Skip to main content
Solved

Process flow API endpoint - sequential processing


Forum|alt.badge.img

Within the SF we have setup a process flow as an API webservice which is open to receive EDI files from an EDI broker. The process flow itself is rather simple, it has a start, decision and an end. The decision contains code to parse an XML file, perform some checks (for instance call a stored procedure which sends an email if invalid data is sent) and insert a purchase order (+ some logging info).

The question is:
Are the EDI messages sent to our endpoint always handled sequentially by this process flow? We have seen EDI messages being send in rapid succession, with a few thousands of a second in between messages (see image below).


The reason for this question is that we have an insert trigger that can handle both sets and individual purchase orders. However, we believe that orders sent in such rapid succession as is the case in the first 3 rows, is not handled well by the insert trigger. 


Thanks in advance.

Best answer by Vincent Doppenberg

Hello Philip,

These requests will not necessarily be handled sequentially. With the rapid succession of requests as you're seeing, it is very possible that the second request beats the first request to the finish line. With the way client-server communication works in general, it's not even a guarantee that Indicium will receive the requests in the same order as the client sends them in.

If it's necessary for the requests to be handled sequentially, then the client must await the response of a request before sending another. From a performance perspective however, it is much better to support handling these requests in parallel.

I hope this helps.

 

View original
This topic has been closed for comments

Forum|alt.badge.img+4

Hello Philip,

These requests will not necessarily be handled sequentially. With the rapid succession of requests as you're seeing, it is very possible that the second request beats the first request to the finish line. With the way client-server communication works in general, it's not even a guarantee that Indicium will receive the requests in the same order as the client sends them in.

If it's necessary for the requests to be handled sequentially, then the client must await the response of a request before sending another. From a performance perspective however, it is much better to support handling these requests in parallel.

I hope this helps.

 


Forum|alt.badge.img
  • Rookie
  • January 27, 2022

Hi Vincent, 

 

Thanks for the response, it is very helpful to be aware of this.


Cookie policy

We use cookies to enhance and personalize your experience. If you accept you agree to our full cookie policy. Learn more about our cookies.

 
Cookie settings