axis-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Martin Gainty" <>
Subject Re: Classloaders and JPA
Date Sun, 29 Oct 2000 01:56:22 GMT
Did you take a look at JibxService and JibxServiceClient (Service and ClientStub for JiBX respectively) from dennis

Get the compiled and deployed as .aar source located at

confirm by
*(change the host:port to your tomcat configuration)*

then Get client

compiled and execute the client pointing EPR to
change the host:port to your tomcat configuration

(I'll jump in for the hibernate configuration afterwards)

----- Original Message -----
From: "Leif Singer" <>
To: <>
Sent: Sunday, October 28, 2007 8:23 PM
Subject: Classloaders and JPA

> Hello,
> I'm trying to implement a simple Axis2 service using JPA. Its only
> operation is supposed to take a model object (e.g., a "Person") as its
> sole argument and persist it.
> I understand that each AAR uses a seperate classloader. Also, I
> believe I've read that the libraries I use (JPA, specifically) are
> being loaded by a different classloader than my AAR.
> The issue I'm having is this:
> 1. My service implementation can see my model classes and the
> persistence.xml.
> 2. JPA cannot see the persistence.xml in my AAR, no matter where I
> place it.
> 3. JPA cannot see my model classes in my AAR.
> I solved this by putting the persistence.xml into Tomcat's axis2/WEB-
> INF/classes/META-INF directory and putting my model classes into the
> axis2/WEB-INF/classes directory, i.e., outside the AAR.
> The trouble I have with this is that I want to have my AAR as self-
> contained as possible. I could live with a seperate persistence.xml --
> after all, it's configuration -- but would really like to have the
> model classes packaged into the AAR and *still* have JPA see them.
> Without a JEE container, is there a way to achieve this? What's
> considered a good practice to solve this?
> I use JiBX for un-/marhalling. I use Hibernate's JPA implementation. I
> tried this running in the SimpleAxisServer and Apache Tomcat 5.0.28.
> Thanks in advance
>    Leif Singer
> ---------------------------------------------------------------------
> To unsubscribe, e-mail:
> For additional commands, e-mail:

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message