首页 > 解决方案 > 如何在骆驼中调用另一条“新”路线

问题描述

我有一条路线 (A) 可以做一些事情,比如调用 REST 服务。

在这条路线中,在调用 REST 服务之前,我需要调用另一个 REST 服务,以评估我的应用程序中的一些数据。该新呼叫位于另一条路线 (B) 中。

我正在寻找调用第二条路线 (B) 的提示,但有一个新的“交换”(我希望 A 和 B 中的交换之间没有链接)。

 from(ROUTE_A)
        .routeId(ROUTE_A)
        .process(someProcessA())
        //I need to call the route B here, but without giving in the current exchange content
        //Route A must wait until before route B execution is complete
        .process(someProcessB())
        .to(http://blahblah.com/)
        .end()

有谁知道解决方案?

谢谢,

标签: apache-camel

解决方案


也许内容丰富的EIP 会有所帮助


推荐阅读