Below are my 3 routes in my base groovy routes class deployed as base framework.
from("jms:queue:EndPoint1?concurrentConsumers=100")
.routePolicyRef("myPolicy")
.transacted()
.log("Recieved From Endpoint1")
/*.to("log:Recieved From Endpoint1?groupSize=100")*/
.to("CommonEndpoint");
from("jms:queue:EndPoint2?concurrentConsumers=50")
.rootPolicyRef("myPolicy")
/*.to("log:Recieved From Endpoint2?groupSize=100")*/
.log("Recieved From Endpoint2")
.to("CommonEndpoint");
from("CommonEndpoint")
.delay(50)
/*.to("log:Delayed?groupSize=100")*/
.log("Delayed");
Below is my timer route created in a bundle which refers to base framework.
from("timer://Timer1?fixedRate=true&period=60000")
.to("jms:queue:EndPoint1");
and
from("timer://Timer2?fixedRate=true&period=60000")
.to("jms:queue:EndPoint2");
which continuosly sends timer message to Endpoint1 and Enpoint2 which both sends message to commonendpoint. My ThrottlingInflightRoutePolicy is defined like below.
<bean id="myPolicy" class="org.apache.camel.impl.ThrottlingInflightRoutePolicy">
<property name="scope" value="Context"/>
<property name="maxInflightExchanges" value="20"/>
<property name="resumePercentOfMax" value="10"/>
<property name="loggingLevel" value="WARN"/>
</bean>
While checking log i can simply see the log trace of timer. Im not understanding how to throttle requests while checking log. is there anything im missing here?? What should be done in my code to test throttling....?