shafreenAnfar opened a new pull request #46:
URL: https://github.com/apache/synapse/pull/46


   Current behavior of the Message Forwarding Processor is to consume all the 
messages at once. For instance, say, the Message Forwarding Processor is 
configured to run every 10 seconds and the Message store is filled with 5 
messages within the 10 second gap. In such a situation, Message Forwarding 
Processor consumes all 5 messages and try to send it to back-end as fast as 
possible. I think this behavior is not optimal. The purpose of Message 
Forwarding Processor it to send messages to the back-end in a controlled rate. 
So that the back-end server can handle the load. IMO, ideal behavior should be 
to consume one message at a time and try to send it to the back-end as per the 
configured interval. 
   
   I have implemented this feature by introducing the below configuration to 
Message Processor.
   
   ```xml
   <parameter name="consume.all">false</parameter>
   ```
   
   Default behavior is to consume all the messages at once. When the value of 
`consume.all`, is set to `false`. Message processor would only consume one 
message per each trigger. 


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscr...@synapse.apache.org
For additional commands, e-mail: dev-h...@synapse.apache.org

Reply via email to