private static async Task<IBus> SetupBus() { string connectionString = ConfigurationManager.AppSettings["AzureConnectionString"]; var pingReceiver = new PingReceiver(); IBus bus = new BusBuilder() .Configure() .WithConnectionString(connectionString) .RegisterQueueProcessor(pingReceiver) .WithLogger(new ConsoleLogger()) .Build(); await bus.Start(); return bus; }
private static async Task<IBus> SetupBus() { string connectionString = ConfigurationManager.AppSettings["AzureConnectionString"]; var subscriptionProcessor = new FirehoseReceiver(); var bus = new BusBuilder() .Configure() .WithConnectionString(connectionString) .WithMaxConcurrentReceiverCallbacks(100) .RegisterSubscriptionProcessor(subscriptionProcessor) .WithLogger(new ConsoleLogger()) .Build(); await bus.Start(); return bus; }