-
Notifications
You must be signed in to change notification settings - Fork 1.8k
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
[Bug][Connector-v2] MongoDB CDC Set SeatunnelRow's tableId #7935
Conversation
...seatunnel/connectors/seatunnel/cdc/mongodb/sender/MongoDBConnectorDeserializationSchema.java
Show resolved
Hide resolved
...a/org/apache/seatunnel/connectors/seatunnel/cdc/mongodb/MongodbIncrementalSourceFactory.java
Show resolved
Hide resolved
@@ -310,3 +241,6 @@ sink { | |||
} | |||
``` | |||
|
|||
## Feature | |||
- Support Multi-table Synchronization for MongoDB-CDC. |
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.
where?
"inventory.products", | ||
keyDocument, | ||
valueDocument); | ||
Object tableId = ReflectionUtils.invoke(schema, "extractTableId", sourceRecord); |
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 can use @VisibleForTesting
annotation to avoid use ReflectionUtils.
List<String> collections = context.getOptions().get(MongodbSourceOptions.COLLECTION); | ||
if (collections.size() != configCatalog.size()) { |
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.
how about add a test case for mongocdc with multi tables.
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.
Waiting CI passes
Purpose of this pull request
Does this PR introduce any user-facing change?
method of
MongoDBConnectorDeserializationSchema.extractTableId
not implemented , The tableId of SeatunnelRow is null, which may affect other downstream operations.How was this patch tested?
Check list
New License Guide
release-note
.