-
Notifications
You must be signed in to change notification settings - Fork 2k
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
[FLINK-37120][pipeline-connector/mysql] Add ending split chunk first to avoid TaskManager oom #3856
base: master
Are you sure you want to change the base?
Conversation
CI:https://github.com/beryllw/flink-cdc/actions/runs/12779452404 |
Adding the ending split chunk first changes the snapshot read result order. I will fix the unit test. |
THanks @beryllw for the contribution, the idea makes sense to me, but we need to consider the compatibility, a configuration is recommended |
If data consistency is not an issue, are there any compatibility concerns we need to address? |
...a/org/apache/flink/cdc/connectors/base/source/assigner/splitter/JdbcSourceChunkSplitter.java
Show resolved
Hide resolved
What‘s more, could you add this optimization to |
Sure, i will check MongoDBChunkSplitter. |
1004386
to
9a7ed71
Compare
I overlooked this issue #3704, good idea. Maybe support |
My previous PR provided both I think if there is no impact on restarting from the previous state, there is no compatibility issue, but adding a parameter to control it would be safer. |
...ysql/src/main/java/org/apache/flink/cdc/connectors/mysql/factory/MySqlDataSourceFactory.java
Outdated
Show resolved
Hide resolved
I think adding a test in MySqlSourceITCase to test the case of restoring from failure will be better. |
agree. |
LGTM. |
What about |
@leonardBang @lvyanquan PTAL |
Thanks @beryllw for this update, since you've added this feature to jdbc common module, it seems like that this config option was not added in DynamicTableSourceFactory and was not passed to Source. |
Thanks for pointing out the error, fixed. Awaiting CI. |
Hi, @beryllw. Do you want to support it all here, or do you want to split the modification of JDBC base into another PR. |
Support it all here is better.Thanks. |
https://github.com/beryllw/flink-cdc/actions/runs/13258656371?pr=7 |
...l-cdc/src/main/java/org/apache/flink/cdc/connectors/mysql/table/MySqlTableSourceFactory.java
Show resolved
Hide resolved
…to avoid TaskManager oom
39bd7b3
to
53471ca
Compare
Add ending split chunk first to avoid TaskManager oom