<commit_before>RabbitMQ Configuration Options
""""""""""""""""""""""""""""""

This is the recommended approach for configuring MassTransit for use with RabbitMQ.

.. sourcecode:: csharp

  ServiceBusFactory.New(sbc => 
  {
    // this is the recommended routing strategy, and will call 'sbc.UseRabbitMq()' on its own.
    sbc.UseRabbitMqRouting();
    // other options
  });
  
Alternatively you can use *raw* RabbitMQ routing.

.. sourcecode:: csharp

  ServiceBusFactory.New(sbc => 
  {
    // this is the recommended routing strategy, and will call 'sbc.UseRabbitMq()' on its own.
    sbc.UseRabbitMq();
    // other options
  });

Have a look at this table for clarification:
  
``UseRabbitMq`` tells the MassTransit code to use RabbitMQ as the transport. 
This also sets the default serializer to JSON.

``UseRabbitMqRouting`` configures the bus instance to use the default MassTransit
convention based routing for RabbitMq

 ==================================  ================================      ==================================
  Description                        Calling ``UseRabbitMqRouting``        Not calling ``UseRabbitMqRouting``
 ==================================  ================================      ==================================
 IServiceBus.Publish<T>(T, A<C<T>>)  Enables *Polymorphic routing* [#pr]   Will only route non-polymorphicly.
                                     and *Interface-based routing* [#ir]   Will not route on interfaces.
 
 ==================================  ================================      ==================================
 
 
 RabbitMQ with SSL
 -----------------
 
 .. sourceode:: csharp
 
  ServiceBusFactory.New(c =>
      {
          c.ReceiveFrom(inputAddress);
          c.UseRabbitMqRouting();
          c.UseRabbitMq(r =>
              {
                  r.ConfigureHost(inputAddress, h =>
                      {
                          h.UseSsl(s =>
                              {
                                  s.SetServerName(System.Net.Dns.GetHostName());
                                  s.SetCertificatePath("client.p12");
                                  s.SetCertificatePassphrase("<PASSWORD>");
                              });
                      });<commit_msg>updated to state that publish needs rmq routing<commit_after>RabbitMQ Configuration Options
""""""""""""""""""""""""""""""

This is the recommended approach for configuring MassTransit for use with RabbitMQ.

.. sourcecode:: csharp

  ServiceBusFactory.New(sbc => 
  {
    // this is the recommended routing strategy, and will call 'sbc.UseRabbitMq()' on its own.
    sbc.UseRabbitMqRouting();
    // other options
  });
  
Alternatively you can use *raw* RabbitMQ routing.

.. sourcecode:: csharp

  ServiceBusFactory.New(sbc => 
  {
    // this is the recommended routing strategy, and will call 'sbc.UseRabbitMq()' on its own.
    sbc.UseRabbitMq();
    // other options
  });

Have a look at this table for clarification:
  
``UseRabbitMq`` tells the MassTransit code to use RabbitMQ as the transport. 
This also sets the default serializer to JSON.

``UseRabbitMqRouting`` configures the bus instance to use the default MassTransit
convention based routing for RabbitMq

 ==================================  ================================      ==================================
  Description                        Calling ``UseRabbitMqRouting``        Not calling ``UseRabbitMqRouting``
 ==================================  ================================      ==================================
 IServiceBus.Publish<T>(T, A<C<T>>)  Enables *Polymorphic routing* [#pr]   Will only route non-polymorphicly.
                                     and *Interface-based routing* [#ir]   Will not route on interfaces.
                                                                           Will not place message in any exchange.
 ==================================  ================================      ==================================
 
 
 RabbitMQ with SSL
 -----------------
 
 .. sourceode:: csharp
 
  ServiceBusFactory.New(c =>
      {
          c.ReceiveFrom(inputAddress);
          c.UseRabbitMqRouting();
          c.UseRabbitMq(r =>
              {
                  r.ConfigureHost(inputAddress, h =>
                      {
                          h.UseSsl(s =>
                              {
                                  s.SetServerName(System.Net.Dns.GetHostName());
                                  s.SetCertificatePath("client.p12");
                                  s.SetCertificatePassphrase("<PASSWORD>");
                              });
                      });
{'fraction_non_alphanumeric': 0.22067338623203947, 'fraction_numerical': 0.0008578168561012224, 'mean_word_length': 2.132303559435863, 'pattern_counts': {'":': 0, '<': 11, '<?xml version=': 0, '>': 23, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 13, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '4433812', 'n_tokens_mistral': 1263, 'n_tokens_neox': 1101, 'n_words': 298}