Skip to content

feat(datafusion): add REST management procedures - #837

Merged
JingsongLi merged 1 commit into
apache:mainfrom
plusplusjiajia:rest-management-procedures
Sep 22, 2026
Merged

JingsongLi merged 1 commit into
apache:mainfrom
plusplusjiajia:rest-management-procedures

Conversation

@plusplusjiajia

@plusplusjiajia plusplusjiajia commented Sep 15, 2026

Copy link
Copy Markdown
Member

Purpose

Ports apache/paimon#9410 to Rust: six CALL sys.* procedures putting the REST management API (#820, #829) behind SQL. Java chose procedures over DDL, and its SQL extension grammar has no GRANT/REVOKE/POLICY at all.

What it adds

CALL sys.grant_permission(resource_type => 'TABLE', database => 'sales',
                          table => 'orders', access => 'SELECT',
                          principal => 'user:alice')

plus revoke_permission, list_permissions, create_policy, drop_policy and list_policies. Procedure names, parameter names and optionality, and the two result schemas follow Java field for field.

Testing

Nineteen tests against the mock REST server, and an end-to-end run against a live Aliyun DLF catalog covering all six procedures, both paging filters, both if_exists paths and the duplicate-policy 409.

@plusplusjiajia
plusplusjiajia force-pushed the rest-management-procedures branch 4 times, most recently from 4ed9f65 to 7d622a7 Compare September 15, 2026 10:25
@plusplusjiajia
plusplusjiajia force-pushed the rest-management-procedures branch from 7d622a7 to 9fbdea6 Compare September 20, 2026 16:57
@plusplusjiajia
plusplusjiajia marked this pull request as ready for review September 20, 2026 16:58
@JingsongLi

Copy link
Copy Markdown
Contributor

Reviewed 9fbdea6. The six CALL procedures provide an end-to-end SQL path to the existing REST permission and policy APIs. I checked argument validation, resource and policy construction, the REST-only catalog boundary, pagination/result mapping, and the mock-server integration tests; I found no actionable issue. The targeted rest_management_procedures suite passed: 18 tests. The initial sandbox run could not bind the local mock server; the rerun with local socket access passed.

@JingsongLi JingsongLi left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

+1

@JingsongLi
JingsongLi merged commit 5de0ba3 into apache:main Sep 22, 2026
14 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants