Arjun Dhar wrote:
QUESTION:: Is the session maintaining references to those objects ever after executing them? Why are the objects not being released? Specially I'd imagine for a STATELESS session (which is what I've set as default).

Using JMeter this system crashes every time under load, even with a single Thread. Clearly objects are not being released.

The error I get may help you: (Along with out of memory). This exception only comes under Load conditions.
Admin:ERROR: [com.myserver.brms.demos.certify.web.servlet.CertifyWebRequests]
[service] :org.drools.spi.ConsequenceException: java.lang.NullPointerException

        at org.drools.common.DefaultAgenda.fireActivation
(DefaultAgenda.java:501)

        at org.drools.common.DefaultAgenda.fireNextItem(DefaultAgenda.java:461)

        at org.drools.common.AbstractWorkingMemory.fireAllRules
(AbstractWorkingMemory.java:373)

        at org.drools.reteoo.ReteooStatelessSession.execute
(ReteooStatelessSession.java:72)

        at com.myserver.brms.sessions.RulesEngineSessionJBossRules4.execute
(RulesEngineSessionJBossRules4.java:113)
at
com.myserver.brms.services.execute.recore.batch.ExecuteSessionBatch.executeBatch
(ExecuteSessionBatch.java:160)

Please help me! This is the only downtime issue I face and unfortunatley its the most critical point of failure.


Ok, I think I figured it out. But please confirm.

The Rule Engine Session DOES NOT release objects. (But hten why have a Stateless session?) if the duration of use of the session is not going to be long?

The solution: Pool the RuleBase and on a request createa freesh session from it each time a request comes in!

Let me know if the cocept is sound or what I'm thinking is now correct.

Thanks,
Arjun




_______________________________________________
rules-users mailing list
rules-users@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/rules-users

Stateless sessions should not hold onto any references. Stateful do, and dispose() must be called when its finished - otherwise the rulebase holds a reference forever. If the rulebase is holding onto stateless sessions, then that is a bug.

Mark
_______________________________________________
rules-users mailing list
rules-users@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/rules-users

Reply via email to