2017-02-08 12 views
0

我想使用動態Uris豐富。我使用駱駝2.17.5。從2.16開始可以使用它。但我如何使用聚合策略和動態Uris?我如何使用aggregationStrategy和動態Uris?

Documantation說:

.enrich().simple("http:myserver/${header.orderId}/order") 

但是,這並不工作:

.enrich(new StrategyEnrich()).simple("http:myserver/${header.orderId}/order") 

這也沒有:

.enrich(simple("http:myserver/${header.orderId}/order"),new StrategyEnrich()) 

多少懂一點一個正確的語法?

謝謝

回答

0

我找到了解決辦法:

.enrich() 
    .simple("http:myserver/${header.orderId}/order") 
    .aggregationStrategy(new StrategyEnrich())