[ https://issues.apache.org/jira/browse/CAMEL-14645?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Claus Ibsen resolved CAMEL-14645. --------------------------------- Resolution: Fixed > Wrong rest mapping on camel-undertow > ------------------------------------ > > Key: CAMEL-14645 > URL: https://issues.apache.org/jira/browse/CAMEL-14645 > Project: Camel > Issue Type: Bug > Components: camel-undertow > Reporter: Nicola Ferraro > Assignee: Claus Ibsen > Priority: Major > Fix For: 3.2.0 > > > The order in which routes are declared changes the behavior of the > integration. > > E.g. > {code:java} > rest() > .get("/{pippo}") > .route() > .setBody().simple("Route with name: ${header.pippo}") > .setHeader("Content-Type", constant("text/plain")); > rest() > .get("/") > .route() > .setBody().constant("Route without name") > .setHeader("Content-Type", constant("text/plain")); > {code} > When calling it with: > {code} > curl http://service:8080/ > {code} > The first route replies ("Route with name: ..."), but the second was supposed > to. > This same example works with jetty and netty-http. > As workaround for undertow, if the order of the two routes is reversed, it > works correctly. > But when you create a route from a given openapi.json file, the order is > given and you're not supposed to change it. -- This message was sent by Atlassian Jira (v8.3.4#803005)