[rust] Add RPC message wrappers for core DB/table operations#629
Open
gnuhpc wants to merge 2 commits into
Open
[rust] Add RPC message wrappers for core DB/table operations#629gnuhpc wants to merge 2 commits into
gnuhpc wants to merge 2 commits into
Conversation
- Update fluss_api.proto with all 1.x message types (ACLs, KV snapshots,
producer offsets, cluster config, rebalance, server tags, etc.)
- Add optional fields: rack, remote_data_dir, leader_epoch, agg_mode, etc.
- Register 24 new ApiKey variants (1023-1064) in api_key.rs
- Update build.rs prost bytes config for new proto fields
- Add None defaults in convert.rs and partition.rs
- Update pre-existing message wrappers that reference renamed proto fields /
ApiKey variants so the crate still builds:
* create_partition.rs: ignore_if_exists -> ignore_if_not_exists
* get_latest_lake_snapshot.rs: ApiKey::GetLatestLakeSnapshot -> GetLakeSnapshot
* list_databases.rs: populate new include_summary field
* lookup.rs: PbLookupReqForBucket.key -> keys; new LookupRequest fields
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Add 9 RPC message wrapper types: - alter_database, alter_table (DDL operations) - get_table_stats (table statistics) - list_database_summaries (database listing with summaries) - create_acls, list_acls, drop_acls (ACL management) - describe_cluster_configs, alter_cluster_configs (cluster configuration) Each wrapper follows the standard pattern: a request struct wrapping the proto-generated type, implementing RequestBody (tying to ApiKey and ResponseBody), WriteType, and ReadType. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This was referenced Jun 19, 2026
fresh-borzoni
requested changes
Jun 19, 2026
fresh-borzoni
left a comment
Member
There was a problem hiding this comment.
@gnuhpc Thank you for the PR, we need to address a couple of issues here.
We shouldn't use proto::* in any public FlussAdmin signature.
Please, define domain types mirroring Java's with conversion in the wrapper layer
| inner_request: proto::GetTableStatsRequest { | ||
| table_id, | ||
| buckets_req, | ||
| target_columns: vec![], |
Member
There was a problem hiding this comment.
why do we hardcode target_columns: vec![]?
There's no way to ask for specific columns with this, is it intentional?
| use bytes::{Buf, BufMut}; | ||
| use prost::Message; | ||
|
|
||
| #[derive(Debug, Default)] |
Member
There was a problem hiding this comment.
Can we drop #[derive(Default)] on the arg-taking requests?
default() just builds empty(invalid requests), and the rest of the wrappers are #[derive(Debug)] only, so it's inconsistent
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.
What
Adds request/response message wrappers for the core 1.x DB/table admin RPCs:
AlterClusterConfigs,AlterDatabase,AlterTable,CreateAcls,DescribeClusterConfigs,DropAcls,GetTableStats,ListAcls,ListDatabaseSummaries.Each is a thin wrapper over the generated
proto::types (from #628) wired intorpc/message/mod.rs. The admin client methods that consume them land in a later PR.Stack
Part 2/6 of the Fluss 1.x Rust support series, stacked on #628 (
pr/1-proto-sync). Each branch in the stack compiles on top of its predecessor, so all PRs here targetmain; once #628 merges, this PR's diff automatically reduces to just the 9 message files unique to this branch.🤖 Generated with Claude Code