The GC uses **incoming** references to determine the liveness of an
object and thus its eligibility for GC.
The code here makes sure that the internal ReteooStatefulSession is no
longer referenced by
the StatefulKnowldegeSessionImpl wrapper, making it eligible for GC
unless it's referenced somewhere else.
The StatefulKnowledgeSessionImpl itself now may or may not be reachable
anymore, depending on who
was holding references to it. In any case, it is now pointing to the
"Disposed" singleton, a mock, shared empty
object.
This said, you will need to provide more details about your
configuration and usage. Just knowing that
you have "hundreds of rules" does not help much in diagnosing the
problem... :)
Did your system work, say, in 5.4 and then started generating these
OOMEs after moving to 5.5?
Could the problem be reproduced systematically? What are your policies
for retracting facts OR expiring sessions?
See the previous messages in this thread for a list of other questions
you may want to answer...
Only then we may be able to provide some advice :)
Best
Davide
On 02/25/2013 09:35 PM, ismaximum wrote:
Not sure about this but I found this code in dispose() method in
stateful
session:
this.session.dispose();
this.session = DisposedReteooWorkingMemory.INSTANCE;
That means that the created session will never become eligible to be GCed,
instead it remains in memory pointing to the same instance (an instance of
DisposedReteooWorkingMemory)
I could be wrong... please correct me if I'm wrong!
--
View this message in context:
http://drools.46999.n3.nabble.com/rules-users-GC-Overhead-Limit-Exceeded-...
Sent from the Drools: User forum mailing list archive at
Nabble.com.
_______________________________________________
rules-users mailing list
rules-users(a)lists.jboss.org
https://lists.jboss.org/mailman/listinfo/rules-users