Hisoka-X commented on code in PR #7360:
URL: https://github.com/apache/seatunnel/pull/7360#discussion_r1712574052


##########
seatunnel-dist/src/test/java/org/apache/seatunnel/api/connector/ConnectorSpecificationCheckTest.java:
##########
@@ -152,16 +154,29 @@ public void 
testAllConnectorImplementFactoryWithUpToDateMethod() throws ClassNot
                 log.info(
                         "Check sink connector {} successfully", 
factory.getClass().getSimpleName());
 
-                checkSupportMultiTableSink(sinkClass);
+                checkSupportMultiTableSink(factory, sinkClass);
             }
         }
     }
 
-    private void checkSupportMultiTableSink(Class<? extends SeaTunnelSink> 
sinkClass) {
+    private void checkSupportMultiTableSink(
+            TableSinkFactory sinkFactory, Class<? extends SeaTunnelSink> 
sinkClass) {
         if (!SupportMultiTableSink.class.isAssignableFrom(sinkClass)) {
             return;
         }
 
+        OptionRule sinkOptionRule = sinkFactory.optionRule();
+        Assertions.assertTrue(
+                sinkOptionRule
+                                .getOptionalOptions()
+                                
.contains(SinkCommonOptions.MULTI_TABLE_SINK_REPLICA)
+                        || sinkOptionRule
+                                .getRequiredOptions()
+                                
.contains(SinkCommonOptions.MULTI_TABLE_SINK_REPLICA),
+                "Please add `SinkCommonOptions.MULTI_TABLE_SINK_REPLICA` 
option into the `optionRule` method of `"
+                        + sinkFactory.getClass().getSimpleName()
+                        + "`");

Review Comment:
   MULTI_TABLE_SINK_REPLICA should be optional options, can not be required 
options.



-- 
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]

Reply via email to