[jbpm-dev] [Design of JBoss jBPM] - Re: statefull vs stateless delegation classes

koen.aers@jboss.com do-not-reply at jboss.com
Thu Feb 19 10:26:03 EST 2009


Actually, since at this moment the handler classes are instantiated at each use and thrown away afterwards, the use of them is stateless by definition. So if users use instance variables (fields) to hold variables temporarily they can somehow always be refactored as local variables in the execute method (or maybe as method calls in some superclass as in Robert's case). In these cases the change will indeed not be backwards compatible. The question is whether the performance gain of being able to cache these action handlers is worth the incompatibility. In my opinion it is. Of course, action handlers need to clearly be documented as stateless if we perform this change.

Cheers,
Koen

View the original post : http://www.jboss.org/index.html?module=bb&op=viewtopic&p=4211516#4211516

Reply to the post : http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=4211516



More information about the jbpm-dev mailing list