Http methods not registered

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view

Http methods not registered

This post has NOT been accepted by the mailing list yet.
This post was updated on .

I am having an issue and need help understand why it is happening. I am getting the following exception

org.apache.camel.FailedToCreateRouteException: Failed to create route ROUTE1 at: >>> To[restlet:] <<< in route: Route(ROUTE1) because of Failed to resolve endpoint: restlet:// due to: Could not find a suitable setter for property: restletMethod as there isn't a setter method with same type: java.lang.String nor type conversion possible: No type converter available to convert from type: java.lang.String to the required type: with value GET

I tracked it down to the class HttpProtocolHelper and it didn't seem that we actually call this registerMethods to register the methods in the enum. From code, the Restlet engine is set to not discover protocols so therefore HttpProtocolHelper is never called.  This is crucial because in, when calling populateRestletRequestFromExchange and the methodt is a post or put with a body, it would never insert the body since we are checking for a method == Method.POST.

Could you please let me know I need to do anything else to work around this issue? I am running restlet  camel, camel 2.17.0 in Karaf 4.0. Other thing that I noticed is that the META-INF/services/org/apache/camel/TypeConverter is not being loaded due to the bundle is not in the thread context for the camel core to find it.

Thank you!