Using camel 2.12 w/o the doTry block (and using a loop) I get a non
fluctuating '1' in flight message. when stopping the route after deploying
as a .war into eap6, it would take the full 5 minutes for a graceful
shutdown.

I also relearned how to use the Timer. limiting the period to 1s allows the
route to complete w/o violating the REST contract.

<from
uri="timer://jettyTimer?fixedRate=true&amp;period=1000&amp;repeatCount=0"/>
                
<doTry>
        <to
uri="jetty:http://api.application.com/v1/pull?httpClient.timeout=30000&amp;enableJmx=true&amp;throwExceptionOnFailure=false&amp;id={{streamId}}&amp;api_key={{api_key}}&amp;username={{username}}"/>
    
        <doCatch> 
               <exception>java.net.ConnectException</exception>
                <log message="*** inside Exception :: ${exception.message} "
loggingLevel="ERROR"/>
        </doCatch>
</doTry>



--
View this message in context: 
http://camel.465427.n5.nabble.com/Jetty-as-a-producer-for-a-Rest-Call-tp5762262p5762284.html
Sent from the Camel - Users mailing list archive at Nabble.com.

Reply via email to