THIS IS A TEST INSTANCE. ALL YOUR CHANGES WILL BE LOST!!!!
...
Where someName can be any string to uniquely identify the endpoint.
Sample
In the route below we have the list , we insert a browse:
component to be able to browse the Exchanges that is passed are passing through:
Code Block | ||||
---|---|---|---|---|
| ||||
from("activemq:order.in").to("browse:orderReceived").to("bean:processOrder"); |
Then we will be able to We can now inspect the received exchanges from java within the Java code:
Code Block | ||||
---|---|---|---|---|
| ||||
private CamelContext context; public void inspectRecievedOrders() { BrowsableEndpoint browse = context.getEndpoint("browse:orderReceived", BrowsableEndpoint.class); List<Exchange> exchanges = browse.getExchanges(); ... // then we can inspect the list of received exchanges from Java for (Exchange exchange : exchanges) { String payload = exchange.getIn().getBody(); ... } } |
...