tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Christopher Schultz <>
Subject Re: IOException while loading persisted sessions / java.lang.OutOfMemoryError: Java heap space
Date Tue, 02 Dec 2008 16:15:47 GMT
Hash: SHA1


Stefan Rainer wrote:
> we are running a Tomcat 5.0.28 on W2k Server with 2 GB RAM and JVM
> 1.5.0_11-b03 which is mainly used as application server for (Axis-based)
> SOAP Services.
> **** From time to time our Tomcat blows up to use almost the whole available
> RAM and finally it "crashes".

Hmm. Do your serialized objects have a lot of circular relationships?
I'm not sure if Java serialization has gotten any better over the years,
but I did a demo a few years ago with object graphs like:

A -> B
B -> A

When serializing object A, B goes with it. Upon de-serialization,
multiple A and B objects were recovered.

If this foolishness still happens with Java serialization, and you have
large objects (many MiB) being serialized via the session persistence
mechanism, you could bust your heap trying to re-load them due to the
behavior described above.

I would try to trim-down the contents of your session, or mark some
objects as transient or otherwise non-serializable.

- -chris
Version: GnuPG v1.4.9 (MingW32)
Comment: Using GnuPG with Mozilla -


To start a new topic, e-mail:
To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message