Round Robin Flow Control in Mule

Round Robin Flow Control in Mule

Round-robin (RR) is one of the algorithms employed by process and network schedulers in computing.As the term is generally used, time slices are assigned to each process in equal portions and in circular order, handling all processes without priority (also known as cyclic executive). Round-robin scheduling is simple, easy to implement, and starvation-free. Round-robin scheduling can also be applied to other scheduling problems, such as data packet scheduling in computer networks. It is an operating system concept.

The Round Robin router iterates through a list of two or more routes in order, but it only routes to one of the routes each time it is executed. It keeps track of the previously selected route and never selects the same route consecutively. For example, the first time Round Robin executes, it selects the first route. The next time, it selects the second route. If the previously selected route is the last route in the list, Round Robin jumps to the first route.

Round Robin flow control send each message received to the next message processor in the circular list of targets.

flow of Round Robin flow control :

Round Robin flow control configuration : 

Nothing to configure in it.

URL :  http://localhost:8085/api/round
Method :  GET

Output :

XML project code :

<?xml version="1.0" encoding="UTF-8"?>

<mule xmlns:tracking="" xmlns:http="" xmlns="" xmlns:doc=""
    <http:listener-config name="HTTP_Listener_Configuration" host="" port="8085" doc:name="HTTP Listener Configuration" basePath="/api"/>
    <flow name="test_roundrobinFlow">
        <http:listener config-ref="HTTP_Listener_Configuration" path="/round" doc:name="HTTP"/>
        <round-robin doc:name="Round Robin">
            <set-payload value="1" doc:name="1"/>
            <set-payload value="2" doc:name="2"/>
            <set-payload value="3" doc:name="3"/>