Repository navigation
Returning HTTP 500 instead of HTTP 200 when a workflow that has HTTP Endpoint is Suspended #6311
Replies: 1 comment
|
Thanks for raising this. The behavior is confirmed in the current HTTP middleware: when no response has started, its fallback writes So a Relevant source: |
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Greetings all,
When a workflow has an HTTP Endpoint activity and the workflow is suspended, the HTTP Endpoint will return HTTP 200 with empty payload, this might cause issues with some calling system since most systems will depend on the return code rather than the payload, e.g. when calling a CreateAccount endpoint, the calling system might only check for 200 OK without verifying the response payload to determine if the account was created.
I would suggest that the HTTP Endpoint will return code 500 rather than 200 if the workflow was suspended before the HTTP Response activity was reached.
Even though the person who designed the workflow should take care not to place a suspending activity between HTTP Endpoint and HTTP Response activities, but in case they missed, it will not cause this issue.
All reactions