-
Notifications
You must be signed in to change notification settings - Fork 646
feat(iceberg): support alter iceberg table connector with #22040
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Conversation
oneof object_type { | ||
AlterConnectorPropsObject alter_connector_props_object = 6; | ||
AlterIcebergTablePropsObject alter_iceberg_table_props_object = 7; | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We'd better use a new RPC instead of reusing the altering sink RPC to reduce the coupling. Current implementation is a bit invasive. Use one RPC is ok, however, for the caller side and the RPC implementation, we'd better handle sink and iceberg table separately.
@@ -1311,13 +1311,14 @@ impl MetaClient { | |||
changed_props: BTreeMap<String, String>, | |||
changed_secret_refs: BTreeMap<String, PbSecretRef>, | |||
connector_conn_ref: Option<u32>, | |||
object_type: ObjectType, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We should use a new method like alter_iceberg_table
instead of alter_sink
pub async fn handle_alter_sink_props( | ||
handler_args: HandlerArgs, | ||
table_name: ObjectName, | ||
alter_sink_object: AlterSinkObject, | ||
changed_props: Vec<SqlOption>, | ||
) -> Result<RwPgResponse> { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
we should have a new method handle_alter_iceberg_table
@@ -1612,6 +1613,7 @@ impl CatalogController { | |||
&self, | |||
sink_id: SinkId, | |||
props: BTreeMap<String, String>, | |||
object_type: risingwave_pb::meta::alter_connector_props_request::ObjectType, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This method is update_sink_props_by_sink_id
, if we need to change iceberg table properies, we'd better use a new method.
I hereby agree to the terms of the RisingWave Labs, Inc. Contributor License Agreement.
Previously, we implemented the
ALTER SINK CONNECTOR
syntax, but it lacked support for directly modifying Iceberg tables. Since Iceberg table definitions are not stored via Sink statements, attempts to alter them using Sink syntax would inevitably fail. This PR introducesALTER TABLE
support for Iceberg tables, enabling direct modifications to their associated Sink configurations.Previously, we synchronized configurations by pulling the full config from the Meta service and dispatching it to the Sink. However, we observed that the Meta-stored configurations were incomplete. This PR refactors the mechanism to incremental updates: only modified configurations are pushed to Compute Nodes and dynamically merged with the Sink's existing configurations.
Checklist
Documentation
Release note