Is it possible to implement the scatter gather pattern in Apigee Edge?

Hi, I'm looking for an example of the scatter gather pattern. Is there a policy to do that?

basically.

- endpoint that internally calls 2 endpoints concurrently.

- it waits till all the responses are fulfilled.

- then you put together something based on response1 and response 2.

Solved Solved
1 4 448
1 ACCEPTED SOLUTION

sidd-harth
Participant V

Hi @Esteban Lartigue, I am sure you are coming from Mule Anypoint Studio Scatter Gather Connector which takes an input & makes two or more concurrent calls & then use a Transformers to flatten both payloads.

In Apigee we don't have an out of the box policy for that, but we can do that using a couple of Service Callout policy(synchronous in nature) or use Nodejs/Java custom code.

View solution in original post

4 REPLIES 4

sidd-harth
Participant V

Hi @Esteban Lartigue, I am sure you are coming from Mule Anypoint Studio Scatter Gather Connector which takes an input & makes two or more concurrent calls & then use a Transformers to flatten both payloads.

In Apigee we don't have an out of the box policy for that, but we can do that using a couple of Service Callout policy(synchronous in nature) or use Nodejs/Java custom code.

thanks! @Siddharth Barahalikar, is there an example somewhere on the NodeJs/Java custom code?

I'm starting a new project and I'm outlining the things I want to be able to do investigate before I actually need to do it. so I can work towards then in my free time.

Definitely not a need right now, but I totally see this becoming a need at some point.

thank you. i definitely come back to this when performance comes back to me, and combine it probably with caching.