camel-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "sunil (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (CAMEL-9435) IllegalArgumentException: Either 'uri' or 'ref' must be specified on: org.apache.camel.impl.DefaultRouteContext
Date Mon, 21 Dec 2015 06:57:46 GMT

    [ https://issues.apache.org/jira/browse/CAMEL-9435?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15066100#comment-15066100
] 

sunil commented on CAMEL-9435:
------------------------------

Thanks.

> IllegalArgumentException: Either 'uri' or 'ref' must be specified on: org.apache.camel.impl.DefaultRouteContext
> ---------------------------------------------------------------------------------------------------------------
>
>                 Key: CAMEL-9435
>                 URL: https://issues.apache.org/jira/browse/CAMEL-9435
>             Project: Camel
>          Issue Type: Bug
>          Components: camel-bindy
>    Affects Versions: 2.14.1
>            Reporter: sunil
>            Assignee: Claus Ibsen
>
> I have written a test case as shown below. Though there are no system level dependencies,
This case case never fails in my system but it fails in all other systems.
> {noformat}
> @Test
>     public void testSOTBlock() throws Exception {
>         context.getRouteDefinitions().get(0).adviceWith(context, new AdviceWithRouteBuilder()
{
>             @Override
>             public void configure() throws Exception {
>                 interceptSendToEndpoint("file://*").skipSendToOriginalEndpoint().to("mock:file");
>             }
>         });
>         MockEndpoint mock = getMockEndpoint("mock:file");
>         mock.expectedBodiesReceived(Arrays.asList("SOS:1;1;T00001;;5.00;;JANE;0;;0;;123456\r\n"));
>         StartOfTransaction startOfSale = new StartOfTransaction(purchase, 1, 1, 1);
>         template.sendBodyAndHeader("direct:toSOT", startOfSale, "flightKey", 123456);
>         assertMockEndpointsSatisfied();
>     }
> {noformat}
> Below is the test case error log.
> {noformat}
> org.apache.camel.FailedToCreateRouteException: Failed to create route route17: Route(route17)[[From[no
uri or ref supplied!]] -> [process[c... because of Either 'uri' or 'ref' must be specified
on: org.apache.camel.impl.DefaultRouteContext@a7720c2
> 	at org.apache.camel.model.RouteDefinition.addRoutes(RouteDefinition.java:192)
> 	at org.apache.camel.impl.DefaultCamelContext.startRoute(DefaultCamelContext.java:805)
> 	at org.apache.camel.impl.DefaultCamelContext.startRouteDefinitions(DefaultCamelContext.java:2174)
> 	at org.apache.camel.impl.DefaultCamelContext.doStartCamel(DefaultCamelContext.java:1906)
> 	at org.apache.camel.impl.DefaultCamelContext.doStart(DefaultCamelContext.java:1767)
> 	at org.apache.camel.support.ServiceSupport.start(ServiceSupport.java:61)
> 	at org.apache.camel.impl.DefaultCamelContext.start(DefaultCamelContext.java:1735)
> 	at org.apache.camel.test.junit4.CamelTestSupport.startCamelContext(CamelTestSupport.java:477)
> 	at org.apache.camel.test.junit4.CamelTestSupport.doSetUp(CamelTestSupport.java:311)
> 	at org.apache.camel.test.junit4.CamelTestSupport.setUp(CamelTestSupport.java:217)
> 	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> 	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
> 	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
> 	at java.lang.reflect.Method.invoke(Method.java:606)
> 	at org.junit.runners.model.FrameworkMethod$1.runReflectiveCall(FrameworkMethod.java:47)
> 	at org.junit.internal.runners.model.ReflectiveCallable.run(ReflectiveCallable.java:12)
> 	at org.junit.runners.model.FrameworkMethod.invokeExplosively(FrameworkMethod.java:44)
> 	at org.junit.internal.runners.statements.RunBefores.evaluate(RunBefores.java:24)
> 	at org.junit.internal.runners.statements.RunAfters.evaluate(RunAfters.java:27)
> 	at org.junit.rules.TestWatcher$1.evaluate(TestWatcher.java:55)
> 	at org.junit.rules.RunRules.evaluate(RunRules.java:20)
> 	at org.junit.runners.ParentRunner.runLeaf(ParentRunner.java:271)
> 	at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:70)
> 	at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:50)
> 	at org.junit.runners.ParentRunner$3.run(ParentRunner.java:238)
> 	at org.junit.runners.ParentRunner$1.schedule(ParentRunner.java:63)
> 	at org.junit.runners.ParentRunner.runChildren(ParentRunner.java:236)
> 	at org.junit.runners.ParentRunner.access$000(ParentRunner.java:53)
> 	at org.junit.runners.ParentRunner$2.evaluate(ParentRunner.java:229)
> 	at org.junit.internal.runners.statements.RunAfters.evaluate(RunAfters.java:27)
> 	at org.junit.runners.ParentRunner.run(ParentRunner.java:309)
> 	at org.eclipse.jdt.internal.junit4.runner.JUnit4TestReference.run(JUnit4TestReference.java:50)
> 	at org.eclipse.jdt.internal.junit.runner.TestExecution.run(TestExecution.java:38)
> 	at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:467)
> 	at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:683)
> 	at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.run(RemoteTestRunner.java:390)
> 	at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.main(RemoteTestRunner.java:197)
> Caused by: java.lang.IllegalArgumentException: Either 'uri' or 'ref' must be specified
on: org.apache.camel.impl.DefaultRouteContext@a7720c2
> 	at org.apache.camel.impl.DefaultRouteContext.resolveEndpoint(DefaultRouteContext.java:135)
> 	at org.apache.camel.model.FromDefinition.resolveEndpoint(FromDefinition.java:72)
> 	at org.apache.camel.impl.DefaultRouteContext.getEndpoint(DefaultRouteContext.java:89)
> 	at org.apache.camel.model.RouteDefinition.addRoutes(RouteDefinition.java:923)
> 	at org.apache.camel.model.RouteDefinition.addRoutes(RouteDefinition.java:187)
> 	... 36 more
> {noformat}



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Mime
View raw message