aspose file tools
The moose likes EJB and other Java EE Technologies and the fly likes Logging Database Connectivity Errors Big Moose Saloon
  Search | Java FAQ | Recent Topics
Register / Login
JavaRanch » Java Forums » Java » EJB and other Java EE Technologies
Reply Bookmark "Logging Database Connectivity Errors" Watch "Logging Database Connectivity Errors" New topic
Author

Logging Database Connectivity Errors

Kishore Chintalpati
Greenhorn

Joined: Oct 14, 2005
Posts: 9
hi,

In case there is a database failure in CMP entity bean, or the database is down for sometime and a transaction is made by a user, then it should log that the database was down for some �X� reason in a flat file. But in CMP there is a problem that it always abstracts the Database failure issues. Suppose a transaction is made, then the session bean tries to call the finder methods or create method on entity bean � Which simply in CMP throw a FinderException or CreateException and not the SQLException, (But its possible in BMP where we manually establish the database connection by writing the JDBC code) bcos SQL related issues are handled internally by the server� I would appreciate if anyone could let me know the possible errors in case of a database connectivity problem. Also, how should one catch those errors.

Thanks
Kishore
Ådne Brunborg
Ranch Hand

Joined: Aug 05, 2005
Posts: 208
Sounds like this is something that should be found in the server/container documentation.


Entia non sunt multiplicanda praeter necessitatem
 
I agree. Here's the link: http://zeroturnaround.com/jrebel - it saves me about five hours per week
 
subject: Logging Database Connectivity Errors
 
Similar Threads
Complex primary key
long post IBM.158
ejb transaction and threading issues
When not to use EJB?
My SCEA Part 1Study Notes