Java Mailing List Archive

http://www.junlu.com/

Google
Google
Mailing List
Home
Forum Home
JBoss - Java Application Server
Tomcat - JSP/Servlet container
Struts - A MVC web framework
iText - An open source PDF Java Library
JDOM - JDOM XML Parser
J2EE - A mailing list for Java(tm) 2 Platform, Enterprise Edition
J2EE Pattern - An interest list for Sun Java Center J2EE Pattern Catalog
JSP - A mailing list about Java Server Pages specification and reference
Servlet - A mailing list for discussion about Sun Microsystem's Java Servlet API Technology
Struts & Hibernate
Subjects
JSP editor plugin for eclipse ?
org apache jasper JasperException: Unable to compile class for JSP
Tomcat: Connection reset by peer: socket write error
Cannot retrieve definition for form bean null
Struts Tiles Tutorial (free Struts training)
Where do I download Tomcat 4 0 6?
Data Access Object (DAO) pattern, example DAO 's
Where to download Tomcat v 4 1 24 from?
Tomcat 5 0 16 Requested resource not available
Oracle Connection Pooling in 3 2 2
Servlet : Session invalidate
Servlet action is currently unavailable
Tomcat/Struts Unicode Encoding/Decoding problems
Tomcat and webapplication specific java library path
Running a Simple JMS Example
Mapping in workers2 properties
org apache jasper JasperException
Cannot find message resources under key org apache struts action
   MESSAGE
problem with html:text bean throwing exception
Cannot find message resources under key org apache struts action MESSAGE
invalid direct reference problem with solution
Tool for jsp debug Try Sysdeo Eclipse Plugin
Tomcat 5 Cannot load JDBC driver class 'null ' SQL state: null
weblogic ejbc
java properties file
Jboss 3 2 3 Coyote Can 't re
Tomcat 5, Apache2 and mod jk2 integration problem
JBoss example problem new to J2EE
url string for connecting jboss to oracle
Value attribute of <html:checkbox
javax servlet ServletException: BeanUtils populate
HTTP Status 404 The requested resource is not available
5 0 18: Windows XP Pro vs Windows 2000
 
Singleton class issue

Singleton class issue

2004-11-18       - By Milind Patil

 Back
Reply:     1     2     3     4     5  


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>

©2008 junlu.com - Jax Systems, LLC, U.S.A.