On Wed, 10 Nov 2004, Berin Loritsch wrote:

Giacomo Pati wrote:

Vadim brought up the idea to contribute the Cocoon Event package replacement (RunnableManager) to Excalibur. Personally, I'm not sure about it as in the end we have the Event package back here in a different form. So, maybe you guys have a look at it at http://svn.apache.org/repos/asf/cocoon/trunk/src/java/org/apache/cocoon/components/thread/ and give us your thoughts about it.

OK, here is my surmizing of what is in that package:

1) It is a thin wrapper around the Doug Lea Concurrent library

Yup.

2) That makes it pretty close to Java5 java.util.concurrent stuff
3) The LinkedQueue will has race conditions waiting to happen with the
  size tracking--only use it with one thread at a time.

Hmm, you mean the insert method, right?

4) The RunnableManager is a lot of code without one test--it makes me
nervous.

Sure. Tests will follow.

For the most part it is a big departure from the Excalibur/D-Haven event
packages and it is pretty close to the Doug Lea Concurrent library.  I
can see some potential issues with synchronization--especially as it
relates to tracking queue size.

Where?

The RunnableManager is a non-trivial class that might actually be
better split up.

Any suggestions are welcome.

I highly recommend writing a bunch of test cases
with JUnit and Clover until the whole thing is covered by tests.
While I know Vadim does good work, it surprised me the number of
issues I found in my own code.

Don't blame Vadim about it, the RunnableManager is my s**t :-). Many thank for looking at it. I'd rather stick with the d-haven event package but the cocoon community has decided otherwise (you either know or can query theaimsgroup about it).


--
Giacomo Pati
Otego AG, Switzerland - http://www.otego.com
Orixo, the XML business alliance - http://www.orixo.com

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
Apache Excalibur Project -- URL: http://excalibur.apache.org/



Reply via email to