|
|
|
@ -39,7 +39,7 @@ public class ProducerPool : IProducerPool, ISingletonDependency |
|
|
|
return Producers.GetOrAdd( |
|
|
|
connectionName, connection => new Lazy<IProducer<string, byte[]>>(() => |
|
|
|
{ |
|
|
|
var producerConfig = new ProducerConfig(Options.Connections.GetOrDefault(connection)); |
|
|
|
var producerConfig = new ProducerConfig(Options.Connections.GetOrDefault(connection).ToDictionary(k => k.Key, v => v.Value)); |
|
|
|
Options.ConfigureProducer?.Invoke(producerConfig); |
|
|
|
return new ProducerBuilder<string, byte[]>(producerConfig).Build(); |
|
|
|
|
|
|
|
|