Hi, I have a question in handling StaleConnectionException in DAO called from EJB. I have a stateless sessionbean.The bean calls a Helper class and the Helper class calls the DAO class. In the DAO class, I have a while loop in each DAO methods.Within the while loop,I get the datasource and from it,I get the connection. I catch the StaleConnectionException when the executequery() method fails. If StaleConnectionException is caught, the while loop will continue (fiveattempts) until it gets the connection and executes the query successfully.
I was told that the retry logic to get the connection when a staleconnectionexception occured must be handled in EJB or EJB client class. And, not in DAO class. Is that correct? Does the above method has any drawbacks? Please let me know. Thanks, =========================================================================== To unsubscribe, send email to [EMAIL PROTECTED] and include in the body of the message "signoff EJB-INTEREST". For general help, send email to [EMAIL PROTECTED] and include in the body of the message "help".