"Memory leak" in javax.xml.xpath.XPath

M

Marvin_123456

Hello,

I am using javax.xml.xpath.XPath in a servlet to evaluate expressions
on a DOM. The servlet then creates a html page from the results. Just
reloading the page, i.e. executing all xpath expressions on DOM again,
increases the memory consumption of the VM for some MB. This memory is
never deallocated. As this occurs with every page reload, sooner or
later, Java runs out of memory, only depending on the heap size
settings.
The same problem occurs using DocumentBuilder.parse().
Does anybody know these problems and can give a hint how to solve or
workaround it?

Thanks,
Marvin_123456
 
J

jan V

I am using javax.xml.xpath.XPath in a servlet to evaluate expressions
on a DOM.

I so wish there was comp.lang.java.web.xml group when I read stuff like
this...
increases the memory consumption of the VM for some MB. This memory is
never deallocated. As this occurs with every page reload, sooner or
later, Java runs out of memory, only depending on the heap size
settings.
The same problem occurs using DocumentBuilder.parse().
Does anybody know these problems and can give a hint how to solve or
workaround it?

File a bug report for starters... ?
 
M

Marvin_123456

Hi Jan,

unfortunately, your answer didn't help me in solving this problem.
However, with regard to your "group-problem": I would recommend that
you initiate a new group named comp.lang.java.web.xml... Probably it is
explained somewhere how this works for starters...

Any constructive solutions are welcome!
 
T

Thomas Hawtin

jan said:
File a bug report for starters... ?

But make sure you file it with the right people. You server may not be
using the default implementation supplied with the JRE. Sun's JRE uses
an Apache implementation, IIRC, so you might get a better response
through Apache than Sun.

Tom Hawtin
 
J

jan V

Any constructive solutions are welcome!

Filing a bug report was meant to be constructive... having the original
authors of the bug fix the bug sounds like a quality solution to me (*may*
be too slow for your schedule, but that's a different issue)
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,733
Messages
2,569,439
Members
44,829
Latest member
PIXThurman

Latest Threads

Top