title: Mule: What's the difference between a multicasting-router and a static-recipient-list-router?
body: <p>I can't really see a difference between a multicasting-router and a static-recipient-list-router.  Why would I use one over the other?</p>
  
  <p>According to <a href="http://old.nabble.com/Mule-2.x-User-Guide-%3E-Using-Message-Routers-td17983777.html" rel="nofollow noreferrer">Mule-2.x user guide</a> </p>
  
  <blockquote>
    <p>Recipient List</p>
    
    <p>the Recipient list router can be used
    to send the same event to multiple
    endpoints over the same endpoint or to
    implement routing-slip behaviour where
    the next destination for the event is
    determined from the event properties
    or payload. Mule provides an abstract
    Recipient list implementation
    org.mule.routing.outbound.AbstractRecipientList
    that provides a thread-safe base for
    specialised implementations. Mule also
    provides a Static recipient list that
    takes a configured list of endpoints
    from the current event or statically
    declared on the endpoint.</p>
  </blockquote>
  
  <pre><code> &lt;outbound&gt;
       &lt;static-recipient-list-router&gt;
          &lt;payload-type-filter expectedType="javax.jms.Message"/&gt;
          &lt;recipients&gt;
                  &lt;spring:value="jms://orders.queue"/&gt;
                  &lt;spring:value="jms://tracking.queue"/&gt;
          &lt;/recipients&gt;
       &lt;/static-recipient-list-router&gt; &lt;/outbound&gt;
  </code></pre>
  
  <blockquote>
    <p>Multicasting Router</p>
    
    <p>The Multicasting router can be used to
    send the same event over multiple
    endpoints. When using this router care
    must be taken to configure the correct
    transformers on the endpoints to
    handle the event source type.</p>
  </blockquote>
  
  <pre><code> &lt;outbound&gt;
       &lt;multicasting-router&gt;
          &lt;jms:endpoint queue="test.queue"
   transformer-refs="StringToJmsMessage"/&gt;
          &lt;http:endpoint host="10.192.111.11"
   transformer-refs="StringToHttpClientRequest"/&gt;
          &lt;tcp:endpoint host="10.192.111.12"
   transformer-refs="StringToByteArray"/&gt;
          &lt;payload-type-filter expectedType="java.lang.String"/&gt;
       &lt;/multicasting-router&gt; &lt;/outbound&gt;
  </code></pre>
  
  <blockquote>
    <p>Remember that care should be taken to
    ensure that the message being routed
    is transformed to a format that the
    endpoint understands.</p>
  </blockquote>