Still celebrating National IT Professionals Day with 3 months of free Premium Membership. Use Code ITDAY17

x
?
Solved

ClassLoading In weblogic 10 Vs 10.3.3 ???

Posted on 2011-09-15
13
Medium Priority
?
1,288 Views
Last Modified: 2012-05-12
Dear All ,
I have couple of questions related to weblogic 10.3 version ...Pls help

1) Facing Some problems while configuring logger for my application............... I have an ear which is compiled with Java 5 and is well working with weblogic 10 . My ear using log4j and for this iam not addign any log4j jar while deploying... I hope this is not necessary , weblogic contains log4j jars inbuilt and loads them on server start up.......

But the same scenario , is not working in weblogic 10.3.3 .... When i deploy ear , Iam getting following exception in 10.3.3 :
java.lang.ClassNotFoundException: org.apache.log4j.Logger
at weblogic.utils.classloaders.GenericClassLoader.findLocalClass(Generic
ClassLoader.java:280)
at weblogic.utils.classloaders.GenericClassLoader.findClass(GenericClass
Loader.java:253)
at weblogic.utils.classloaders.ChangeAwareClassLoader.findClass(ChangeAw
areClassLoader.java:56)
at java.lang.ClassLoader.loadClass(ClassLoader.java:307)

And the issue is getting solved , when i explicly keep the log4j jar in domain-home\lib folder ...... Iam unable to get difference between both weblogic versions classloaders ??/

2) I know that weblogic 10.3 onwards supports java 6... So , can't we deploy applications compiled with 5 into it.?? will it bring any problems ??

3) Can't we start weblogic 10.3 server domain by pointing to JDK 5 ??? When i changed java-home of domain to java 5 it's not at all starting......?? If it supports 6 , i feel there should be backward compatibility as well so that it should support 5 in all cases ??? I might be wrong ...but pls answer my questions
0
Comment
Question by:npglobal
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 5
  • 4
13 Comments
 
LVL 8

Expert Comment

by:vsudip
ID: 36541910
Can u share the code snippet... how are you using log4j in your application ?
0
 
LVL 8

Accepted Solution

by:
vsudip earned 2000 total points
ID: 36541965
Well there is a major difference between webogic 10 & 10.3 version is that... log4j.jar was implicitly included on the WebLogic Server classpath in WLS 10.0. While in  WLS 10.3, log4j.jar is no longer on the WebLogic Server classpath. So here (WLS 10.3)you have to manually add log4j in the server classpath.
0
 

Author Comment

by:npglobal
ID: 36542214
Thanks for reply dear vsudip..... That sound's different for me..... Why In weblogic 10.3 , they removed log4j.jar from classpath ??  But I found the jar's(Related to log4j , Commons-logging)  present inside weblogic server folder .

Where I get these information , I searched in weblogic 10.3.3 , but couldn't find any thing .... Now , we want to migrate from 10 to 10.3.3 , so can i find any migration steps in weblogic docs ??

And can u pls suggest a way to my last question as well ? i.e why can't i start weblogic server with jdk 1.5 ?? I guess all server jars might get compiled with jdk 6 .... So jdk 5 classloader unable to load classes compiled with 6 ... Iam I right ?



0
Portable, direct connect server access

The ATEN CV211 connects a laptop directly to any server allowing you instant access to perform data maintenance and local operations, for quick troubleshooting, updating, service and repair.

 

Author Comment

by:npglobal
ID: 36542220
Iam using log4j related code in one of my servlet which loads on server start up... So , even my application is not deployed because of this reason ...
0
 
LVL 8

Assisted Solution

by:vsudip
vsudip earned 2000 total points
ID: 36542282
I am not very sure... but it seems that 10.3.3 is not compatible with jdk 1.5.

For upgrading the to 10.3.3... see below link.... might be helpful for you...

http://download.oracle.com/docs/cd/E12840_01/wls/docs103/upgrade/upgrading9091.html
0
 

Author Comment

by:npglobal
ID: 36542973
Hi vsudip ,

Yes....Found answers to all questions.... Log4j is not there in classpath of weblogic 10.3 server .... The reason is that , if user wants specific log4j version jar to be loaded he wont get those class if weblogic also loads it's default jar ( as it will be first in classpath tree) ....... That's why they removed  loading of log4j jar in weblogic 10.3

We can deploy applications compiled with 1.5 , but can not use 1.6 to start weblogic as weblogic server inbuilt jars are compiled with java 6........ Lower level classloader can not load classes compiled with higher level........

Thanks for replies........... :):)
0
 

Author Comment

by:npglobal
ID: 36547645
I've requested that this question be closed as follows:

Accepted answer: 0 points for npglobal's comment http:/Q_27309516.html#36542973

for the following reason:

Found answer with the help of suggestions
0
 
LVL 8

Expert Comment

by:vsudip
ID: 36547646
Hi... if comment is ' Found answer with the help of suggestions' so why the points were not assigned ?
0
 
LVL 8

Expert Comment

by:vsudip
ID: 36585339
Recommendation:
option 3) below posts should be treated as answer , answer Id's are 36541965 ( vsudip ) , 36542282 (vsudip).
0

Featured Post

Manage your data center from practically anywhere

The KN8164V features HD resolution of 1920 x 1200, FIPS 140-2 with level 1 security standards and virtual media transmissions at twice the speed. Built for reliability, the KN series provides local console and remote over IP access, ensuring 24/7 availability to all servers.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Verbose logging is used to diagnose garbage collector problems. By default, -verbose:gc output is written to either native_stderr.log or native_stdout.log.   It is also possible to redirect the logs to a user-specified file. This article will de…
Upgrading Tomcat – There are a couple of methods to upgrade Tomcat is to use The Apache Installer is to download and unzip and run the services.bat remove|install Tomcat6 Because of the App that we are working with, we can only use Tomcat 6.…
Video by: ITPro.TV
In this episode Don builds upon the troubleshooting techniques by demonstrating how to properly monitor a vSphere deployment to detect problems before they occur. He begins the show using tools found within the vSphere suite as ends the show demonst…
Add bar graphs to Access queries using Unicode block characters. Graphs appear on every record in the color you want. Give life to numbers. Hopes this gives you ideas on visualizing your data in new ways ~ Create a calculated field in a query: …
Suggested Courses

721 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question