[
http://opensource.atlassian.com/projects/hibernate/browse/HHH-2317?page=c...
]
Jason Novotny commented on HHH-2317:
------------------------------------
I don't think I explained well enough-- here's the actual structure
webappA/WEB-INF/lib
+ hibernate-3.2.jar, cglib-x.jar, asm-*.jar, etc
+ PersistenceServiceImpl which acts as a wrapper around hibernate-- responsible for
loading in mapping files
webappB/
+ contains hibernate mapping files (no other jars)
shared/lib
+ PersistenceService interface
So webappB has access to the PersistenceService interface since it's in shared/lib,
but the actual impl is in webappA and has webapp A's classloader. To recap, if lazy is
false,then webappB can use the concrete PersistenceServiceImpl to load in the mapping
files in B. However, if lazy is true, then the proxies need to be created.
I then tried experimenting with Configuration.addResource(mappingFile, classLoader) in
the PersistenceServiceImpl so that it could use webapp B's classloader to locate its
mapping file and was greeted with this error:
Caused by: java.lang.NoClassDefFoundError: org/hibernate/proxy/HibernateProxy
at java.lang.ClassLoader.defineClass1(Native Method)
which seems in line with the reporter of
http://opensource.atlassian.com/projects/hibernate/browse/HHH-2318
In a nutshell I am trying to figure out any possible way where the hibernate and co. jars
do not need to be placed in every single webapp.
Thanks, Jason
CGLIB unable to lazy load classes in diff. classloader than
hibernate jars
---------------------------------------------------------------------------
Key: HHH-2317
URL:
http://opensource.atlassian.com/projects/hibernate/browse/HHH-2317
Project: Hibernate3
Type: Bug
Components: core
Versions: 3.2.1
Reporter: Jason Novotny
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://opensource.atlassian.com/projects/hibernate/secure/Administrators....
-
For more information on JIRA, see:
http://www.atlassian.com/software/jira