in a WorkerService .Net I am trying to configure a MassTransit host with RabbitMq but I am getting this Error
Reference to type 'IBusControl' claims it is defined in 'MassTransit', but it could not be found
IHost host = Host.CreateDefaultBuilder(args)
.ConfigureServices((context,services) =>
{
services.AddHostedService<Worker>();
services.AddAutoMapper(typeof(Program));
//MassTransit-RabbitMQ Configuration
services.AddMassTransit(config => {
config.UsingRabbitMq((ctx, cfg) => {
cfg.Host(context.Configuration.GetValue<string>("EventBusSettings:HostAddress"));
});
});
services.AddMassTransitHostedService();
})
.Build();
await host.RunAsync();
What am I missing?