Re: SEDA Request Reply
Hi So if I have the following 2 routes: from(SomeEndpoint).to(seda:endpoint); from(seda:endpoint.to(SomeOtherpoint); I have not specified the exchange pattern for the SEDA endpoint. Hence, does it default to something? Thanks -- View this message in context: http://camel.465427.n5.nabble.com/SEDA-Request-Reply-tp5715275p5715326.html Sent from the Camel - Users mailing list archive at Nabble.com.
Re: SEDA Request Reply
It depends on SomeEndpoint... The message exchange pattern (MEP) is bound to the exchange, not the enpoint itself. Each component has a default MEP which is e.g. InOnly for the File Component, InOut for the HTTP Component, ... This MEP is used by creating the exchange in the component which receives the request first. The MEP will only change if you explicitly define it, e.g. by using inOnly(xxx) instead of to(xxx). Best, Christian On Sun, Jul 1, 2012 at 9:08 AM, gilboy josephoto...@gmail.com wrote: Hi So if I have the following 2 routes: from(SomeEndpoint).to(seda:endpoint); from(seda:endpoint.to(SomeOtherpoint); I have not specified the exchange pattern for the SEDA endpoint. Hence, does it default to something? Thanks -- View this message in context: http://camel.465427.n5.nabble.com/SEDA-Request-Reply-tp5715275p5715326.html Sent from the Camel - Users mailing list archive at Nabble.com.
Re: SEDA Request Reply
Apologies folks - accidentally posted this in the Development forum -- View this message in context: http://camel.465427.n5.nabble.com/SEDA-Request-Reply-tp5715275p5715299.html Sent from the Camel - Users mailing list archive at Nabble.com.
Re: SEDA Request Reply
its based on the Exchange Pattern being used...internally the SEDA producer is calling ExchangeHelper.isOutCapable(exchange) which returns TRUE if the pattern is NOT InOnly/RobustInOnly Edwin wrote Hi Folks, With reference to /http://camel.apache.org/seda.html/ section /Use of Request Reply/ I am curious about the /waitForTaskToComplete / option defaulting to /IfReplyExpected / /IfReplyExpected/, only waits if the message is Request Reply based I'm wondering how I would find out if a message is request reply based? Thanks, Edwin - Ben O'Day IT Consultant -http://consulting-notes.com -- View this message in context: http://camel.465427.n5.nabble.com/SEDA-Request-Reply-tp5715275p5715314.html Sent from the Camel - Users mailing list archive at Nabble.com.
defaultEndpoint must be specified with seda request/reply
When running this program I get the message 'defaultEndpoint must be specified'. Could you help me understand why? Thank you! public static void main(String args[]) throws Exception { // create CamelContext CamelContext context = new DefaultCamelContext(); // add our route to the CamelContext context.addRoutes(new RouteBuilder() { public void configure() { from(seda:backend).inOut(http4://10.11.144.78:8080/pvaa-backend/rest/v1/users/json); } } ); // start the route and let it do its work context.start(); ProducerTemplate template = context.createProducerTemplate(); Object result = template.requestBody(seda:backend); Thread.sleep(3); context.stop(); } -- View this message in context: http://camel.465427.n5.nabble.com/defaultEndpoint-must-be-specified-with-seda-request-reply-tp5606712p5606712.html Sent from the Camel - Users mailing list archive at Nabble.com.
Re: defaultEndpoint must be specified with seda request/reply
If you look at the JavaDoc, you will see that: template.requestBody(seda:backend); will send the String seda:backend to the default Endpoint which you didn't specify. You have to possible solutions: 1) set the default endpoint: createProducerTemplate.setDefaultEndpointUri(seda:backend) 2) provide the endpoint in the requestBody method template.requestBody(seda:backend, body); Best, Christian On Fri, Mar 30, 2012 at 3:42 PM, unludo unl...@gmail.com wrote: When running this program I get the message 'defaultEndpoint must be specified'. Could you help me understand why? Thank you! public static void main(String args[]) throws Exception { // create CamelContext CamelContext context = new DefaultCamelContext(); // add our route to the CamelContext context.addRoutes(new RouteBuilder() { public void configure() { from(seda:backend).inOut(http4:// 10.11.144.78:8080/pvaa-backend/rest/v1/users/json); } } ); // start the route and let it do its work context.start(); ProducerTemplate template = context.createProducerTemplate(); Object result = template.requestBody(seda:backend); Thread.sleep(3); context.stop(); } -- View this message in context: http://camel.465427.n5.nabble.com/defaultEndpoint-must-be-specified-with-seda-request-reply-tp5606712p5606712.html Sent from the Camel - Users mailing list archive at Nabble.com.