Does your system support parallel execution of Java threads on multiple<br>processors? Otherwise I don&#39;t see how parallelization will gain much<br>since the Rete evaluation itself is clearly compile-time bound. <br><br>
How are you timing these 53ms? Does this include input time for your facts?<br>Frequently, much of a program&#39;s elapsed time is saved by adopting a<br>better i/o strategy.<br><br>Also, IIRC, there was the Utitilities method comparing times. Have you<br>
looked into possible speed gains there, i.e., what&#39;s the type of the<br>&quot;date&quot; attribute and how does that U-method work?<br><br>-W<br><br><br><div class="gmail_quote">On Tue, May 11, 2010 at 10:40 AM, djb <span dir="ltr">&lt;<a href="mailto:dbrownell83@hotmail.com">dbrownell83@hotmail.com</a>&gt;</span> wrote:<br>
<blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;"><br>
Hi Drools squad,<br>
<br>
This is a follow-up to my previous speed-related post.  By boss is still<br>
pushing to get 35ms down a bit, and I&#39;m looking at parallelization options.<br>
I&#39;ve looked through the forums, but not successfully...<br>
<br>
The options I see, are:<br>
<br>
1. KnowledgeBase partitioning (setting KnowledgeBaseConfiguration to use<br>
multi-threads)<br>
   - I tried this, and got the error pasted at the bottom.  My suspicion is<br>
that it starts a thread, and meanwhile the Java thread continues, and<br>
disposes of the session before evaluation is complete.<br>
<br>
2. Creating multiple Java threads, each of which starts its own<br>
KnowledgeSession.<br>
   - I started this, but need to confirm that this is possible.  What&#39;s<br>
happening currently, is that the Java thread continues, and closes my<br>
database connection prematurely, and so, I am working on adding some sort of<br>
counting-semaphore, to wait for all the threads to complete before<br>
continuing the Java thread.<br>
<br>
Should I pursue either of these ideas?  I will probably work on the second<br>
today.  The other idea I had was to try Sequential Mode, but I don&#39;t think<br>
my data is applicable to a StatelessKnowledgeSession.<br>
<br>
Thanks,<br>
Daniel<br>
<br>
<br>
***************************<br>
Partition task manager caught an unexpected exception: null<br>
Drools is capturing the exception to avoid thread death. Please report stack<br>
trace to development team.<br>
java.util.concurrent.RejectedExecutionException<br>
        at<br>
java.util.concurrent.ThreadPoolExecutor$AbortPolicy.rejectedExecution(ThreadPoolExecutor.java:1760)<br>
        at<br>
java.util.concurrent.ThreadPoolExecutor.reject(ThreadPoolExecutor.java:767)<br>
        at<br>
java.util.concurrent.ThreadPoolExecutor.ensureQueuedTaskHandled(ThreadPoolExecutor.java:758)<br>
        at<br>
java.util.concurrent.ThreadPoolExecutor.execute(ThreadPoolExecutor.java:655)<br>
        at<br>
org.drools.reteoo.PartitionTaskManager.enqueue(PartitionTaskManager.java:75)<br>
        at<br>
org.drools.reteoo.AsyncCompositeObjectSinkAdapter.doPropagateAssertObject(AsyncCompositeObjectSinkAdapter.java:49)<br>
        at<br>
org.drools.reteoo.CompositeObjectSinkAdapter.propagateAssertObject(CompositeObjectSinkAdapter.java:344)<br>
        at org.drools.reteoo.AlphaNode.assertObject(AlphaNode.java:147)<br>
        at<br>
org.drools.reteoo.PartitionTaskManager$FactAssertAction.execute(PartitionTaskManager.java:188)<br>
        at<br>
org.drools.reteoo.PartitionTaskManager$PartitionTask.run(PartitionTaskManager.java:112)<br>
        at<br>
java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)<br>
        at<br>
java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)<br>
        at java.lang.Thread.run(Thread.java:619)<br>
<font color="#888888"><br>
--<br>
View this message in context: <a href="http://drools-java-rules-engine.46999.n3.nabble.com/Parallelization-tp809341p809341.html" target="_blank">http://drools-java-rules-engine.46999.n3.nabble.com/Parallelization-tp809341p809341.html</a><br>

Sent from the Drools - User mailing list archive at Nabble.com.<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>
</font></blockquote></div><br>