We upgraded from Camel 2.13.0 to 2.14.0 a couple of days ago and noticed some
problems during the upgrade. While we managed to fix certain issues with CXF
based services in Camel (extending spring configurations didn’t work for us in
2.14.0 but using @Import({…}) does achieve the same), we noticed that on having
multiple routes that define „RESTful services“ via Camels JettyComponent
initialization fails with a StackOverflowException.
Each route injects the component-string from a property file which is
furthermore used inside the from(…) statement inside the route. In Camel 2.13.0
this was working fine (which can be seen in a github project:
https://github.com/RovoMe/CamelMultipleJettyComponents) but Camel 2.14.0
(https://github.com/RovoMe/CamelMultipleJettyComponents/tree/version-upgrade)
produces a StackOverflowError as mentioned earlier. If enableMultipartFilter is
set to false (as parameter for the configuration-string) the error is delayed
to invocation time instead of setup time.
The (updated?) documentation states "Important: You can not use different
handlers with different Jetty endpoints using the same port number. The
handlers is associated to the port number. If you need different handlers, then
use different port numbers.„ So on removing handler=#jettyAuthHandler from all
but the first route
(https://github.com/RovoMe/CamelMultipleJettyComponents/tree/version-upgrade-fix)
the services are working again. So is the injected jetty basic auth handler a
different handler for every service? In that case, there should be a more
expressive exception rather than a StackOverflowError IMO.
Kind regards,
Roman