You are viewing a plain text version of this content. The canonical link for it is here.
Posted to batik-dev@xmlgraphics.apache.org by bu...@apache.org on 2009/03/23 17:48:59 UTC
DO NOT REPLY [Bug 46894] New: CSS scanner keeps multiple file
handles to UserAgentStyleSheet.css open
https://issues.apache.org/bugzilla/show_bug.cgi?id=46894
Summary: CSS scanner keeps multiple file handles to
UserAgentStyleSheet.css open
Product: Batik
Version: 1.7
Platform: All
OS/Version: All
Status: NEW
Severity: normal
Priority: P2
Component: CSS
AssignedTo: batik-dev@xmlgraphics.apache.org
ReportedBy: m.kaeser@exxcellent.de
Created an attachment (id=23399)
--> (https://issues.apache.org/bugzilla/attachment.cgi?id=23399)
Diffs for Parser.java and Scanner.java
Our software uses the CSS component of Batik. It's executed on a dedicated
server system. Several times a big number of file handles (> 100) to the Batik
resource file UserAgentStyleSheet.css remained open, that forced us to restart
the server.
We managed to track down the problem in the Batik source code:
In SVGDOMImplementation and SVG12DOMImplementation the above mentioned resource
file is parsed, which leads to
org.apache.batik.css.parser.Parser.parseStyleSheet(InputSource source). At the
beginning of this method a Scanner instance is created but at the end it isn't
destroyed (only set to null). The org.apache.batik.css.parser.Scanner holds an
instance of org.apache.batik.util.io.NormalizingReader that needs to be closed
to free the file handle.
As the scanner and the reader are not destroyed after the end of their usage,
the freeing of the file handle relies on the Java garbage collector. Especially
on server systems with lots of resources this can take a long time.
To improve the performance in this respect we applied a patch to our version of
Batik (based on batik-src-1.7.zip). With this post we send you unifed diff
files for Parser.java and Scanner.java. We would really appreciate it if you
could include a fix for this matter in the next version of Batik.
--
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.
---------------------------------------------------------------------
To unsubscribe, e-mail: batik-dev-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: batik-dev-help@xmlgraphics.apache.org
DO NOT REPLY [Bug 46894] [PATCH] CSS scanner keeps multiple file
handles to UserAgentStyleSheet.css open
Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=46894
David Chwalisz <dc...@fsc.follett.com> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |dchwalisz@fsc.follett.com
--
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.
---------------------------------------------------------------------
To unsubscribe, e-mail: batik-dev-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: batik-dev-help@xmlgraphics.apache.org
DO NOT REPLY [Bug 46894] [PATCH] CSS scanner keeps multiple file
handles to UserAgentStyleSheet.css open
Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=46894
Martin Kaeser <m....@exxcellent.de> changed:
What |Removed |Added
----------------------------------------------------------------------------
Keywords| |PatchAvailable
Summary|CSS scanner keeps multiple |[PATCH] CSS scanner keeps
|file handles to |multiple file handles to
|UserAgentStyleSheet.css |UserAgentStyleSheet.css
|open |open
--
Configure bugmail: https://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.
---------------------------------------------------------------------
To unsubscribe, e-mail: batik-dev-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: batik-dev-help@xmlgraphics.apache.org