:08 PM
Subject: Re: Garbage Collection
> Hello Vibha!
>
> VJ> Hi,
>
> VJ> I am creating instances of dataclasses in my Servlets and JSPs.
> VJ> I am not explicitly setting them to null after use.
> VJ> Could this be a problem?
> VJ> I mean, would these obj
Hello Vibha!
VJ> Hi,
VJ> I am creating instances of dataclasses in my Servlets and JSPs.
VJ> I am not explicitly setting them to null after use.
VJ> Could this be a problem?
VJ> I mean, would these objects not be eligible for garbage collection or would
VJ> they be eligible?
t;
To: <[EMAIL PROTECTED]>
Sent: Thursday, January 31, 2002 11:46 AM
Subject: Re: Garbage Collection
> Hi,
>
> I was intereested in knowing the effect in Servlets and JSPs.
> I believe that the Servlets are destroyed as soon as they throw the JSP.
>
> And once the JSP dis
references to null.
Or do I need to ?
Regards,
Vibha
- Original Message -
From: Vikramjit Singh <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Thursday, January 31, 2002 9:32 AM
Subject: Re: Garbage Collection
> hi vibha,
>
> the objects will be eligible for garba
will become a
candidate for garbage collection.
I always do like this for resultsets, statements and connections in the
finally block. For more information on garbage collection you can read some
core java books.
finally
{
if (rs != null)
{
rs.close
Hi,
I am creating instances of dataclasses in my Servlets and JSPs.
I am not explicitly setting them to null after use.
Could this be a problem?
I mean, would these objects not be eligible for garbage collection or would
they be eligible?
Regards,
Vibha
bout Java Server Pages specification and reference
[mailto:[EMAIL PROTECTED]]On Behalf Of piyush jain
Sent: Thursday, May 03, 2001 11:49 PM
To: [EMAIL PROTECTED]
Subject: Re: Garbage collection issue - URGENT
Celeste,
I wanted to understand that if that is the case then should i explicitly run
the garbag
ference
[mailto:[EMAIL PROTECTED]]On Behalf Of Rathna
Sent: Friday, May 04, 2001 12:17 AM
To: [EMAIL PROTECTED]
Subject: Re: Garbage collection issue - URGENT
hi celeste,
In our application , we use large number of JSP's say around 300.
Will there be a problem for Jrun to load all the servlet
athna.
Celeste Haseltine wrote:
> Rathna,
>
> Please double check what I am about to say on the Allaire developer web
> site, but I think that you have a misunderstanding of how a JSP
> complier/interpreter works, which is what JRUN is.
>
> In Java, you do a have garbage col
lso i supp..
piyush.
- Original Message --
Celeste Haseltine <[EMAIL PROTECTED]> wrote:
To:[EMAIL PROTECTED]
From:Celeste Haseltine <[EMAIL PROTECTED]>
Date:Thu, 3 May 2001 09:46:22 -0500
Subject:Re: Garbage collection issue - URGENT
Rathna,
Please double chec
Hi all,
I wonder is there any garbage collection problem in Jrun 3.0 version.
we are using JDK 1.2.2 in jrun 3.0 version on solarix box. In the long
run
the application becomes very slow.we have 1GB of swap space
and after running the jrun(after several hit) the swap space reduced to
nearly
I am having similar problems,
We are using Websphere App Server to server JSP's,
System spec is a Pentium 2 500, with 550mb ram
We started with the default of 16 mb,
but soon found that we had the jsp failing, or timing out, after increasing
the jvm heap memory to 64mb this then allowed the serve
From: "Kathy Wargo" <[EMAIL PROTECTED]>
> we are developing a java application using servlet but after a few runs
the application slows down. We noticed that this happens once the JVM's heap
size reaches 16M. I would assume the garbage collection would be invoked and
cl
we are developing a java application using servlet but after a few runs the
application slows down. We noticed that this happens once the JVM's heap size reaches
16M. I would assume the garbage collection would be invoked and clear up the heap but
this does not seem to be happening. We
tempt to wake up the garbage
> collection thread, but doesn't guarantee that it will run at that
> instant.
> However, you're missing the real problem: if you are getting to the
> point that you may need to force a garbage collection you should
> either (a) manage the numb
That is correct. System.gc() will attempt to wake up the garbage collection thread, but doesn't guarantee that it will run at that instant.
However, you're missing the real problem: if you are getting to the point that you may need to force a garbage collection you should either (a)
This does not force garbage collection. It only suggests it. A key point to
remember for the Java certification exam is that there is no way to force
garbage collection. Garbage collection runs as a low priority thread and its
implementation is not strictly detailed in the Java specifications. So
If implemented correctly the destroy() method can at most
cleanly forget all
references so as to make them garbage collectable. It
doesn't call garbage
collection.
System.gc() also does not necessarily run the garbage
collection right there when
called. This call only tells the garbag
Actual, in Java the System.gc() is merely a suggestion. Garbage collection
will still only happen when "the time is right".
The destroy() method can be used to free up resources, but garbage
collection does not necessarily occur at that time. Again the VM is in
control of when G
Tao Kang wrote:
> No. You cannot force garbage collection.
No? What about java.lang.System.gc() ?
--
#
Pedro Teixeira
USD
Link<-
Tao Kang wrote:
No. You cannot force garbage collection. However, you can make an
object to become 'subject to'
garbage collect
order to avoid contention
with application threads). Even if this code doesn't hang you up entirely, it will
definitely kill your performance, unless you're in a single-threaded system.
I have heard that HotSpot implements an incremental garbage collection algorithm.
The gc is shrouded in
That doesn't FORCE garbage collection. Just suggests that if the GC would
like to run, it can.
-tg
- Original Message -
From: Pedro Teixeira <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Thursday, November 04, 1999 10:51 AM
Subject: Re: Garbage collection
try this code:
Runtime rt = Runtime.getRuntime( );
long isFree = rt.freeMemory( );
long wasFree;
do {
wasFree = isFree;
rt.gc( );
isFree = rt.freeMemory( );
}
while( isFree > wasFree );
rt.runFinalization( );
===
To
Garbage collection
(more of a java q, but seems fitting...)
Is there a way to force garbage collection, such as with delete in C++?
Phil
[EMAIL PROTECTED]]
> Reply To: Campbell
> Sent: Thursday, November 04, 1999 9:50 PM
> To: [EMAIL PROTECTED]
> Subject: Garbage collection
>
> (more of a java q, but seems fitting...)
>
> Is there a way to force garbage collection, such a
No. You cannot force garbage collection. However, you can make
an object to become 'subject to' garbage collection by making it
'unreachable.' (assigning the reference varaible to null, for
example)
Because the garbage collector runs asynchronously to your program a
and reference
[mailto:[EMAIL PROTECTED]]On Behalf Of CampbellSent:
Thursday, November 04, 1999 10:21 AMTo:
[EMAIL PROTECTED]Subject: Garbage
collection
(more of a java q, but seems
fitting...)
Is there a way to force garbage collection,
such as with delete in C
(more of a java q, but seems
fitting...)
Is there a way to force garbage collection, such
as with delete in C++?
Phil
28 matches
Mail list logo