Singleton class issue 2004-11-18 - By Milind Patil
Back
Hi,
I agree with Partha. Even I have also faced same problem and we have used DAOFactory and separate DAO's. If you want to build a singleton class with a separate connection and related objects(statements,result sets), then you have to have separate objects holding separate references to each connection objects. In fact, once you used DAO instance you can make it null so it can garbage collected fast.
Milind Bhaskar Patil Tata Consultancy Services Limited Mailto: milind.patil@(protected) Website: http://www.tcs.com
DISCLAIMER: The information contained in this message is intended only and solely for the addressed individual or entity indicated in this message and for the exclusive use of the said addressed individual or entity indicated in this message (or responsible for delivery of the message to such person) and may contain legally privileged and confidential information belonging to Tata Consultancy Services Limited. It must not be printed, read, copied, disclosed, forwarded, distributed or used (in whatsoever manner) by any person other than the addressee. Unauthorized use, disclosure or copying is strictly prohibited and may constitute unlawful act and can possibly attract legal action, civil and/or criminal. The contents of this message need not necessarily reflect or endorse the views of Tata Consultancy Services limited on any subject matter. Any action taken or omitted to be taken based on this message is entirely at your risk and neither the originator of this message nor Tata Consultancy Services Limited takes any responsibility or liability towards the same. Opinions, conclusions and any other information contained in this message that do not relate to the official business of Tata Consultancy Services limited shall be understood as neither given nor endorsed by Tata Consultancy Services Limited or any affiliate of Tata Consultancy Services Limited. If you have received this message in error, you should destroy this message and may please notify the sender by e-mail. Thank you.
=========================================================================== To unsubscribe, send email to listserv@(protected) and include in the body of the message "signoff J2EE-INTEREST". For general help, send email to listserv@(protected) and include in the body of the message "help".
<br><font size=2 face="sans-serif">Hi,</font> <br> <br><font size=2 face="sans-serif">I agree with Partha. Even I have also faced same problem and we have used DAOFactory and separate DAO's. </font> <br><font size=2 face="sans-serif">If you want to build a singleton class with a separate connection and related objects(statements,result sets), then you have to have separate objects holding separate references to each connection objects.</font> <br><font size=2 face="sans-serif">In fact, once you used DAO instance you can make it null so it can garbage collected fast.</font> <br><font size=2 face="sans-serif"><br> Milind Bhaskar Patil<br> Tata Consultancy Services Limited<br> Mailto: milind.patil@(protected)<br> Website: http://www.tcs.com</font> <table><tr><td bgcolor=#ffffff><font color=#000000>DISCLAIMER: The information contained in this message is intended only and solely for the addressed individual or entity indicated in this message and for the exclusive use of the said addressed individual or entity indicated in this message (or responsible for delivery of the message to such person) and may contain legally privileged and confidential information belonging to Tata Consultancy Services Limited. It must not be printed, read, copied, disclosed, forwarded, distributed or used (in whatsoever manner) by any person other than the addressee. Unauthorized use, disclosure or copying is strictly prohibited and may constitute unlawful act and can possibly attract legal action, civil and/or criminal. The contents of this message need not necessarily reflect or endorse the views of Tata Consultancy Services limited on any subject matter.<br> Any action taken or omitted to be taken based on this message is entirely at your risk and neither the originator of this message nor Tata Consultancy Services Limited takes any responsibility or liability towards the same. Opinions, conclusions and any other information contained in this message that do not relate to the official business of Tata Consultancy Services limited shall be understood as neither given nor endorsed by Tata Consultancy Services Limited or any affiliate of Tata Consultancy Services Limited. If you have received this message in error, you should destroy this message and may please notify the sender by e-mail. <br> Thank you.<br> </font></td></tr></table> =========================================================================== To unsubscribe, send email to listserv@(protected) and include in the body of the message "signoff J2EE-INTEREST". For general help, send email to listserv@(protected) and include in the body of the message "help". <p>
|
|