You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@camel.apache.org by "Babak Vahdat (JIRA)" <ji...@apache.org> on 2012/07/09 18:13:34 UTC
[jira] [Resolved] (CAMEL-5432) Dynamically added SEDA-route is not
working
[ https://issues.apache.org/jira/browse/CAMEL-5432?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Babak Vahdat resolved CAMEL-5432.
---------------------------------
Resolution: Fixed
Thanks for reporting and providing the unit-test.
> Dynamically added SEDA-route is not working
> -------------------------------------------
>
> Key: CAMEL-5432
> URL: https://issues.apache.org/jira/browse/CAMEL-5432
> Project: Camel
> Issue Type: Bug
> Components: camel-core
> Affects Versions: 2.10.0
> Reporter: Hartmut Lang
> Assignee: Babak Vahdat
> Fix For: 2.9.3, 2.10.1, 2.11
>
>
> Dynamically removing and adding a SEDA-route creates a not working route in Camel 2.10.0.
> It is working in 2.9.2.
> Test-Code:
> {code}
> public class DynamicRouteTest extends CamelTestSupport {
> @Override
> protected RouteBuilder createRouteBuilder() throws Exception {
> return new RouteBuilder() {
> @Override
> public void configure() throws Exception {
> from("seda:in").id("sedaToMock").to("mock:out");
> }
> };
> }
>
> @Test
> public void testDynamicRoute() throws Exception {
> MockEndpoint out = getMockEndpoint("mock:out");
> out.expectedMessageCount(1);
>
> template.sendBody("seda:in", "Test Message");
>
> out.assertIsSatisfied();
>
> CamelContext camelContext = out.getCamelContext();
> camelContext.stopRoute("sedaToMock");
> camelContext.removeRoute("sedaToMock");
>
> camelContext.addRoutes(createRouteBuilder());
> out.reset();
> out.expectedMessageCount(1);
>
> template.sendBody("seda:in", "Test Message");
>
> out.assertIsSatisfied();
>
> }
> }
> {code}
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira