• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

java.lang.NoSuchMethodError: org.apache.log4j.Category.log

 
Ranch Hand
Posts: 77
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi,
I'm trying to deploy my application in web logic 9.1 . But when i try to deploy i get following error trace.


I tried with both log4j-1.2.8.jar and log4j-1.2.11.jar . I also saw that both jar does not contain that method. Then how does weblogic call those method. Can you specify the correct version of Jar that i have to use. Or is there any other work around to get rid of this problem as i actually dont want that log to be used.

Regards,
Arjun
 
Ranch Hand
Posts: 544
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi,
You may need to check some things mentioned below
1) If you are using the log4j logger from a web application classes(present in WAR file) then check if the Jar is present in the web-inf\lib directory.
2) If jar is present in the web-inf\lib directory and you are trying to reference it from classes which are at application level then those classes may not find the class because log4j would be loaded by webapp classloader.
In this case you might need to add the log4j.jar to the WEBLOGIC_CLASSPATH in startweblogic.cmd.( I am not much aware of 9.1 but this startup script is there till weblogic 8.1).
Regards,
Amit
 
Arjun Karthick
Ranch Hand
Posts: 77
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Thanks Amit,
The problem was the one of the jar(commons-logging.jar) that i was using called a deprecated method from the log4j jar. So once i replaced that jar with other version that referred to correct API , the problem was resolved.

regards,
Arjun.
 
Greenhorn
Posts: 1
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi Arjun
Can you please point me to the correct version of commons-logging.jar. I am also facing the same issue.

Regards
Mohit
 
Bartender
Posts: 2856
10
Firefox Browser Fedora Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
"mit hit "
please check your private messages for an important administrative matter. You can check them by clicking the My Private Messages link above.
 
Don't get me started about those stupid light bulbs.
reply
    Bookmark Topic Watch Topic
  • New Topic