storia321
storia321

Reputation: 381

loop back mediator and respond mediator

I am working on WSO2 ESB 4.9.0. We have an API with in and out sequences. All the business logic is there in, in sequence and out sequence doesn't have any logic implemented. Some times we need to exit the flow from in sequence because all our back end service calls are made with call mediator and not with send mediator. In this service chain pattern, if we want to exit the flow, do we need to use respond OR loopback mediator.

Can somebody help me what are the basic use cases where loopback and respond can be used

Upvotes: 5

Views: 1654

Answers (1)

maheeka
maheeka

Reputation: 2093

respond mediator will send back the response to the client. loopback mediator will move the message flow to the outsequence. In this case you need to use respond mediator since you need to exit the flow and respond to the client. However, if you have any mediation that you need to execute in outsequence, you can always use loopback mediator and use respond mediator in the outsequence to do the same.

Upvotes: 6

Related Questions