Reputation: 634
I have an application that is being deployed to an AIX machine as an executable JAR. I used Maven shade to build an Uber JAR that has all of my dependencies packed in the JAR; Spring, Logback, and javax.mail. The application is called by another program executing a shell script. That all works fine. The DBA has asked that I remove of all of the dependencies from the JAR, place them in directories on the AIX machine, and include those locations in the CLASSPATH of the AIX user. He indicated that this was best practice. I have used the <scope>provided</scope>
tag before in Maven to not package dependencies that the Container would provide, but I have never run into this type of request with a JAR. Is this a best practice with this sort of scenario?
Upvotes: 2
Views: 676
Reputation: 1676
In the Uber-JAR the dependencies are not visible. But there are a lot of people out there, which need to know and list all dependencies, because they need to publish a list of all license (for example gnu,asf...) used in the application.
So if you need a clear listing of all dependencies, then the Uber-JAR is not the best practice you should go.
Upvotes: 1