cocoon-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Tony Collen <>
Subject Re: Endless Looping in Flow
Date Thu, 28 Oct 2004 21:26:23 GMT
Brent Johnson wrote:

> I've got a page where the user can modify something (the title of an
> XML document in this case).  Here's what I'm doing in the flowscript:
> So there's an infinite loop there.  Is that going to be a problem? 
> See there's really no "end" to this flow.  As long as they're sitting
> on the layout manager page they're wanting to "do" something.  The
> only end to this continuation would be when they clicked on some other
> page rather than clicking "Set Title" or something similar.
> Anyone have any thoughts on this?  Will this continually eat up
> resources as time goes on or anything?

Well, it won't keep running because the execution is halted on 
sendPageAndWait().  My only guess is if there's a memory leak in Rhino, 
but it seems fine.  If you're really paranoid you could add a "quit" 
function that breaks out of the loop, but it should be fine.  From what 
I've seen, a lot of Flowscript makes use of while(true) to keep doing 
something over and over.   It might be better to do while (!done)  and 
set done=true when the person signals they're done with whatever process.


To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message