> From: Stefan Riegel [mailto:stefan.rie...@telig.de] > Subject: Re: Random Connection Closed Exceptions - Question > to the code example > > So both code examples are correct, but the one in the > docs minimizes resource usage?
Yes - but really only if there is additional processing necessary after the ResultSet has been processed. If you don't have anything else to do after going through the ResultSet, then I would do the close() calls only in the finally block (but I'd certainly put some comments in the try block saying why it's done that way). - Chuck THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus for use only by the intended recipient. If you received this in error, please contact the sender and delete the e-mail and its attachments from all computers. --------------------------------------------------------------------- To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org