Submitted On 04-APR-2003
s-koehler
does that mean, that a socket is never closed when it isn't
closed within the user-code?
Submitted On 15-APR-2003
cowwoc
I for one think this is retarded... This is likely to lead to leaky
channel issues. I *know* it is up to the developer to weed
these out but they are hard to locate and it makes a lot of
sense for the garbage collector to actually do its job and
clean up the resource.
In so far as performance is concerned, work on optimizing the
garbage collector so that *all* classes making use of
finalizers will run faster, instead of hacking Channel objects.
Submitted On 12-MAY-2003
xxiii
Please at least make sure that the javadoc in all relevent places indicates the need for the channels to be explicitly closed. Many people assume or rely on finalizers cleaning up native resources eventually (even though finalizers aren't guaranteed to run), especially when there is not specific documentation warning that they won't be.
Submitted On 01-JUL-2003
xtarka0
I would hope that the affected classes will register their new
instances with a PhantomReference subclass and a
ReferenceQueue. So that when the instance is reclaimed by
the garbage collector, any associated resources can be closed
when the PhantomReference is posted to the
ReferenceQueue. Otherwise, resource leaks may occur.
A PhantomReference with a ReferenceQueue is a better way
to track instance reclamation than finalize() methods.
PLEASE NOTE: JDK6 is formerly known as Project Mustang
|