commons-logging.jar not loaded [message #77249] |
Wed, 12 July 2006 06:24  |
Eclipse User |
|
|
|
Originally posted by: prince.pajero.gmail.com
I run TPTP Junit plugin test for my plugin. Here is the setup.
Plugin xyzlib contains the commons-logging.jar
Plugin abcPlugin has some simple code which uses classes provided by
common-logging.jar
In plugin xyzlib I've exported the commons-logging.jar from the Project
Properties sheet. I've also added the jar to the Classpath in the
Runtime tab of the Manifest editor. Also, I've exported the packages to
all downstream plugins.
Now my plugin abcPlugin has some (plain) Junit tests, which I can run
using Run > Run as Junit Plugin Test. There are no problems and my code
can find the classes from the commons-logging.jar
Problem is when I Import the same tests TPTP Junit Plugin tests and try
to run then my code throws a Runtime NoClassDefFoundException.
I tried to debug and found that in BundleLoader.class, in the method:-
Class findClass(String name, boolean checkParent) throws
ClassNotFoundException
after these lines:-
// 4) search the required bundles
source = findRequiredSource(pkgName);
the source variable:-
source > supplier > loader > classloader > classpathentries
has the entry for commons-logging.jar in case of Junit Plugin Test
BUT
does not have any entry in case of TPTP Junit Plugin Test.
|
|
|
|
Re: commons-logging.jar not loaded [message #77280 is a reply to message #77265] |
Wed, 12 July 2006 06:41   |
Eclipse User |
|
|
|
Originally posted by: prince.pajero.gmail.com
The plugin org.apache.jakarta_commons_logging has the
commons-logging.jar already, which I guess is causing the problem
Prince Singh wrote:
> Forgot to add this:-
> I'm using eclipse 3.1.2 with TPTP 4.1.0.1, Sun Java 1.5 OS is FC3-linux
>
> Also, TPTP uses the commons-logging.jar itself, so it might be causing
> some conflict and hence the commons-logging.jar is not loaded by the
> class loader when my code requests it.
>
> Are these any useful links:-
> http://www.qos.ch/logging/classloader.jsp
> http://help.eclipse.org/help31/index.jsp?topic=/org.eclipse. hyades.test.doc.user/tasks/tdeploymentGroundRules.htm
>
> For the second link, the Excluded Libraries topic seems interesting. But
> I have no idea why isn't this 'issue' resolved.
>
>
>
> Prince Singh wrote:
>> I run TPTP Junit plugin test for my plugin. Here is the setup.
>>
>> Plugin xyzlib contains the commons-logging.jar
>> Plugin abcPlugin has some simple code which uses classes provided by
>> common-logging.jar
>>
>> In plugin xyzlib I've exported the commons-logging.jar from the
>> Project Properties sheet. I've also added the jar to the Classpath in
>> the Runtime tab of the Manifest editor. Also, I've exported the
>> packages to all downstream plugins.
>>
>> Now my plugin abcPlugin has some (plain) Junit tests, which I can run
>> using Run > Run as Junit Plugin Test. There are no problems and my
>> code can find the classes from the commons-logging.jar
>>
>> Problem is when I Import the same tests TPTP Junit Plugin tests and
>> try to run then my code throws a Runtime NoClassDefFoundException.
>>
>> I tried to debug and found that in BundleLoader.class, in the method:-
>>
>> Class findClass(String name, boolean checkParent) throws
>> ClassNotFoundException
>>
>> after these lines:-
>>
>> // 4) search the required bundles
>> source = findRequiredSource(pkgName);
>>
>> the source variable:-
>> source > supplier > loader > classloader > classpathentries
>>
>> has the entry for commons-logging.jar in case of Junit Plugin Test
>> BUT
>> does not have any entry in case of TPTP Junit Plugin Test.
|
|
|
Re: commons-logging.jar not loaded [message #77296 is a reply to message #77280] |
Wed, 12 July 2006 07:29   |
Eclipse User |
|
|
|
Originally posted by: prince.pajero.gmail.com
I made my plugin dependent on org.apache.jakarta_commons_logging and
evrything worked fine. But this is not how I want to do it. I want the
commons-logging.jar api to be available through my plugin only.
Please Help !!
Prince Singh wrote:
> The plugin org.apache.jakarta_commons_logging has the
> commons-logging.jar already, which I guess is causing the problem
>
> Prince Singh wrote:
>> Forgot to add this:-
>> I'm using eclipse 3.1.2 with TPTP 4.1.0.1, Sun Java 1.5 OS is FC3-linux
>>
>> Also, TPTP uses the commons-logging.jar itself, so it might be causing
>> some conflict and hence the commons-logging.jar is not loaded by the
>> class loader when my code requests it.
>>
>> Are these any useful links:-
>> http://www.qos.ch/logging/classloader.jsp
>> http://help.eclipse.org/help31/index.jsp?topic=/org.eclipse. hyades.test.doc.user/tasks/tdeploymentGroundRules.htm
>>
>> For the second link, the Excluded Libraries topic seems interesting.
>> But I have no idea why isn't this 'issue' resolved.
>>
>>
>>
>> Prince Singh wrote:
>>> I run TPTP Junit plugin test for my plugin. Here is the setup.
>>>
>>> Plugin xyzlib contains the commons-logging.jar
>>> Plugin abcPlugin has some simple code which uses classes provided by
>>> common-logging.jar
>>>
>>> In plugin xyzlib I've exported the commons-logging.jar from the
>>> Project Properties sheet. I've also added the jar to the Classpath in
>>> the Runtime tab of the Manifest editor. Also, I've exported the
>>> packages to all downstream plugins.
>>>
>>> Now my plugin abcPlugin has some (plain) Junit tests, which I can run
>>> using Run > Run as Junit Plugin Test. There are no problems and my
>>> code can find the classes from the commons-logging.jar
>>>
>>> Problem is when I Import the same tests TPTP Junit Plugin tests and
>>> try to run then my code throws a Runtime NoClassDefFoundException.
>>>
>>> I tried to debug and found that in BundleLoader.class, in the method:-
>>>
>>> Class findClass(String name, boolean checkParent) throws
>>> ClassNotFoundException
>>>
>>> after these lines:-
>>>
>>> // 4) search the required bundles
>>> source = findRequiredSource(pkgName);
>>>
>>> the source variable:-
>>> source > supplier > loader > classloader > classpathentries
>>>
>>> has the entry for commons-logging.jar in case of Junit Plugin Test
>>> BUT
>>> does not have any entry in case of TPTP Junit Plugin Test.
|
|
|
|
|
Re: commons-logging.jar not loaded [message #77520 is a reply to message #77296] |
Mon, 17 July 2006 08:17  |
Eclipse User |
|
|
|
Originally posted by: prince.pajero.gmail.com
I tried with eclipse 3.2.0 and tptp 4.2.0 the problem is not there.
Prince Singh wrote:
> I made my plugin dependent on org.apache.jakarta_commons_logging and
> evrything worked fine. But this is not how I want to do it. I want the
> commons-logging.jar api to be available through my plugin only.
>
> Please Help !!
>
>
> Prince Singh wrote:
>> The plugin org.apache.jakarta_commons_logging has the
>> commons-logging.jar already, which I guess is causing the problem
>>
>> Prince Singh wrote:
>>> Forgot to add this:-
>>> I'm using eclipse 3.1.2 with TPTP 4.1.0.1, Sun Java 1.5 OS is FC3-linux
>>>
>>> Also, TPTP uses the commons-logging.jar itself, so it might be
>>> causing some conflict and hence the commons-logging.jar is not loaded
>>> by the class loader when my code requests it.
>>>
>>> Are these any useful links:-
>>> http://www.qos.ch/logging/classloader.jsp
>>> http://help.eclipse.org/help31/index.jsp?topic=/org.eclipse. hyades.test.doc.user/tasks/tdeploymentGroundRules.htm
>>>
>>> For the second link, the Excluded Libraries topic seems interesting.
>>> But I have no idea why isn't this 'issue' resolved.
>>>
>>>
>>>
>>> Prince Singh wrote:
>>>> I run TPTP Junit plugin test for my plugin. Here is the setup.
>>>>
>>>> Plugin xyzlib contains the commons-logging.jar
>>>> Plugin abcPlugin has some simple code which uses classes provided by
>>>> common-logging.jar
>>>>
>>>> In plugin xyzlib I've exported the commons-logging.jar from the
>>>> Project Properties sheet. I've also added the jar to the Classpath
>>>> in the Runtime tab of the Manifest editor. Also, I've exported the
>>>> packages to all downstream plugins.
>>>>
>>>> Now my plugin abcPlugin has some (plain) Junit tests, which I can
>>>> run using Run > Run as Junit Plugin Test. There are no problems and
>>>> my code can find the classes from the commons-logging.jar
>>>>
>>>> Problem is when I Import the same tests TPTP Junit Plugin tests and
>>>> try to run then my code throws a Runtime NoClassDefFoundException.
>>>>
>>>> I tried to debug and found that in BundleLoader.class, in the method:-
>>>>
>>>> Class findClass(String name, boolean checkParent) throws
>>>> ClassNotFoundException
>>>>
>>>> after these lines:-
>>>>
>>>> // 4) search the required bundles
>>>> source = findRequiredSource(pkgName);
>>>>
>>>> the source variable:-
>>>> source > supplier > loader > classloader > classpathentries
>>>>
>>>> has the entry for commons-logging.jar in case of Junit Plugin Test
>>>> BUT
>>>> does not have any entry in case of TPTP Junit Plugin Test.
|
|
|
Powered by
FUDForum. Page generated in 0.07571 seconds