[Bug] Inconsistent Kafka shading among cdc connectors
envgap__apache__flink-cdc-2984
01 / FAILURE SIGNATURE
As reported upstream
Put flink-sql-connector-tidb-cdc-3.0.0.jar, flink-sql-connector-mysql-cdc-3.0.0.jar and flink-sql-connector-mongodb-cdc-3.0.0.jar into lib folder at Flink home (Flink 1.14 in my case), then create a MySQL CDC table and submit a simple query like select * from mysql_cdc_table, there would be an error:
Not a benchmark task.
- In a clean container the reported failure did not reproduce, or the known fix did not make the project run.
02 / ENVIRONMENT RECIPE
- Base commit
5f4f86fb3190e14b4437e6134760759dce19609c- Manifest
flink-cdc-connect/flink-cdc-source-connectors/flink-sql-connector-tidb-cdc/pom.xml- Reproduce
Awaiting issue-specific recipe- Run under trace
Awaiting a meaningful runtime command
03 / ORIGINAL ISSUE TEXT
apache/flink-cdc #2984 · read the original issue
### Search before asking - [X] I searched in the [issues](https://github.com/ververica/flink-cdc-connectors/issues) and found nothing similar. ### Flink version 1.14.3 ### Flink CDC version 3.0.0 ### Database and its version MySQL 5.7 Mongo 4.4 ### Minimal reproduce step Put flink-sql-connector-tidb-cdc-3.0.0.jar, flink-sql-connector-mysql-cdc-3.0.0.jar and flink-sql-connector-mongodb-cdc-3.0.0.jar into lib folder at Flink home (Flink 1.14 in my case), then create a MySQL CDC table and submit a simple query like select * from mysql_cdc_table, there would be an error: `java.lang.NoClassDefFoundError: org/apache/kafka/connect/source/SourceRecord` It's caused by inconsistent shading of Kafka classes. Only MySQL CDC connector relocated Kafka classes, so if the classpath contains un-relocated classes from other CDC connectors the above error occurs. ### What did you expect to see? The cdc connectors would not have class conflicts. ### What did you see instead? The cdc connectors have class conflicts. ### Anything else? _No response_ ### Are you willing to submit a PR? - [X] I'm willing to submit a PR!
04 / LABELS
Labels from the report text only; not yet run
No supported category has been assigned.
Label rules and the text that matched
[]