flink-cdc icon indicating copy to clipboard operation
flink-cdc copied to clipboard

[FLINK-35071][cdc-connector][cdc-base] Shade guava31 to avoid dependency conflict with flink below 1.18

Open loserwang1024 opened this issue 1 year ago • 4 comments

As shown in https://github.com/ververica/flink-cdc-connectors/issues/3071, Unlike flink-table-common、flink-connector-base 、flink-core whose maven scope is provided , flink-shaded-guava and flink-shaded-force-shading will be included in the final jar package, so maybe cause dependency conflict.

Now we can see why dependency conflict occurs:

  • Since Flink 1.18, version of guava is upgrade from 30 to 31 (using 31.1-jre-17.0)

image

  • Since CDC 3.0.1, version of guava is also upgrade from 30 to 31 (using 31.1-jre-17.0)

  • So CDC 3.0.1 is compatible with Flink 1.18, CDC 2.x is is compatible with Flink 1.13-1.17. CDC 2.x and Flink 1.18 dependency conflict, CDC 3.0.1 and Flink 1.17(or earlier version) dependency conflict. (https://maven.apache.org/plugins/maven-shade-plugin/shade-mojo.html#relocations) in pom.xml.

loserwang1024 avatar Feb 27 '24 03:02 loserwang1024

@PatrickRen , CC?

loserwang1024 avatar Apr 17 '24 02:04 loserwang1024

Seems there's some conflicts between master branch, could @loserwang1024 please rebase it when you're available?

yuxiqian avatar Jun 13 '24 08:06 yuxiqian

The CI failed, could you fix it ? @loserwang1024

leonardBang avatar Aug 06 '24 11:08 leonardBang