Just to strengthen Justy's comments,
If you are using JDK1.3 it doesn't hurt you to create beans per request
(even in case of lots of beans) because all these objects die young and they
are garbage collected by copying collector in object nursury itself which is
designed for very high garbage ratio. You can be pretty sure to see very
good performance inspite of the fact that you are creating lots of object. I
don't mean that you create lots of objects to get better performance :).
Regards,
Chandra Patni


-----Original Message-----
From: A mailing list about Java Server Pages specification and reference
[mailto:[EMAIL PROTECTED]]On Behalf Of horwat
Sent: Wednesday, June 13, 2001 1:43 PM
To: [EMAIL PROTECTED]
Subject: Re: How to get rid of objects ( beans) when the user abandons
the sit e


You can use the bean page scope to specify that the bean should exist for
the current page only. The gc will take care of a bean that is no longer
accessible. Note that each time the page is requested then an instance of
the bean is created.

Justy

----- Original Message -----

> HI all,
> My question is how to get rid of object ( to avoid memory leaks) when the
> user 'just' abandons the site
> is there any way I can detect when the user leaves the page so  I can
triger
> some kind of event to get rid of my objects?
>
> Please
> Help
> Thank you all
>
>
===========================================================================
> To unsubscribe: mailto [EMAIL PROTECTED] with body: "signoff
JSP-INTEREST".
> For digest: mailto [EMAIL PROTECTED] with body: "set JSP-INTEREST
DIGEST".
> Some relevant FAQs on JSP/Servlets can be found at:
>
>  http://java.sun.com/products/jsp/faq.html
>  http://www.esperanto.org.nz/jsp/jspfaq.html
>  http://www.jguru.com/jguru/faq/faqpage.jsp?name=JSP
>  http://www.jguru.com/jguru/faq/faqpage.jsp?name=Servlets
>

===========================================================================
To unsubscribe: mailto [EMAIL PROTECTED] with body: "signoff
JSP-INTEREST".
For digest: mailto [EMAIL PROTECTED] with body: "set JSP-INTEREST
DIGEST".
Some relevant FAQs on JSP/Servlets can be found at:

 http://java.sun.com/products/jsp/faq.html
 http://www.esperanto.org.nz/jsp/jspfaq.html
 http://www.jguru.com/jguru/faq/faqpage.jsp?name=JSP
 http://www.jguru.com/jguru/faq/faqpage.jsp?name=Servlets

===========================================================================
To unsubscribe: mailto [EMAIL PROTECTED] with body: "signoff JSP-INTEREST".
For digest: mailto [EMAIL PROTECTED] with body: "set JSP-INTEREST DIGEST".
Some relevant FAQs on JSP/Servlets can be found at:

 http://java.sun.com/products/jsp/faq.html
 http://www.esperanto.org.nz/jsp/jspfaq.html
 http://www.jguru.com/jguru/faq/faqpage.jsp?name=JSP
 http://www.jguru.com/jguru/faq/faqpage.jsp?name=Servlets

Reply via email to