You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@camel.apache.org by "Christian Müller (JIRA)" <ji...@apache.org> on 2014/12/31 14:12:13 UTC
[jira] [Commented] (CAMEL-8201) NPE with language:ruby and
concurrentConsumers
[ https://issues.apache.org/jira/browse/CAMEL-8201?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14262159#comment-14262159 ]
Christian Müller commented on CAMEL-8201:
-----------------------------------------
By updating the route as following:
{noformat}
return new RouteBuilder() {
public void configure() throws Exception {
getContext().getProperties().put(Exchange.REUSE_SCRIPT_ENGINE, "true");
getContext().getProperties().put(Exchange.COMPILE_SCRIPT, "true");
from("seda:jruby?concurrentConsumers=5")
.to("language:ruby:puts $request.body;result = $request.body?cacheScript=true")
.to(resultEndpoint);
}
};
{noformat}
I could run the test without any errors with the same performance (1500ms). May this is the solution you are looking for.
However, I will have a look and check why it's not working if we don't cache the script...
> NPE with language:ruby and concurrentConsumers
> -----------------------------------------------
>
> Key: CAMEL-8201
> URL: https://issues.apache.org/jira/browse/CAMEL-8201
> Project: Camel
> Issue Type: Bug
> Components: camel-script
> Affects Versions: 2.12.5, 2.13.3, 2.14.1
> Reporter: Christian Müller
> Assignee: Christian Müller
> Fix For: 2.13.4, 2.14.2, 2.15.0
>
> Attachments: RubyScriptTextTest.java
>
>
> See http://camel.465427.n5.nabble.com/NPE-with-language-ruby-and-concurrentConsumers-td5759703.html for details.
> By running git bisect, it reports the first bad commit was:
> f66375e91e2755e956c1527752c255aa2d0f8c42 is the first bad commit
> commit f66375e91e2755e956c1527752c255aa2d0f8c42
> Author: Willem Jiang <ni...@apache.org>
> Date: Fri Jul 26 16:46:50 2013 +0800
> CAMEL-6559 fixed the script builder synchronized the operation of evaluateScript issue
> :040000 040000 148db9cc9e521c7951be27c1416c7218880d10cf 5f55cbb6798f9a0f8477348708360a7a09a98f5e M components
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)