protected void ConfigureRegistration(IBusRegistrationConfigurator configurator) { configurator.AddSagaStateMachine <TestStateMachineSaga, TestInstance>() .RedisRepository(r => r.ConcurrencyMode = ConcurrencyMode.Pessimistic); configurator.AddBus(provider => BusControl); }
protected void ConfigureRegistration(IBusRegistrationConfigurator configurator) { configurator.AddSaga <SimpleSaga>() .InMemoryRepository(); configurator.AddBus(provider => BusControl); }
protected void ConfigureRegistration(IBusRegistrationConfigurator configurator) { configurator.AddConsumer <InitialConsumer>(); configurator.AddConsumer <SubsequentConsumer>(); configurator.AddBus(context => BusControl); }
protected void ConfigureRegistration(IBusRegistrationConfigurator configurator) { configurator.AddConsumer <DependentBatchConsumer>(x => x.Options <BatchOptions>(b => b.SetTimeLimit(200).SetMessageLimit(4))); configurator.AddBus(provider => BusControl); }
protected void ConfigureRegistration(IBusRegistrationConfigurator configurator) { configurator.AddSagaStateMachine <TestStateMachineSaga, TestInstance>() .MessageSessionRepository(); configurator.AddBus(provider => BusControl); }
protected void ConfigureRegistration(IBusRegistrationConfigurator configurator) { configurator.AddConsumer <ActivityRequestConsumer>(); configurator.AddExecuteActivity <SendRequestActivity, SendRequestArguments>(); configurator.AddBus(context => BusControl); configurator.AddRequestClient <ActivityRequest>(RequestQueueAddress); }
protected void ConfigureRegistration(IBusRegistrationConfigurator configurator) { _connectionString = LocalDbConnectionStringProvider.GetLocalDbConnectionString(); configurator.AddSagaStateMachine <TestStateMachineSaga, TestInstance>() .DapperRepository(_connectionString); configurator.AddBus(provider => BusControl); }
protected void ConfigureRegistration(IBusRegistrationConfigurator configurator) { configurator.AddSagaStateMachine <TestStateMachineSaga, TestInstance>() .AzureTableRepository(cfg => { cfg.ConnectionFactory(() => TestCloudTable); }); configurator.AddBus(provider => BusControl); }
protected void ConfigureRegistration(IBusRegistrationConfigurator configurator) { configurator.AddConsumer <InitialConsumer>(); configurator.AddConsumer <SubsequentConsumer>(); configurator.AddBus(context => BusControl); configurator.AddRequestClient <InitialRequest>(InputQueueAddress); configurator.AddRequestClient(typeof(SubsequentRequest), SubsequentQueueAddress); }
protected void ConfigureRegistration(IBusRegistrationConfigurator configurator) { configurator.SetKebabCaseEndpointNameFormatter(); configurator.AddConsumersFromNamespaceContaining <CrunchTheNumbersConsumer>(); configurator.AddRequestClient <CrunchTheNumbers>(); configurator.AddBus(provider => BusControl); }
protected void ConfigureRegistration(IBusRegistrationConfigurator configurator) { configurator.SetKebabCaseEndpointNameFormatter(); configurator.AddConsumersFromNamespaceContaining <SubmitOrderConsumer>(); configurator.AddRequestClient <SubmitOrder>(); configurator.AddRequestClient <AuthorizeOrder>(); configurator.AddBus(provider => BusControl); }
protected void ConfigureRegistration(IBusRegistrationConfigurator configurator) { configurator.AddSagaStateMachine <TestStateMachineSaga, TestInstance>() .MongoDbRepository(r => { r.Connection = "mongodb://127.0.0.1"; r.DatabaseName = "sagaTest"; }); configurator.AddBus(provider => BusControl); }
protected void ConfigureRegistration(IBusRegistrationConfigurator configurator) { configurator.AddConsumer <ConsumerA>(typeof(ConsumerADefinition)) .Endpoint(x => x.Name = "shared"); configurator.AddConsumer <ConsumerB>(typeof(ConsumerBDefinition)) .Endpoint(x => x.Name = "shared"); configurator.AddConsumer <ConsumerC>(typeof(ConsumerCDefinition)); configurator.AddBus(provider => BusControl); }
protected void ConfigureRegistration(IBusRegistrationConfigurator configurator) { configurator.AddSagaStateMachine <TestStateMachineSaga, TestInstance>() .CosmosRepository(r => { r.DatabaseId = "sagaTest"; r.CollectionId = "TestInstance"; r.UseClientFactory(_clientName); }); configurator.AddBus(provider => BusControl); }
protected void ConfigureRegistration(IBusRegistrationConfigurator configurator) { configurator.AddSaga <SimpleSaga>() .Endpoint(e => e.Name = "custom-endpoint-name") .InMemoryRepository(); configurator.AddSaga <SecondSimpleSaga>(typeof(SecondSimpleSagaDefinition)) .Endpoint(e => e.Temporary = true) .InMemoryRepository(); configurator.AddBus(provider => BusControl); }
protected void ConfigureRegistration(IBusRegistrationConfigurator configurator) { configurator.AddSagaStateMachine <TestStateMachineSaga, TestInstance>() .EntityFrameworkRepository(r => { r.ConcurrencyMode = ConcurrencyMode.Optimistic; r.AddDbContext <DbContext, TestInstanceDbContext>(ApplyBuilderOptions); }); configurator.AddBus(provider => BusControl); }
protected void ConfigureRegistration(IBusRegistrationConfigurator configurator) { configurator.AddSagaStateMachine <TestStateMachineSaga, TestInstance>() .EntityFrameworkRepository(r => { r.ConcurrencyMode = ConcurrencyMode.Pessimistic; r.DatabaseFactory(provider => () => new TestInstanceDbContext(LocalDbConnectionStringProvider.GetLocalDbConnectionString())); }); configurator.AddBus(provider => BusControl); }
protected void ConfigureRegistration(IBusRegistrationConfigurator configurator) { configurator.AddSagaStateMachine <TestStateMachineSaga, TestInstance>() .CosmosRepository(r => { r.EndpointUri = Configuration.EndpointUri; r.Key = Configuration.Key; r.DatabaseId = "sagaTest"; r.CollectionId = "TestInstance"; }); configurator.AddBus(provider => BusControl); }
protected void ConfigureRegistration(IBusRegistrationConfigurator configurator) { configurator.AddSagaStateMachine <TestStateMachineSaga, TestInstance>() .MartenRepository("server=localhost;port=5432;database=MartenTest;user id=postgres;password=Password12!;", r => { r.CreateDatabasesForTenants(c => { c.ForTenant() .CheckAgainstPgDatabase() .WithOwner("postgres") .WithEncoding("UTF-8") .ConnectionLimit(-1); }); }); configurator.AddBus(provider => BusControl); }
protected void ConfigureRegistration(IBusRegistrationConfigurator configurator) { configurator.AddSagaStateMachine <TestStateMachineSaga, TestInstance>() .EntityFrameworkRepository(r => { r.AddDbContext <DbContext, TestInstanceDbContext>(ApplyBuilderOptions); r.ConcurrencyMode = ConcurrencyMode.Pessimistic; if (DbContextOptionsBuilder.Options.Extensions.Any(x => x is NpgsqlOptionsExtension)) { r.LockStatementProvider = new PostgresLockStatementProvider(false); } else { r.LockStatementProvider = new SqlServerLockStatementProvider(false); } }); configurator.AddBus(provider => BusControl); }
protected void ConfigureRegistration(IBusRegistrationConfigurator configurator) { configurator.AddConsumer <PlainConsumer>(); configurator.AddConsumer <ByDefinitionConsumer, ByDefinitionConsumerDefinition>(); configurator.AddConsumer <ByEndpointConsumer>() .Endpoint(x => x.Name = "by-endpoint"); configurator.AddConsumer <ByEndpointDefinitionConsumer, ByEndpointDefinitionConsumerDefinition>() .Endpoint(x => x.Name = "by_endpoint_definition"); configurator.AddConsumer <ByEndpointNameConsumer, ByEndpointNameConsumerDefinition>() .Endpoint(x => x.Name = "by_endpoint_name"); configurator.AddConsumer <ByEndpointOverrideConsumer, ByEndpointOverrideConsumerDefinition>() .Endpoint(x => x.Name = "by_endpoint_override"); configurator.AddBus(provider => BusControl); }
protected void ConfigureRegistration(IBusRegistrationConfigurator configurator) { configurator.AddConsumer <SimplerConsumer>(); configurator.AddBus(provider => BusControl); }
protected void ConfigureRegistration(IBusRegistrationConfigurator configurator) { configurator.AddActivity <TestActivity, TestArguments, TestLog>(); configurator.AddBus(provider => BusControl); }