[rust] Add Fluss 1.x protocol support to the admin client#625
Closed
gnuhpc wants to merge 1 commit into
Closed
Conversation
Bring the Rust client up to date with the latest Fluss 1.x server API: - Sync `fluss_api.proto` with the 1.x schema (new/renamed fields such as `rack`, `filter_predicate`, `remote_data_dir`, `PbLookupReqForBucket.keys`, `ScanKvResponse.records`, and the `ignore_if_not_exists` partition flag). - Register the new API keys in `api_key.rs`. - Add RPC message wrappers for the new admin operations: alter table/database, cluster config describe/alter, table stats, KV snapshot listing/metadata and lease acquire/release/drop, lake snapshot, ACL create/list/drop, server tags, rebalance trigger/progress/cancel, producer offset register/get/delete, cluster health, remote log manifests, and KV scan. - Expose all of the above as methods on `FlussAdmin`. - Adapt existing message wrappers and conversions to the new field shapes. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
This PR syncs the Rust client with the Fluss 1.x server protocol and exposes the new admin APIs it introduced.
Proto changes (
fluss_api.proto)ScanKvRequest:filter_predicate,filter_schema_id,remote_data_dir,filtered_end_offsetrackfield toPbServerNodeignore_if_not_existstoCreatePartitionRequestPbLookupReqForBucket.key→keys(repeated bytes, matches 1.x schema)ScanKvResponse.recordsfieldNew message wrappers (
src/rpc/message/)27 new request/response wrapper files covering all admin RPCs that previously lacked Rust bindings:
acquire_kv_snapshot_lease,add_server_tag,alter_cluster_configs,alter_database,alter_table,cancel_rebalance,create_acls,delete_producer_offsets,describe_cluster_configs,drop_acls,drop_kv_snapshot_lease,get_cluster_health,get_kv_snapshot_metadata,get_lake_snapshot,get_latest_kv_snapshots,get_producer_offsets,get_table_stats,list_acls,list_database_summaries,list_kv_snapshots,list_rebalance_progress,list_remote_log_manifests,rebalance,register_producer_offsets,release_kv_snapshot_lease,remove_server_tag,scan_kvAdmin client (
src/client/admin.rs)Added 23 new public methods covering the full admin API surface:
list_databases,list_database_summaries,get_table_schema,alter_table,alter_database,describe_cluster_configs,alter_cluster_configs,get_table_stats,get_latest_kv_snapshots,acquire_kv_snapshot_lease,get_kv_snapshot_metadata,release_kv_snapshot_lease,drop_kv_snapshot_lease,list_kv_snapshots,add_server_tag,remove_server_tag,rebalance,cancel_rebalance,list_rebalance_progress,register_producer_offsets,get_producer_offsets,delete_producer_offsets,create_acls,list_acls,drop_acls,get_lake_snapshot,get_latest_lake_snapshot,get_cluster_health,list_remote_log_manifestsAPI key registry (
src/rpc/api_key.rs)Added entries for all new 1.x API key IDs (1057–1064).
build.rsUpdated
prost_buildbytes configuration to use the renamedkeysfield and the newrecordsfield.Test plan
cargo build -p fluss-rs— library builds cleanlycargo clippy -p fluss-rs --tests --features integration_tests,fluss_v1— no warnings🤖 Generated with Claude Code