Reputation: 3
I just wish to check the return code of a HTTP call against a list of values. The logical case would be to use the IN operator, but I can't seem to make it work.
The documentation says to use a comma delimited list of values to check against so I did this:
header.CamelHttpResponseCode in 204,200
but it does not seem to kick in. Anyone done this kind of thing?
Upvotes: 0
Views: 653
Reputation: 1060
You need to add single quotes around the status codes
<simple>${header.CamelHttpResponseCode} in '204,200'</simple>
Or in java dsl:
.simple("${header.CamelHttpResponseCode} in '204,200' ")
Upvotes: 1