I am fighting with maven to include a managed dependency with \'provided\' scope into tar file by using the maven-assembly-plugin.
I use super parent pom file as a base
You can override a managed dependency by declaring it inside a
tag in the POM where you want it to be overridden.
In your case, you should add the following to your child pom:
log4j
log4j
${log4j.version}
provided
Note that this overrides everything declared in the parent POM's dependency management, i.e. you cannot leave version
or scope
undeclared and expect it to be inherited.