DanielLeens commented on code in PR #11912: URL: https://github.com/apache/seatunnel/pull/11912#discussion_r4357154875
########## seatunnel-api/src/main/java/org/apache/seatunnel/api/sink/SupportCoordinatedSchemaEvolutionSink.java: ########## @@ -0,0 +1,51 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package org.apache.seatunnel.api.sink; + +import org.apache.seatunnel.api.annotation.Experimental; +import org.apache.seatunnel.api.table.catalog.TablePath; + +import java.io.IOException; + +/** + * Sink capability for engine-coordinated external schema application. + * + * <p>Writers created by an implementation must also implement {@link + * SupportSchemaRefreshSinkWriter}. + */ +@Experimental +public interface SupportCoordinatedSchemaEvolutionSink extends SupportSchemaEvolutionSink { + + /** Review Comment: Thanks for the question, @nzw921rx. I traced the callers: MultiTableSink itself implements SupportCoordinatedSchemaEvolutionSink (MultiTableSink.java:243-250), so a plain instanceof check would be true for every multi-table sink, including ones whose child sinks do not support coordination. The method lets the composite answer 'all children support it' (callers: FlinkSink.java:105 and SchemaEvolutionSinkFlow.java:42). I think it is needed; a short javadoc on the interface method explaining why instanceof alone is not enough would make that clear. @dybyte could you add that line? -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
