<br> The problem here is a different one. The engine is calling shutdown() on a thread pool and even without any task being executed, the thread is blocked in an internal JDK queue waiting for the timeout. I replaced the call by shutdownNow(), forcing the jdk to signal an interrupt to the thread and this seemed to work. I am investigating side effects of this procedure right now.<br>
<br> []s<br> Edson<br><br><br><div class="gmail_quote">2009/7/16 Mark Proctor <span dir="ltr"><<a href="mailto:mproctor@codehaus.org">mproctor@codehaus.org</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 class="im">Rafael Ribeiro wrote:<br>
> Hi all,<br>
><br>
> I've downloaded Drools fusion sample and started to make some changes to<br>
> the code (first of all wipe out the UI so I can test it easier).<br>
> I tried to get to a minimal set so I can run a console main class and see<br>
> what happens but I am facing a strange behaviour.<br>
> As soon as I start pushing events into the WorkingMemoryEntryPoint<br>
> ("StockTick stream") a Thread - not daemonized since it blocks shutdown from<br>
> ending - is spawned and this prevents my JVM from shutting down (obviously<br>
> if I call System.exit(0) it will but I am avoiding this).<br>
> I've tried both to halt and dispose the session that this entry point<br>
> belongs but with no success. Does anyone know how could I get rid of this<br>
> thread?<br>
><br>
</div>Drools is starting up threads in a number of places now - using "new<br>
Thread()". I think the plan is to change this to an interface call that<br>
allows pluggable implementations. So that the user can decide how<br>
threads are executed and stopped.<br>
<br>
Mark<br>
> best regards,<br>
<div class="im">><br>
<br>
<br>
_______________________________________________<br>
rules-users mailing list<br>
<a href="mailto:rules-users@lists.jboss.org">rules-users@lists.jboss.org</a><br>
</div><a href="https://lists.jboss.org/mailman/listinfo/rules-users" target="_blank">https://lists.jboss.org/mailman/listinfo/rules-users</a><br>
</blockquote></div><br><br clear="all"><br>-- <br> Edson Tirelli<br> JBoss Drools Core Development<br> JBoss by Red Hat @ <a href="http://www.jboss.com">www.jboss.com</a><br>