-->
These old forums are deprecated now and set to read-only. We are waiting for you on our new forums!
More modern, Discourse-based and with GitHub/Google/Twitter authentication built-in.

All times are UTC - 5 hours [ DST ]



Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 6 posts ] 
Author Message
 Post subject: Hibernate integration
PostPosted: Fri Mar 19, 2004 12:49 pm 
Newbie

Joined: Fri Mar 19, 2004 12:30 pm
Posts: 8
Hi,

I have an application 'B' that uses hibernate (db postgres) that is a module of another application say 'A' that uses jdbc-connectons defined in tomcat's server.xml (This application 'A" uses JDO's and implements DAO's and I have chosen postgres for this application). My Application 'A' works fine and I am able to retrieve and persist data as LONG AS I HAVE NOT INTEGRATED HIBERNATE WITH IT!. When I deploy my module 'B' module B works fine but i am cannot create/update or save anything henceforth for my Application 'A' I can only retrieve information. If I undeploy my hibernate module 'B' I have not problems with Application 'A' . I have created two different databases 'A' and 'B' on postgres but A uses JDBC connection and for 'B' I have specified the appropriate settings in hibernate.properties file. Can anybody help me out?

Regards,
Conrad.


Top
 Profile  
 
 Post subject:
PostPosted: Fri Mar 19, 2004 1:00 pm 
Newbie

Joined: Fri Mar 19, 2004 12:30 pm
Posts: 8
Just to add a bit my module 'A' uses javax.sql.datasource as the datasource for the JDBC
connections. However for "B" I use hibernate API for sessions after setting the apropriate hibernate config parameters and database settings for postgres.


Top
 Profile  
 
 Post subject: Regarding problem!
PostPosted: Mon Mar 22, 2004 7:20 am 
Newbie

Joined: Fri Mar 19, 2004 12:30 pm
Posts: 8
just found out that the jta.jar was causing the problem. I was gettin a Class Cast exception when I deployed my module 'B' (That runs on hibernate) in my deploy folder where Application 'A' resides. If I use java:comp/UserTransaction (wjic my main Application uses) everything works fine!.


Top
 Profile  
 
 Post subject:
PostPosted: Mon Mar 22, 2004 10:44 am 
Newbie

Joined: Fri Mar 19, 2004 12:30 pm
Posts: 8
I am assuming that tomcat 3.0 uses an older version of jta.jar. When I copied the jar files that comes with hibernate (including the jta.jar--I think this is a new version) into the deploy folder I assume that the class cast exception was being caused because of the version problem . When I deleted the jta.jar (the newer version) that was present in the lib folder file everything worked fine because it used the older tomcat's version.


Top
 Profile  
 
 Post subject:
PostPosted: Mon Mar 22, 2004 10:47 am 
Hibernate Team
Hibernate Team

Joined: Mon Aug 25, 2003 9:11 pm
Posts: 4592
Location: Switzerland
You are using Tomcat 3.0?

_________________
JAVA PERSISTENCE WITH HIBERNATE
http://jpwh.org
Get the book, training, and consulting for your Hibernate team.


Top
 Profile  
 
 Post subject:
PostPosted: Mon Mar 22, 2004 11:43 am 
Newbie

Joined: Fri Mar 19, 2004 12:30 pm
Posts: 8
Sorry!

i am using tomcat 4.0.3 version.


Top
 Profile  
 
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 6 posts ] 

All times are UTC - 5 hours [ DST ]


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
© Copyright 2014, Red Hat Inc. All rights reserved. JBoss and Hibernate are registered trademarks and servicemarks of Red Hat, Inc.