On Sat, 2003-08-30 at 15:20, Giacomo Pati wrote: > On Fri, 29 Aug 2003, Bruno Dumon wrote: > > > On Fri, 2003-08-29 at 19:55, Giacomo Pati wrote: > > > > if you add the following code before the closing bracket of the > > PooledExecutor.workerDone(...) method, then it --seems to-- work: > > > > if (!shutdown_) { > > if (poolSize_ < maximumPoolSize_) { > > Runnable r= null; > > try { > > r = getTask(); > > } catch (InterruptedException e) { > > e.printStackTrace(); > > } > > if (r != null) > > addThread(r); > > } > > } > > > > Could someone else also try this out? For your convenience, here's a > > compiled jar with this change: > > I've patched the 1.3.2 Doug Lea utils myself with your suggestion above > and can affirm it works now.
ok, thanks (Jeff/Antonio too). > > Cocoon compiled and tested with sun jdk 1.4.2 as well as sun jdk 1.3.1 > on Linux. To stop the Jetty running under 1.3.1 I needed two [Ctrl][C] > hits whereas the first hit reports "Shutdown hook executing" and after > the second one Jetty finally shuts down. If've made the tests with > Tomcat 4.1.27 as well where it behaves correctly as expected. > > Now, there is still the double Ctrl-C on jdk 1.3. Can you confirm this, > Bruno (or someone else with a Win$ machine)? On Linux/JDK1.3.1 I have this problem too. It has nothing to do with the CommandManager though (I'm really sure since I disabled the code). Maybe a Java or Jetty problem. > > Is someone on the Doug Lea list (if there is any) to report this? I've just sent him a message, I'll keep the list up-to-date on any news from him of course. > > I like the way how the Cornerstone Scheduler recently integrated by > Carsten more than the CommandManager way because of its > componentisation. Still, I like to see a Scheduler as a single component > definition in the xconf file. Today we need at least three component > definitions (Scheduler, ThreadManager, TimeScheduler) as well as one for > each Target. I think this can be made much easier, like: > > <scheduler logger="scheduler"> > <triggers> > <trigger name="mytarget" > class="my.comp.MyTarget" > logger="mytarget"> > <timed type="crontab"> > <month> -1 </month> > <weekday> SUN </weekday> > <day> * </day> > <hour> 9-17/2 </hour> > <minute> */5 </minute> > </timed> > ... > </triggers> > </scheduler> > > In the above, triggers are handled as Avalon components and the > scheduler takes care of instatiation and the lifecycle stuff. > > Unfortunately, the Cornerstone Scheduler toolkit doensn't offer a full > crontab like specification of defining trigger point in time like I've > used above (and I'd be happy to have). > > My suggestion (which I can implement if accepted) is to have a > Scheduler that is able to do the above by use of the CommandManager > given someone can fix Doug Leas concurrent utilities with the patch > from Bruno. great. -- Bruno Dumon http://outerthought.org/ Outerthought - Open Source, Java & XML Competence Support Center [EMAIL PROTECTED] [EMAIL PROTECTED]