BorlandTalk.com Forum Index BorlandTalk.com
Borland discussion newsgroups
 
Archives   FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

Memory leaks with dbswing

 
Post new topic   Reply to topic    BorlandTalk.com Forum Index -> JBuilder DB Swing
View previous topic :: View next topic  
Author Message
John T. Dow
Guest





PostPosted: Mon Mar 19, 2007 9:01 pm    Post subject: Memory leaks with dbswing Reply with quote



I'm using JBuilder2006 with Java 1.5.0_10 trying to clear up memory leaks
that prevent my application from running continuously for more than a few
hours.

The program can create many list boxes, all using the same library method
I wrote. This method reads a file with specifications for each list box
and then creates a JDialog with a JdbTable and a QueryDataSet with a
dynamically generated query and sort, making appropriate buttons visible,
etc.

The runtime configuration I am using at present these vm parameters so I
get a heap dump.

-Xms4m -Xmx128m -Xrunhprof:file=dump.hprof,format=b

I then use HAT to look at the heap.

After bringing up a list box several times, there are many cases of
"unintentional object retention", the worst cases being many hundreds
each of com.borland.dx.dataset.RowVariant and
com.borland.dx.dataset.Column.

When I google for this type of problem, I see discussions going back
several years. It seems that the programmer has had to explicitly undo
the JdbTable (listeners, adding it inside a scrollpane, etc). I am
wondering if any of those problems have been fixed - ie what is the
current status?

Is there some document that describes what dbSwing does now and how to
avoid memory leaks? How to read the HAT reports to know what to fix?

I've been working on this but I'm wasting precious time and not making
much progress. I don't know if I'm totally missing something about how to
close or dispose of things so there are no objects left behind.

John
Back to top
Kevin Dean [TeamB]
Guest





PostPosted: Tue Mar 20, 2007 12:16 am    Post subject: Re: Memory leaks with dbswing Reply with quote



John T. Dow wrote:

Quote:
I am
wondering if any of those problems have been fixed - ie what is the
current status?

Unfortunately, DataExpress and dbSwing have not been updated for a very
long time and there doesn't appear to be much hope that they they ever
will be. Your frustration is shared by many, including myself.

--
Kevin Dean [TeamB]
Dolphin Data Development Ltd.
http://www.datadevelopment.com/

Please see Borland's newsgroup guidelines at
http://info.borland.com/newsgroups/guide.html
Back to top
John T. Dow
Guest





PostPosted: Tue May 01, 2007 10:59 pm    Post subject: Re: Memory leaks with dbswing Reply with quote



"Kevin Dean [TeamB]" <NkOdSePaAnM (AT) datadevelopment (DOT) com> wrote in
news:xn0f3w8k93f7yj4000-kdean (AT) www (DOT) teamb.com:

Quote:
John T. Dow wrote:

I am
wondering if any of those problems have been fixed - ie what is the
current status?

Unfortunately, DataExpress and dbSwing have not been updated for a very
long time and there doesn't appear to be much hope that they they ever
will be. Your frustration is shared by many, including myself.


The memory leak was caused by creating objects (such as JDialog and all the
components on it) from within actionPerformed, such as a button click or a
menu choice. I fixed it by doing invokeLater to create the dialog.

John
Back to top
Display posts from previous:   
Post new topic   Reply to topic    BorlandTalk.com Forum Index -> JBuilder DB Swing All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2006 phpBB Group
SEO toolkit © 2004-2006 webmedic.