You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@tinkerpop.apache.org by GitBox <gi...@apache.org> on 2021/03/12 15:32:40 UTC

[GitHub] [tinkerpop] spmallette commented on pull request #1405: TINKERPOP-2476 Added shaded uberjar for gremlin-driver

spmallette commented on pull request #1405:
URL: https://github.com/apache/tinkerpop/pull/1405#issuecomment-797564855


   Pushed some minor adjustments. We can't shade logger stuff or else we get a lot of warnings related to logger static initialization. Users will need to handle their own logging conflict resolutions but that seems fairly minimal in my mind. I tested this uberjar with a small sample project and it worked almost as I expected. I didn't realize that we would still get the same dependency tree. So for this setup in my sample project:
   
   ```xml
       <dependencies>
           <dependency>
               <groupId>org.apache.tinkerpop</groupId>
               <artifactId>gremlin-driver</artifactId>
               <version>3.5.0-SNAPSHOT</version>
               <classifier>all</classifier>
           </dependency>
           <dependency>
               <groupId>org.slf4j</groupId>
               <artifactId>slf4j-log4j12</artifactId>
               <version>1.7.25</version>
           </dependency>
           <dependency>
               <groupId>log4j</groupId>
               <artifactId>log4j</artifactId>
               <version>1.2.17</version>
           </dependency>
       </dependencies>
   ```
   
   I get this:
   
   ```text
   $ mvn dependency:tree
   [INFO] Scanning for projects...
   [INFO] 
   [INFO] --------------------< org.example:test-driver-all >---------------------
   [INFO] Building test-driver-all 1.0-SNAPSHOT
   [INFO] --------------------------------[ jar ]---------------------------------
   [INFO] 
   [INFO] --- maven-dependency-plugin:2.8:tree (default-cli) @ test-driver-all ---
   [INFO] org.example:test-driver-all:jar:1.0-SNAPSHOT
   [INFO] +- org.apache.tinkerpop:gremlin-driver:jar:all:3.5.0-SNAPSHOT:compile
   [INFO] |  +- org.apache.tinkerpop:gremlin-core:jar:3.5.0-SNAPSHOT:compile
   [INFO] |  |  +- org.apache.tinkerpop:gremlin-shaded:jar:3.5.0-SNAPSHOT:compile
   [INFO] |  |  +- org.apache.commons:commons-configuration2:jar:2.6:compile
   [INFO] |  |  |  +- org.apache.commons:commons-text:jar:1.8:compile
   [INFO] |  |  |  \- commons-logging:commons-logging:jar:1.2:compile
   [INFO] |  |  +- commons-beanutils:commons-beanutils:jar:1.9.4:compile
   [INFO] |  |  +- commons-collections:commons-collections:jar:3.2.2:compile
   [INFO] |  |  +- org.yaml:snakeyaml:jar:1.27:compile
   [INFO] |  |  +- org.javatuples:javatuples:jar:1.2:compile
   [INFO] |  |  +- com.carrotsearch:hppc:jar:0.7.1:compile
   [INFO] |  |  +- com.jcabi:jcabi-manifests:jar:1.1:compile
   [INFO] |  |  |  \- com.jcabi:jcabi-log:jar:0.14:compile
   [INFO] |  |  +- com.squareup:javapoet:jar:1.8.0:compile
   [INFO] |  |  +- net.objecthunter:exp4j:jar:0.4.8:compile
   [INFO] |  |  \- org.slf4j:jcl-over-slf4j:jar:1.7.25:compile
   [INFO] |  +- io.netty:netty-all:jar:4.1.52.Final:compile
   [INFO] |  \- org.apache.commons:commons-lang3:jar:3.11:compile
   [INFO] +- org.slf4j:slf4j-log4j12:jar:1.7.25:compile
   [INFO] |  \- org.slf4j:slf4j-api:jar:1.7.25:compile
   [INFO] \- log4j:log4j:jar:1.2.17:compile
   [INFO] ------------------------------------------------------------------------
   [INFO] BUILD SUCCESS
   [INFO] ------------------------------------------------------------------------
   [INFO] Total time:  0.684 s
   [INFO] Finished at: 2021-03-12T10:25:59-05:00
   [INFO] ------------------------------------------------------------------------
   ```
   
   which means that I'm still left to resolve conflicts as this uberjar is based on the original pom (and I don't see how that can change though I tried for a while).  This seems normal?? as I see similar findings with the cassandra shaded driver: https://docs.datastax.com/en/developer/java-driver/3.6/manual/shaded_jar/
   
   I've updated the docs a bit to reflect this situation.


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org