Esempio n. 1
0
        public SlowConcurrentSaga_Specs()
        {
            _sagaRepository = new Lazy <ISagaRepository <SlowConcurrentSaga> >(() =>
                                                                               AzureTableSagaRepository <SlowConcurrentSaga> .Create(() => TestCloudTable));

            _sagaTestHarness = BusTestHarness.StateMachineSaga(new SlowConcurrentSagaStateMachine(), _sagaRepository.Value);
        }
Esempio n. 2
0
        public static void UseAzureTableSagaRepository(this IJobServiceConfigurator configurator,
                                                       Func <CloudTable> contextFactory)
        {
            configurator.Repository = AzureTableSagaRepository <JobTypeSaga> .Create(contextFactory);

            configurator.JobRepository = AzureTableSagaRepository <JobSaga> .Create(contextFactory);

            configurator.JobAttemptRepository = AzureTableSagaRepository <JobAttemptSaga> .Create(contextFactory);
        }
Esempio n. 3
0
        public static void UseAzureTableSagaRepository(this IJobServiceConfigurator configurator,
                                                       Func <CloudTable> contextFactory,
                                                       ISagaKeyFormatter <JobTypeSaga> jobTypeKeyFormatter,
                                                       ISagaKeyFormatter <JobSaga> jobKeyFormatter,
                                                       ISagaKeyFormatter <JobAttemptSaga> jobAttemptKeyFormatter)
        {
            configurator.Repository = AzureTableSagaRepository <JobTypeSaga> .Create(contextFactory, jobTypeKeyFormatter);

            configurator.JobRepository = AzureTableSagaRepository <JobSaga> .Create(contextFactory, jobKeyFormatter);

            configurator.JobAttemptRepository = AzureTableSagaRepository <JobAttemptSaga> .Create(contextFactory, jobAttemptKeyFormatter);
        }
Esempio n. 4
0
 ISagaRepository <ReadOnlyInstance> CreateSagaRepository()
 {
     return(AzureTableSagaRepository <ReadOnlyInstance> .Create(() => TestCloudTable));
 }
Esempio n. 5
0
 public LocatingAnExistingSaga()
 {
     _sagaRepository = new Lazy <ISagaRepository <SimpleSaga> >(() => AzureTableSagaRepository <SimpleSaga> .Create(() => TestCloudTable));
 }