Maven jar-with-dependencies log4j

I am creating jar-with-dependencies executables using maven. My application uses log4j and the src / resources file has the corresponding log4j.properties file.

My problem is that there are other log4j.properties files that float around, so when maven creates jar-with-dependencies, it grabs one of them instead of the one I want and skips any others it finds from- behind log4j.properties are already included.

Does anyone know about this?

+1
source share
1 answer

According to jar-with-dependencies documentation , this is a very dumb tool. For better control, use the maven-shade plugin, where you can exclude all these unwanted files.

+3
source

Source: https://habr.com/ru/post/898139/


All Articles