Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
How to make camel redirect requests in a maximum
from(url).process(processor).choice()
.when(header("location").isNull()).endChoice()
.when(header("location").contains("?")).recipientList(simple("${header.location}&bridgeEndpoint=true")).endChoice()
.otherwise().recipientList(simple("${header.location}?bridgeEndpoint=true"));
and just modify location header in processor to any url you need to redirect based on input request content
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.