在Camel中的Rest DSL中通过头参数值进行基于请求的路由

时间:2016-09-29 21:50:21

标签: apache-camel

我想根据标头参数中的数据将消息路由到不同的路由。

rest()  
    .tag("API")
    .id("eventRest")
    .post("/data").description("Post a new settlement data record")
    .consumes("application/json")
    .param().type(RestParamType.header).name("channelID").endParam().to("direct:customRoute")

这里如果我有不同的参数,那么这个应该绕过并继续我的程序中的其余流程。

0 个答案:

没有答案