-
Notifications
You must be signed in to change notification settings - Fork 397
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
Jar conflicts on Arrow and Protobuf between Vanilla Spark and Gluten #789
Comments
yeah, as mentioned by @zzcclp , the original PR leads to the project loading failure in IDEA and therefore the workflow of people used to using that for development is broken the root cause analysis is following:
so when people uses IDEA to develop with the changed code from "import x.y.z" to "import shade.x.y.z", IDEA cannot find the dependency and the whole project is broken I am proposing
cc @PHILO-HE |
Was this proved a correct usage of dependency shading? Some questions here:
|
you mean whether we are referring the right class? yes, I run it in our environment successfully without the issue
this is basically my second proposal, I am |
this is a good question, I was discussing with @PHILO-HE . The reason I discard here is that, I found the eventual jar will contain two copies of pb, one for relocated, the other is not relocated....I put shade plugin in root pom.xml, in theory, every module should get relocated when being packed into a jar, but still....I checked |
Does this make sense to apply shade plugin on the bundled jar generated by I recalled that (correct me if I was wrong) |
so I spent another few hours in this problem, I don't think anything new is found, please check the following
Flink (https://github.com/apache/flink/blob/03c0f155c2f5198bf1fda35de43afc34a4b12f6e/flink-runtime-web/src/main/java/org/apache/flink/runtime/webmonitor/HttpRequestHandler.java). Flink uses maven, it refers to the shaded netty classes but still makes IDEA happy. The reason is that it publishes a relocated netty library https://mvnrepository.com/artifact/org.apache.flink/flink-shaded-netty/4.1.65.Final-14.0 , everything looks fine in this case. (all packages shaded and published for flink are at https://github.com/apache/flink-shaded) Iceberg (https://github.com/apache/iceberg/blob/0c79e40f8772672daedd45db516e003d9569e038/build.gradle#L203-L242). Iceberg uses gradle, so it can easily define a shaded project just for guava and then refer it in other modules, https://github.com/apache/iceberg/blob/a878ad7cd61b68cf17ead57c3aa7c2b3dae5ab6f/spark/v3.3/build.gradle#L54 I THINK it should have been clear that we have only two options
|
Maybe you can shade in the file |
@CodingCat I've create a PR as proof-of-concept to use shade plugin instead of assembly plugin: Would you like to check on the changes to see if it works on your side? |
I see we have extended a PR to fix this then revert it.
cc6d264
74c3678
@CodingCat We can discuss what have to do about the issue in this thread
The text was updated successfully, but these errors were encountered: