Interface SupportsRowLevelModificationScan
-
@PublicEvolving public interface SupportsRowLevelModificationScanInterface forScanTableSources that support the row-level modification. The table source is responsible for returning the information described byRowLevelModificationScanContext. The context will be propagated to the sink which implementsSupportsRowLevelUpdateorSupportsRowLevelDelete.Note: This interface is optional for table sources to implement. For cases where the table source neither needs to know the type of row-level modification nor propagate information to sink, the table source doesn't need to implement this interface. See more details at
applyRowLevelModificationScan(RowLevelModificationType, RowLevelModificationScanContext).
-
-
Nested Class Summary
Nested Classes Modifier and Type Interface Description static classSupportsRowLevelModificationScan.RowLevelModificationTypeType of the row-level modification for table.
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description RowLevelModificationScanContextapplyRowLevelModificationScan(SupportsRowLevelModificationScan.RowLevelModificationType rowLevelModificationType, RowLevelModificationScanContext previousContext)Applies the type of row-level modification and the previousRowLevelModificationScanContextreturned by previous table source scan, return a newRowLevelModificationScanContext.
-
-
-
Method Detail
-
applyRowLevelModificationScan
RowLevelModificationScanContext applyRowLevelModificationScan(SupportsRowLevelModificationScan.RowLevelModificationType rowLevelModificationType, @Nullable RowLevelModificationScanContext previousContext)
Applies the type of row-level modification and the previousRowLevelModificationScanContextreturned by previous table source scan, return a newRowLevelModificationScanContext. If the table source is the last one, theRowLevelModificationScanContextwill be passed to the table sink. Otherwise, it will be passed to the following table source.Note: For the all tables in the UPDATE/DELETE statement, this method will be involved for the corresponding table source scan.
Note: It may have multiple table sources in the case of sub-query. In such case, it will return multiple
RowLevelModificationScanContexts. To handle such case, the planner will also pass the previousRowLevelModificationScanContextto the current table source scan which is expected to decide what to do with the previousRowLevelModificationScanContext. The order is consistent with the compilation order of the table sources. The planer will only pass the last context returned to the sink.- Parameters:
previousContext- the context returned by previous table source, if there's no previous context, it'll be null.
-
-