Skip to content

Instantly share code, notes, and snippets.

@dcomartin
Created September 23, 2020 21:50
Show Gist options
  • Save dcomartin/2dfe5780c6b3672ab369acb5dd36eaab to your computer and use it in GitHub Desktop.
Save dcomartin/2dfe5780c6b3672ab369acb5dd36eaab to your computer and use it in GitHub Desktop.
public void ConfigureServices(IServiceCollection services)
{
services.AddControllers();
services.AddSales();
services.AddShipping();
services
.AddLogging(builder =>
{
builder.SetMinimumLevel(LogLevel.Trace);
builder.AddConsole();
})
.AddBrighter(options =>
{
var messageStore = new InMemoryMessageStore();
var rmq = new RmqMessageProducer(new RmqMessagingGatewayConnection
{
AmpqUri = new AmqpUriSpecification(new Uri("amqp://guest:guest@localhost:5672")),
Exchange = new Exchange("demo")
});
options.BrighterMessaging = new BrighterMessaging(messageStore, rmq);
})
.AddSales()
.AddShipping();;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment