Hi Should be fixed in upcoming 2.12.3 release.
On Tue, Feb 11, 2014 at 10:19 PM, florin <[email protected]> wrote: > Trying to use a Groovy script inside a Camel (version 12.2.1) validator I > encountered the problem that the validator returns always the result form > first evaluation (from first message) for subsequent messages. By looking > into the code (/org.apache.camel.builder.script.ScriptBuilder/) I noticed > that this is caused by calling /result = compiledScript.eval()/; in > /runScript/ method without passing as a parameter the recently updated > context (in /populateBindings /) and so the cached context from compilation > time(first execution) is always used. > A quick solution (for testing purpose) was to recompile the camel-scripting > component after changing the above mentioned call to /result = > compiledScript.eval(getScriptContext())/; > > > > ----- > Florin > -- > View this message in context: > http://camel.465427.n5.nabble.com/Groovy-compiled-scripts-cache-execution-context-tp5747131.html > Sent from the Camel - Users mailing list archive at Nabble.com. -- Claus Ibsen ----------------- Red Hat, Inc. Email: [email protected] Twitter: davsclaus Blog: http://davsclaus.com Author of Camel in Action: http://www.manning.com/ibsen Make your Camel applications look hawt, try: http://hawt.io
