Details
-
Improvement
-
Status: Resolved
-
Minor
-
Resolution: Fixed
-
2.18.3
-
None
-
Novice
Description
So you can do
@Inject @Uri("undertow:http://0.0.0.0:8080") private Endpoint undertow;
Without having to append ending slash, eg
@Inject @Uri("undertow:http://0.0.0.0:8080/") private Endpoint undertow;
As otherwise you get a stacktrace
2017-03-21 18:06:15,764 ERROR [stderr] (main) java.lang.IllegalArgumentException: UT000009: Path must be specified 2017-03-21 18:06:15,764 ERROR [stderr] (main) at io.undertow.util.PathMatcher.addPrefixPath(PathMatcher.java:115) 2017-03-21 18:06:15,764 ERROR [stderr] (main) at io.undertow.server.handlers.PathHandler.addPrefixPath(PathHandler.java:132) 2017-03-21 18:06:15,765 ERROR [stderr] (main) at org.wildfly.extension.undertow.Host.registerHandler(Host.java:213) 2017-03-21 18:06:15,765 ERROR [stderr] (main) at org.wildfly.extension.camel.undertow.CamelUndertowHostService$WildFlyUndertowHost.registerHandler(CamelUndertowHostService.java:187) 2017-03-21 18:06:15,765 ERROR [stderr] (main) at org.apache.camel.component.undertow.UndertowConsumer.doStart(UndertowConsumer.java:73) 2017-03-21 18:06:15,765 ERROR [stderr] (main) at org.wildfly.extension.camel.undertow.WildFlyUndertowComponent$WildFlyUndertowUndertowConsumer.doStart(WildFlyUndertowComponent.java:90) 2017-03-21 18:06:15,765 ERROR [stderr] (main) at org.apache.camel.support.ServiceSupport.start(ServiceSupport.java:61) 2017-03-21 18:06:15,766 ERROR [stderr] (main) at org.apache.camel.impl.DefaultCamelContext.startService(DefaultCamelContext.java:3375) 2017-03-21 18:06:15,766 ERROR [stderr] (main) at org.apache.camel.impl.DefaultCamelContext.doStartOrResumeRouteConsumers(DefaultCamelContext.java:3692)