Dear Attila

After removing call()/apply() the continuations seemed to work better. 
However, it still sometimes happens that Rhino crashes in 
exitActivationFunction(). Apparently, currentActivationCall  in Context 
becomes null leading to a NullPointerException. I changed 
exitActivationFunction() such that it does nothing if currentActivationCall 
is null and things seem to work fine. Any guess how I can run into this 
case?.

java.lang. NullPointerException
 at 
org.mozilla.javascript.ScriptRuntime.exitActivationFunction(ScriptRuntime.java:2937)
 at org.mozilla.javascript.Interpreter.exitFrame(Interpreter.java:4107)
 at org.mozilla.javascript.Interpreter.interpretLoop(Interpreter.java:3836)
 at org.mozilla.javascript.Interpreter.interpret(Interpreter.java:2394)
 at 
org.mozilla.javascript.InterpretedFunction.call(InterpretedFunction.java:162)
 at org.mozilla.javascript.ContextFactory.doTopCall(ContextFactory.java:393)
 at org.mozilla.javascript.ScriptRuntime.doTopCall(ScriptRuntime.java:2834)
 at 
org.mozilla.javascript.InterpretedFunction.exec(InterpretedFunction.java:173)

Thanks!
Regards, Thomas

"Attila Szegedi" <[EMAIL PROTECTED]> wrote in message 
news:[EMAIL PROTECTED]
>
> On 2007.11.23., at 9:47, Thomas wrote:
>
>> Dear Attila
>>
>> Sure, nothing is bug free and I really appreciate the effort you put 
>> into
>> Rhino.
>> Good to know that there are people already having experience with
>> continuations and serialization - I'm just starting to look into the
>> challenge of adding persistence support to my application.
>
> I have a quite elaborate system for serializing scopes with  continuations 
> in my Rhino-in-Spring project, see:
>
> <http://rhinoinspring.svn.sourceforge.net/viewvc/rhinoinspring/trunk/rhinoInSpring/src/java/org/szegedi/spring/web/jsflow/support/
> >
>
> Start from the FlowStateSerializer.java. Feel free to lift whatever  idea 
> or even verbatim code you like -- it's Apache licensed :-)  There's stuff 
> for custom serialization stubbing (i.e. my streams have  custom 
> resolveObject/replaceObject) of heavy but usually recreateable  objects, 
> i.e. bodies of functions loaded from a script file, global  beans in 
> Spring application contexts, and so on.
>
> Attila.
>
> --
> home: http://www.szegedi.org
> weblog: http://constc.blogspot.com
>
>>
>> Again, thanks for shedding light on this.
>>
>>
>> Regards, Thomas
>
>
>
> 


_______________________________________________
dev-tech-js-engine-rhino mailing list
[email protected]
https://lists.mozilla.org/listinfo/dev-tech-js-engine-rhino

Reply via email to