You are viewing a plain text version of this content. The canonical link for it is here.
Posted to java-user@axis.apache.org by Anthony Bull <an...@bcsoft.co.nz> on 2007/08/16 06:13:56 UTC

jar files within aar file

Hi, In the Axis 2 (1.2) services I have been developing, I cannot seem 
to use classes that are within jar files inside my .aar service archives.

In my Skeleton method handlers, I call class X which exists in the same 
aar file as the Skeleton class, inside a jar file in the lib folder, and 
I get class def not found errors. 

If I stick that jar file in the axis2/WEB-INF/lib folder, my Skeleton 
class picks it up and runs fine. This is not acceptable due to the need 
to have multiple services running that potentially could use different 
versions of the same jar.

Note that if I explode my web service, once the service has been loaded, 
both the version in the WEB-INF/lib folder and the version in the 
exploded service are locked by the Tomcat - so the jar inside my aar is 
being loaded, but it seems to be by a different classloader to the one 
loading the class files in my service.

I have set everything up in the standard way, as per the Axis 2 1.2 
documentation.

Has anyone had this problem also, or does anyone know what I could be 
doing wrong? Is it something to do with classloaders?

cheers,
Ants.

-- 
Anthony
-------------------------------------
Anthony Bull
Senior Developer
Black Coffee Software Ltd
PO Box 10-192 The Terrace
Wellington, New Zealand

anthony.bull@bcsoft.co.nz
Ph  +64 4 472 8818
Fax +64 4 472 8811
Mobile 021 303 692
-------------------------------------
www.bcsoft.co.nz
---------------------------------------------------------------
This email may contain confidential or privileged information,
and is intended for use only by the addressee, or addressees.
If you are not the intended recipient please advise the sender
immediately and do not copy, use or disclose the contents to
any other person or organisation.
Black Coffee Software Ltd accepts no responsibility for viruses
received with this email, or to any changes made to the original
content. Any views or opinions expressed in this email may be
personal to the sender and are not necessarily those of Black
Coffee Software Ltd.
---------------------------------------------------------------



---------------------------------------------------------------------
To unsubscribe, e-mail: axis-user-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-user-help@ws.apache.org


Re: jar files within aar file

Posted by Lahiru Sandakith <sa...@gmail.com>.
Hi Anthony,
Seems you are doing nothing wrong.
Please raise a JIRA @ http://issues.apache.org/jira/browse/AXIS2 with your
deployment/environment details
BTW did you tried with latest Axis2 1.3?
Thanks
Lahiru

On 8/16/07, Anthony Bull <an...@bcsoft.co.nz> wrote:
>
> Hi, In the Axis 2 (1.2) services I have been developing, I cannot seem
> to use classes that are within jar files inside my .aar service archives.
>
> In my Skeleton method handlers, I call class X which exists in the same
> aar file as the Skeleton class, inside a jar file in the lib folder, and
> I get class def not found errors.
>
> If I stick that jar file in the axis2/WEB-INF/lib folder, my Skeleton
> class picks it up and runs fine. This is not acceptable due to the need
> to have multiple services running that potentially could use different
> versions of the same jar.
>
> Note that if I explode my web service, once the service has been loaded,
> both the version in the WEB-INF/lib folder and the version in the
> exploded service are locked by the Tomcat - so the jar inside my aar is
> being loaded, but it seems to be by a different classloader to the one
> loading the class files in my service.
>
> I have set everything up in the standard way, as per the Axis 2 1.2
> documentation.
>
> Has anyone had this problem also, or does anyone know what I could be
> doing wrong? Is it something to do with classloaders?
>
> cheers,
> Ants.
>
> --
> Anthony
> -------------------------------------
> Anthony Bull
> Senior Developer
> Black Coffee Software Ltd
> PO Box 10-192 The Terrace
> Wellington, New Zealand
>
> anthony.bull@bcsoft.co.nz
> Ph  +64 4 472 8818
> Fax +64 4 472 8811
> Mobile 021 303 692
> -------------------------------------
> www.bcsoft.co.nz
> ---------------------------------------------------------------
> This email may contain confidential or privileged information,
> and is intended for use only by the addressee, or addressees.
> If you are not the intended recipient please advise the sender
> immediately and do not copy, use or disclose the contents to
> any other person or organisation.
> Black Coffee Software Ltd accepts no responsibility for viruses
> received with this email, or to any changes made to the original
> content. Any views or opinions expressed in this email may be
> personal to the sender and are not necessarily those of Black
> Coffee Software Ltd.
> ---------------------------------------------------------------
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: axis-user-unsubscribe@ws.apache.org
> For additional commands, e-mail: axis-user-help@ws.apache.org
>
>


-- 
Thanks
Lahiru Sandakith

http://sandakith.wordpress.com/
GPG Key Fingerprint : 8CD8 68E0 4CBC 75CB 25BC  1AB1 FE5E 7464 1F01 9A0F