Yes, David is correct. What I do in my Job is create a pool of WorkingMemories from the same RuleBase (we use StatefullSession) in order to increase the time of response.<br><br><div class="gmail_quote">2009/6/4 David Sinclair <span dir="ltr"><<a href="mailto:dsinclair@chariotsolutions.com">dsinclair@chariotsolutions.com</a>></span><br>
<blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">The Rulebase is thread safe, but individual sessions are not, regardless if it is a stateless or stateful. So your first suggestion, creating a new session for each call is correct. <br>
<br><div class="gmail_quote">2009/6/4 Meny Kobel <span dir="ltr"><<a href="mailto:meny.kobel@gmail.com" target="_blank">meny.kobel@gmail.com</a>></span><br>
<blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;"><div><div></div><div class="h5"><div dir="ltr">Hi,<br>I have a number of services(threads) sharing the same RuleBase instance.<br>
Each service is calling execute method and waiting for the results.<br>should each service call StatelessSession session = ruleBase.newStatelessSession() Or I can create one StatelessSession and share it between the services (probably will improve performance)?<br>
<br>Meny<br></div>
<br></div></div>_______________________________________________<br>
rules-users mailing list<br>
<a href="mailto:rules-users@lists.jboss.org" target="_blank">rules-users@lists.jboss.org</a><br>
<a href="https://lists.jboss.org/mailman/listinfo/rules-users" target="_blank">https://lists.jboss.org/mailman/listinfo/rules-users</a><br>
<br></blockquote></div><br>
<br>_______________________________________________<br>
rules-users mailing list<br>
<a href="mailto:rules-users@lists.jboss.org">rules-users@lists.jboss.org</a><br>
<a href="https://lists.jboss.org/mailman/listinfo/rules-users" target="_blank">https://lists.jboss.org/mailman/listinfo/rules-users</a><br>
<br></blockquote></div><br><br clear="all"><br>-- <br>Luis Enrique Silva Valdivieso<br>Cel. 00 51 1 991546707<br>Casa 00 51 1 4476616<br>