We did find a memory leak for highly recursive sessions, which is fixed
in trunk, please try the latekst trunk snapshot here:
http://cruisecontrol.jboss.com/cc/artifacts/jboss-rules
Mark
Arjun Dhar wrote:
Hi,
I've been building a BRMS server over the Drools 4MR2 API.
The Server has a Boot process to allow to make it become a Rule server(s).
reads and XML configuration in which a user can specify the location of the
DRL, XLS, CVS, etc. During the Boot proocess it verifies thew authenticity of
each resource it loads. To sommarize:
<Session 1 type="Stateless">
<Rule Source 1>
<Rule Source 2>
..
<Adapter ExternalService class="..."/>
<Session>
<Session 2 type="Stateful">
<Rule Source 1>
<Rule Source 2>
..
<Session>
..well its more, but I guess this paints the picture.
It creates a Pool of Sessions. Now I know creating a Session is inexpensive,
but the process of creating them and authentication of resources etc. (Required
for prodcution quality system)
Once the server is up, requests are serviced. the request knows which session
it wants and facts are asserted per request. The request can be Synchronous or
Async and single or batch.
For testing I'm using: (JMeter test Case)
Session mode: STATELESS
Synchronous
Mode: Batch of 5 facts (composing of other objects (about 5) which are asserted
into the Session as well) at at a time
Loop: 10,000 <-- Does not matter how fast or slow I trow this at the engine
After the request is processed and results logged; Result and what rules led to
that result. I even nullify the top level Business obejcts. (a desperate
attempt to free memory)
After about 10,000 loops the System goes out of memory.
Sorry to bore you so far, but it was important you have the right context :o)
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.
All thats left is to build an RMI service with a console dameon shell to give
it the final touches. Once this is done i'd like to share the deisng with you
guys if you like it.
_______________________________________________
rules-users mailing list
rules-users@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/rules-users
_______________________________________________
rules-users mailing list
rules-users@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/rules-users