![]() ![]() Mass Transit along with the Delta Rides Regional Coordination Group is collaborating with the Mississippi Department of Human Services (MDHS) to provide transportation as a part of Project Smart Start. To provide assistance in meeting the needs of low-income, elderly, and disabled persons in this project's service area with affordable and safe transportation during this program year ending September 30, 2019. To plan, develop, and provide mobility options for the general public in the project's service area that are safe, reliable, accessible, and cost-effective. Mass Transit is charged with the responsibility of developing mobility options for residents in its service area. I have created a simple activity, registered it in IOC, used as You did, but have got the exception: GreenPipes.PayloadNotFoundException: The payload was not found: Automatonymous.IStateMachineActivityFactoryĪt (PipeContext context)Īt `3.(BehaviorContext`2 context, Behavior`2 next)Īt `2.(BehaviorContext`2 context, Behavior`2 next)Īt `1.(BehaviorContext`2 context)Īt `1.(EventContext`2 context)Īt Automatonymous.AutomatonymousStateMachine`1.(EventContext`2 context)Īt `2.Send(SagaConsumeContext`2 context, IPipe`1 next)Īt `1. Mass Transit Program operates under the umbrella of the Division of Economic Development and Public Service at Mississippi Valley State University. this Equal fails saying the saga is in state InitialĪssert.Equal(, ) ![]() Var saga = await repo.ShouldContainSaga(s => s.Serial = serial, timeout: TimeSpan.FromSeconds(1)) Var repo = provider.GetService>() as InMemorySagaRepository Var guid = CorrelationId = Guid.NewGuid() Īwait (new Run()) Harness.OnConfigureInMemoryReceiveEndpoint += cfg => cfg.StateMachineSaga(machine, provider) Var provider = collection.BuildServiceProvider() Var collection = new ServiceCollection() Ĭollection.RegisterInMemorySagaRepository() Public async Task RunMessageSent_NonexistingSaga_StateIsRunning() throw new Exception("BOO") // uncommenting this line doesn't throw anywhereĪwait next.Execute(context).ConfigureAwait(false) Public async Task Execute(BehaviorContext context, Behavior next) InstanceState(instance => instance.CurrentState) Įvent(() => Start, x => x.CorrelateBy(saga => saga.CorrelationId, context => )) Here's some code public class MyStateMachine : MassTransitStateMachine I'm using Microsofts' dotnet core Dependency Injection library. It appears there's some exception thrown, but that apparently doesn't bubble up to the test harness. It gets resolved from the container and the Execute method is called, but then it somehow just quits. My problem is that whatever I execute in the activity I just cannot get it to work as it should. Now, I've understood that the state machine itself should not have any dependencies, and hence there's this Activity(x => x.OfInstanceType) activity that can be added which is resolved from the DI container and can have whatever dependencies (services etc) in it. My scenario is that I have a state machine saga where I want to do stuff in the same transaction (Entity Framework) as the saga is running in, so that the state and business things goes together. I've been fighting a lot with this problem for a couple of days, but cannot find a way that actually works. ![]()
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |