/// <summary>
        /// <para>This method specifies that the service bus under configuration is to
        /// use RabbitMQ for message queueing. See http://readthedocs.org/docs/masstransit/en/latest/configuration/transports/rabbitmq.html.
        /// This method also calls <see cref="SerializerConfigurationExtensions.UseJsonSerializer{T}"/>.</para>
        ///
        /// </summary>
        /// <typeparam name="T">configurator type param</typeparam>
        /// <param name="configurator">configurator instance</param>
        /// <param name="configureFactory">custom action used to call APIs on the configurator</param>
        /// <returns>the configurator instance</returns>
        public static void UseRabbitMq(this EndpointFactoryConfigurator configurator,
                                       Action <RabbitMqTransportFactoryConfigurator> configureFactory)
        {
            var transportFactoryConfigurator = new RabbitMqTransportFactoryConfiguratorImpl();

            configureFactory(transportFactoryConfigurator);

            configurator.AddTransportFactory(transportFactoryConfigurator.Build);

            configurator.UseJsonSerializer();
        }