1

Well, this is awkward. I want to use log4j-over-slf4j for our logging and so I've added the jar to the project and specified in the WebLogic application to use the package org.slf4j.* but the problem is that the commons jar library on WebLogic has slf4j-log4j12.jar which creates a conflict:

java.lang.IllegalStateException: Detected both log4j-over-slf4j.jar AND slf4j-log4j12.jar on the class path, preempting StackOverflowError. See also  http://www.slf4j.org/codes.html#log4jDelegationLoop for more details.

How can I tell WebLogic to ignore that package?

Maarten Bodewes
  • 90,524
  • 13
  • 150
  • 263
diazazar
  • 522
  • 1
  • 5
  • 24

1 Answers1

0

So you're using this?

<wls:prefer-application-packages>
    <wls:package-name>org.slf4j.*</wls:package-name>
</wls:prefer-application-packages>

And have you seen this same question?

Community
  • 1
  • 1
Display Name is missing
  • 6,197
  • 3
  • 34
  • 46
  • yes I am using that. You cannot have those two libraries together! One comes from my ear one comes from the commonsJar I am trying to connect to. please look carefully at my situation, i dont have them both in my ear to simply exclude one and i cannot exclude the one my project is using – diazazar Aug 05 '14 at 07:12
  • We have both of those jars on our classpath but `prefer-application-packages` fixes the issue and seems to for everyone else. http://stackoverflow.com/questions/9734503/prevent-weblogic-12c-from-using-systems-slf4j-binding http://buttso.blogspot.com/2011/06/using-slf4j-with-weblogic-server.html http://blog.terrencemiao.com/archives/annoying-slf4j-problem-in-weblogic-server-12c Not sure how your scenario is different – Display Name is missing Aug 05 '14 at 15:23