[prev in list] [next in list] [prev in thread] [next in thread]
List: batik-users
Subject: RE: Memory-Leaks in Batik
From: "Pepping, Florian" <florian.pepping () wincor-nixdorf ! com>
Date: 2006-12-20 7:00:44
Message-ID: E8CD91EBC59424468765F17B0BC0EA4162F981 () DEEXVS03 ! wincor-nixdorf ! com
[Download RAW message or body]
Hallo Thomas,
yeah you're right, that was not a memory-leak. After another few hours
of investigation I could verify, that the memory consumption always has
a limit. Although the behaviour of the garbage collector is very
strange. You have to wait up to half an hour, before the memory-limit is
reached (not mentioned, that the JConsole is a very helpful tool :-) )
Ok, thanks for your reply and pointing me into the right direction.
Florian
________________________________
From: thomas.deweese@kodak.com [mailto:thomas.deweese@kodak.com]
Sent: Tuesday, December 19, 2006 2:40 PM
To: batik-users@xmlgraphics.apache.org
Cc: batik-users@xmlgraphics.apache.org
Subject: Re: Memory-Leaks in Batik
Hi Pepping,
"Pepping, Florian" <florian.pepping@wincor-nixdorf.com> wrote on
12/19/2006 07:38:22 AM:
> once again a problem using batik:
> I have a JSVGCanvas and often load another SVG with canvas.
> setURI(svgFile.toURL().toString()); into it. The consequence is a
> more or less heavy memory-leak, whatever Batik-Version I use. The
> following observations can I report:
[...]
> It seems that the memory level settles down after a longer time
> (half an hour), however batik than uses more than 100MB or more
> of memory. Perhaps you can have a look at this behavior.
This doesn't sound like a problem. This is just how
Garbage Collection works.
In Java you don't delete/free memory, the JVM automatically
detects memory that is no longer referenced and free's it for
you. However this detection can be time consuming so it
generally doesn't look for work until memory is almost full.
So if memory consumption is settling then there isn't a memory
leak.
[Attachment #3 (text/html)]
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META http-equiv=Content-Type content="text/html; charset=us-ascii">
<META content="MSHTML 6.00.2900.2995" name=GENERATOR></HEAD>
<BODY>
<DIV dir=ltr align=left><SPAN class=040435406-20122006><FONT face=Arial
color=#0000ff size=2>Hallo Thomas,</FONT></SPAN></DIV>
<DIV dir=ltr align=left><SPAN class=040435406-20122006><FONT face=Arial
color=#0000ff size=2></FONT></SPAN> </DIV>
<DIV dir=ltr align=left><SPAN class=040435406-20122006><FONT face=Arial
color=#0000ff size=2>yeah you're right, that was not a memory-leak. After
another few hours of investigation I could verify, that the memory consumption
always has a limit. Although the behaviour of the garbage collector is very
strange. You have to wait up to half an hour, before the memory-limit is reached
(not mentioned, that the JConsole is a very helpful tool :-)
)</FONT></SPAN></DIV>
<DIV dir=ltr align=left><SPAN class=040435406-20122006><FONT face=Arial
color=#0000ff size=2></FONT></SPAN> </DIV>
<DIV dir=ltr align=left><SPAN class=040435406-20122006><FONT face=Arial
color=#0000ff size=2>Ok, thanks for your reply and pointing me into the right
direction.</FONT></SPAN></DIV>
<DIV dir=ltr align=left><SPAN class=040435406-20122006><FONT face=Arial
color=#0000ff size=2></FONT></SPAN> </DIV>
<DIV dir=ltr align=left><SPAN class=040435406-20122006><FONT face=Arial
color=#0000ff size=2>Florian</FONT></SPAN></DIV><BR>
<DIV class=OutlookMessageHeader lang=de dir=ltr align=left>
<HR tabIndex=-1>
<FONT face=Tahoma size=2><B>From:</B> thomas.deweese@kodak.com
[mailto:thomas.deweese@kodak.com] <BR><B>Sent:</B> Tuesday, December 19, 2006
2:40 PM<BR><B>To:</B> batik-users@xmlgraphics.apache.org<BR><B>Cc:</B>
batik-users@xmlgraphics.apache.org<BR><B>Subject:</B> Re: Memory-Leaks in
Batik<BR></FONT><BR></DIV>
<DIV></DIV><BR><FONT face=sans-serif size=2>Hi Pepping,</FONT> <BR><BR><FONT
size=2><TT>"Pepping, Florian" <florian.pepping@wincor-nixdorf.com> wrote
on 12/19/2006 07:38:22 AM:<BR><BR>> once again a problem using batik:
<BR>> I have a JSVGCanvas and often load another SVG with canvas.<BR>>
setURI(svgFile.toURL().toString()); into it. The consequence is a <BR>> more
or less heavy memory-leak, whatever Batik-Version I use. The <BR>> following
observations can I report:</TT></FONT> <BR><FONT size=2><TT>
[...]</TT></FONT> <BR><FONT size=2><TT>> It seems that the memory
level settles down after a longer time </TT></FONT><BR><FONT size=2><TT>>
(half an hour), however batik than uses more than 100MB or more
</TT></FONT><BR><FONT size=2><TT>> of memory. Perhaps you can have a look at
this behavior.</TT></FONT> <BR><BR><FONT size=2><TT> This doesn't
sound like a problem. This is just how</TT></FONT> <BR><FONT
size=2><TT>Garbage Collection works. </TT></FONT> <BR><BR><FONT
size=2><TT> In Java you don't delete/free memory, the JVM
automatically </TT></FONT><BR><FONT size=2><TT>detects memory that is no longer
referenced and free's it for </TT></FONT><BR><FONT size=2><TT>you. However
this detection can be time consuming so it </TT></FONT><BR><FONT
size=2><TT>generally doesn't look for work until memory is almost full.
</TT></FONT><BR><FONT size=2><TT>So if memory consumption is settling then there
isn't a memory </TT></FONT><BR><FONT size=2><TT>leak.</TT></FONT>
<BR></BODY></HTML>
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic