Using loop EIP to solve a Usecase in Apache Camel -


i have usecase in have route takes m number of rest urls' input , hits each of these urls's n number of times each until response code comes out 204.

so hit url until 204 response code , if returns 204 move on next url , apply same procedure.

i tried use loop eip did not work.please suggest.

if understood requirement correctly, should trick:

<from uri="bean:cxf...." />  <setexchangepattern pattern="inout"/> <to uri="jetty...." /> //hit url  <choice>   <when>     <simple>check_if_http_response_code_header_is_204</simple>     <to uri="mock:result" />   </when>   <otherwise>     <to uri="bean:cxf...." /> //send exchange route again   </otherwise> </choice> 

Comments

Popular posts from this blog

Magento/PHP - Get phones on all members in a customer group -

php - .htaccess mod_rewrite for dynamic url which has domain names -

Website Login Issue developed in magento -