Mark Lundquist wrote:
Hi,

I posted this on the users list a few days ago, but never got a definitive answer (I did find out that this is *not* the case for javaflow :-), but that's not really an answer... I want to know if it *is* the case for flowscript).

cheers,
—ml—

Begin forwarded message:

From: Mark Lundquist <[EMAIL PROTECTED]>

On Aug 1, 2006, at 1:46 PM, [EMAIL PROTECTED] wrote:

You're saying that flow calls in concurrently received requests within
a session are processed serially, not in parallel threads?  Is that
right?

That's pretty much it in a nutshell, yes.

wow...

Is there a developer around who can confirm/refute the above?

I guess that's right, see the code of the FOM_JavascriptInterpreter line 563 (in trunk):

ThreadScope thrScope = getSessionScope();
synchronized (thrScope) {
   ClassLoader savedClassLoader =
       Thread.currentThread().getContextClassLoader();
    FOM_Cocoon cocoon = null;
    try {
       try {
           setupContext(redirector, context, thrScope);
           cocoon = (FOM_Cocoon) thrScope.get("cocoon", thrScope);

I remember that we had concurrency issues with Rhino a long time ago. It might be that they have gone in the meantime with Rhino 1.6. If concurrency is really an issue for you, experimenting with synchronization is definitly worth a try.

But note that synchronization is done based on the thread scope object. AFAIU every user has a thread scope per session _and_ per sitemap. That means that only requests to the same sitemap and the same session are blocking.

--
Reinhard Pötz Independent Consultant, Trainer & (IT)-Coach
{Software Engineering, Open Source, Web Applications, Apache Cocoon}

                                       web(log): http://www.poetz.cc
--------------------------------------------------------------------

        

        
                
___________________________________________________________ Der frühe Vogel fängt den Wurm. Hier gelangen Sie zum neuen Yahoo! Mail: http://mail.yahoo.de

Reply via email to