You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@camel.apache.org by "Henryk Konsek (JIRA)" <ji...@apache.org> on 2015/04/22 13:36:20 UTC
[jira] [Created] (CAMEL-8685) Netty should resolve OPTIONS prefix
matches earlier
Henryk Konsek created CAMEL-8685:
------------------------------------
Summary: Netty should resolve OPTIONS prefix matches earlier
Key: CAMEL-8685
URL: https://issues.apache.org/jira/browse/CAMEL-8685
Project: Camel
Issue Type: Improvement
Components: camel-netty-http, camel-netty4-http
Reporter: Henryk Konsek
Assignee: Henryk Konsek
Fix For: 2.15.2, 2.16.0
Currently it is impossible to define wildcard URI that will serve custom OPTIONS response to all the requests:
{code}
from("netty4-http:http://0.0.0.0:{{port}}/path1?httpMethodRestrict=POST").setBody().constant("somePostResponse");
from("netty4-http:http://0.0.0.0:{{port}}?matchOnUriPrefix=true&httpMethodRestrict=OPTIONS").setBody().constant("expectedOptionsResponse");
{code}
POST route is detected as match for OPTION method too early and the second route is never called.
Netty HTTP should be smart enough to find out that there is the wildcard route serving OPTION requests and prefer that route over the default OPTION response generated by the POST routes.
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)