class Program | |
{ | |
static void Main(string[] args) | |
{ | |
CreateHostBuilder(args).Build().Run(); | |
} | |
private static IHostBuilder CreateHostBuilder(string[] args) => | |
Host.CreateDefaultBuilder(args) | |
.ConfigureServices((context, collection) => | |
{ | |
collection.AddHostedService<KafkaConsumerHostedService>(); | |
collection.AddHostedService<KafkaProducerHostedService>(); | |
}); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment