Stop log4j-1.2.17.jar from loading in \osgi\state

BRODY HIGGS JR, modified 3 Years ago. Junior Member Posts: 61 Join Date: 5/16/14 Recent Posts

LIferay 7.3.4GA5

Which file in \osgi\ folder is allowing log4j-1.2.17.jar to load?  I noticed log4j-1.2.17.jar in this location and would like to stop it from loading in the state folder.  I know how to use \osgi\marketplace\override folder to load modified .jar files.  I wonder if I can do the same for this log4j-1.2.17.jar file.

 

log4j location:   osgi\state\org.eclipse.osgi\2384\0\.cp\lib\log4j-1.2.17.jar

 

thumbnail
Olaf Kock, modified 3 Years ago. Liferay Legend Posts: 6441 Join Date: 9/23/08 Recent Posts

If the library exists in osgi/state, some module brings it. You might​​​​​​​ look at osgi/state for informational purpose, but you should not think on modifying anything on that level. It's just a cache that the OSGi runtime has under control.

Rather identify who brings it and fix that module.

How? The lpkg files in osgi/marketplace are actually zip format, so you can open them with standard unzip and inspect them. Or locate the dependency in Liferay's source, where you likely can grep it.