It just involved two service,and Customer-Server don't need to excute DQL.It is my understanding that 2 or more database need to execute DQL than we need distributed transaction.
Furthermore,If I need compensate and action in every step,and there are over 2 step.What am I supposed to write SagaDefinition like below?
It just involved two service,and Customer-Server don't need to excute DQL.It is my understanding that 2 or more database need to execute DQL than we need distributed transaction. Furthermore,If I need compensate and action in every step,and there are over 2 step.What am I supposed to write SagaDefinition like below?
private SagaDefinition<CreateOrderSagaData> sagaDefinition = step() .withCompensation(this::reject) .step() .invokeParticipant(this::reserveCredit) .step() .invokeParticipant(this::approve) .build();