Hello,
I am trying to use Hibernate 3 with JRun 4. I have developed an
application the works correctly on Tomcat 5.5, but when I try to load
the application on JRun 4, I receive the following exception:
- Configuration resource: /hibernate.cfg.xml
- Mapping resource: /com/timeinc/si/dcgold/db/Address.hbm.xml
Initial SessionFactory creation failed.org.hibernate.MappingException:
Resource: /com/timeinc/si/dcgold/db/Address.hbm.xml not found
10/18 16:15:20 error
[1]org.hibernate.MappingException: Resource:
/com/timeinc/si/dcgold/db/Address.hbm.xml not found
at
org.hibernate.cfg.Configuration.addResource(Configuration.java:447)
at
org.hibernate.cfg.Configuration.parseMappingElement(Configuration.java:1
263)
at
org.hibernate.cfg.Configuration.parseSessionFactory(Configuration.java:1
235)
[complete stack trace omitted]
In my war file, hibernate.cfg.xml is located in WEB-INF/classes, and
Address.hbm.xml is located in
WEB-INF/classes/com/timeinc/si/dcgold/db/Address.hbm.xml
The Hibernate source code that throws the exception is:
public Configuration addResource(String path) throws
MappingException {
log.info( "Mapping resource: " + path );
InputStream rsrc =
Thread.currentThread().getContextClassLoader().getResourceAsStream( path
);
if ( rsrc == null ) rsrc =
Environment.class.getClassLoader().getResourceAsStream( path );
if ( rsrc == null ) throw new MappingException( "Resource: "
+ path + " not found" );
[...]
I don't understand why the code from Hibernate would fail. Has anyone
encountered this problem? Is there an issue with the JRun classloader?
Any help would be greatly appreciated.
Thanks,
Sam Greenfield
Sports Illustrated
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Discover CFTicket - The leading ColdFusion Help Desk and Trouble
Ticket application
http://www.houseoffusion.com/banners/view.cfm?bannerid=48
Message: http://www.houseoffusion.com/lists.cfm/link=i:8:5727
Archives: http://www.houseoffusion.com/cf_lists/threads.cfm/8
Subscription: http://www.houseoffusion.com/lists.cfm/link=s:8
Unsubscribe:
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.8
Donations & Support: http://www.houseoffusion.com/tiny.cfm/54