github-actions[bot] commented on code in PR #68320:
URL: https://github.com/apache/doris/pull/68320#discussion_r4123925404
##########
fe/fe-core/src/main/java/org/apache/doris/nereids/trees/plans/commands/RowLevelDmlRegistry.java:
##########
@@ -50,6 +54,20 @@ public static Optional<RowLevelDmlTransform> find(TableIf
table) {
return Optional.of(transform);
}
}
+ if (table instanceof PluginDrivenExternalTable) {
+ PluginDrivenExternalTable connectorTable =
(PluginDrivenExternalTable) table;
+ Set<WriteOperation> operations =
connectorTable.connectorSupportedWriteOperations();
+ if (supportsAnyRowLevelDml(operations)) {
+ throw new AnalysisException("No row-level DML plan for
connector row-change style "
+ + connectorTable.getConnectorRowChangeStyle());
+ }
+ }
return Optional.empty();
}
+
+ static boolean supportsAnyRowLevelDml(Set<WriteOperation> operations) {
+ return operations.contains(WriteOperation.DELETE)
+ || operations.contains(WriteOperation.UPDATE)
Review Comment:
[P2] Preserve UPDATE capability through position-delete translation. A
provider with `POSITION_DELETE` and `supportedOperations() = {INSERT, UPDATE}`
now passes this probe and `checkMode`. UPDATE builds
`PhysicalExternalRowLevelMergeSink`, whose translator passes `MERGE` to
`buildPluginRowLevelDmlSink`; its gate rejects this provider before
`planWrite`. A provider that also supports DELETE passes the gate but still
receives MERGE for SQL UPDATE. Carry the SQL operation through the sink and
plan that operation, or require MERGE before admitting this path; cover an
UPDATE-only provider.
--
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]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]