/// <summary> /// Registers the fake in-memory message broker. /// </summary> /// <param name="builder"></param> /// <param name="optionsAction">Additional options (such as connectors).</param> /// <returns></returns> public static ISilverbackBuilder WithInMemoryBroker( this ISilverbackBuilder builder, Action <BrokerOptionsBuilder> optionsAction = null) { builder.WithConnectionTo <InMemoryBroker>(optionsAction); return(builder); }
/// <summary> /// Registers Apache Kafka as message broker. /// </summary> /// <param name="builder"></param> /// <param name="optionsAction">Additional options (such as connectors).</param> /// <returns></returns> public static ISilverbackBuilder WithConnectionToKafka( this ISilverbackBuilder builder, Action <BrokerOptionsBuilder> optionsAction = null) { builder.WithConnectionTo <KafkaBroker>(optionsAction); builder.AddSingletonBehavior <KafkaPartitioningKeyBehavior>(); return(builder); }