how to set id of camel processor or other route ingredients

安稳与你 提交于 2019-12-06 04:27:55

If using xml then use the id attribute.

<to id="foo" uri="seda:foo"/>

And if using java code, then use .id

.to("seda:bar").id("foo");

And one special is to set the id of the route, which you must use .routeId

from("xxx").routeId("id of the route")
   .to("xxx")

So your example should be

from("some:where").process(myProcessor).id("theIdOfTheProcessorYouWant").to(no:where)
标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!