Learn how easy it is to sync an existing GitHub or Google Code repo to a SourceForge project! See Demo

Close

Memory leak in QueryThread

SerG
2006-10-27
2013-05-08
  • SerG
    SerG
    2006-10-27

    Hello, DiGIR developer team!

    I have collided with OutOfMemory exception when I tried to run large data volume through DiGIR. It happens in org.calacademy.digir.engine.QueryThread class after that lines while databuf variable is growing and growing:

    StringBuffer databuf = new StringBuffer();

                    while (true) {
                        data = buf.readLine();

    I had memory leak size is about 250 megabytes when response XML was about 30 megabytes. I have solved this problem using InputStreamReader like that:

    _spooler.add(new String(IOUtils.toByteArray(new InputStreamReader(is, "UTF-8"))));

    The questions are:
    1. Do you have more stable or new versions of DiGIR classes?
    2. Are the non-team developers have an access to DiGIR CVS repository to make such updates?

     
    • regiov
      regiov
      2007-02-05

      Hi,

      The most recent version of the portal engine is in CVS head, as far as I know.

      I have write access to the repository and I'll be happy to incorporate your changes. Can you send me (or post here) the exact patch?

      Thanks!
      --
      Renato