public void Setup() { var clientConfig = new PulsarClientConfigBuilder() .ServiceUrl("pulsar://localhost:6650"); _pulsarSystem = PulsarSystem.GetInstance(clientConfig); _client = _pulsarSystem.NewClient(); }
public void Setup() { var clientConfig = new PulsarClientConfigBuilder() .ServiceUrl("pulsar://localhost:6650"); _pulsarSystem = PulsarSystem.GetInstance(clientConfig); _client = _pulsarSystem.NewClient(); _consumer = _client.NewConsumer(new ConsumerConfigBuilder <byte[]>() .Topic(_benchTopic) .ForceTopicCreation(true) .SubscriptionName($"bench-sub-{Guid.NewGuid()}") .SubscriptionInitialPosition(Common.SubscriptionInitialPosition.Earliest)); _producer = _client.NewProducer(new ProducerConfigBuilder <byte[]>() .Topic(_benchTopic)); }