Flow design - REST API Socket Error code 1
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-11-2024 10:16 AM
Hello everyone,
I created a flow to send a REST message to an API, requesting some records and inserting them into a staging table.
When I run the workflow, the actions that send the request begin processing, and after 5 to 10 minutes, it generates the following error message:
However, even with the error, my staging table is still receiving the records.
Can someone help me please?
Thank you
André Ramos
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-12-2024 04:53 AM
Hi @Andr_1
May be the default timeout of 30 seconds is creating the issue. To bypass it, we need to set the system property "glide.http.outbound.max_timeout.enabled" to false and make the REST API call using scripting. In the script, we need to use waitForResponse(). Please refer below links and check if this helps.
Thanks & Regards
Amit Verma
Please mark this response as correct and helpful if it assisted you with your question.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-15-2024 01:42 AM
Hello @Amit Verma
I am doing the call to the api with SOAP Steps on the flow design.
But, to try your suggestion, I created an script to do a rest message
I set the "glide.http.outbound.max_timeout.enabled" to false and used the waitForResponse() in the script. I put also a log to see the response body, and it gives me an error:
"An internal error occurred. For error details check MPL ID AGWhciSbtst0D7H1VnYS2Dp9L4Tg in message monitoring or use the URL ..... to directly access the error information"
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-15-2024 02:09 AM
Hi @Andr_1
Are you calling a SOAP endpoint in the "ServiceNow CPI test" Rest message ? Most probably, you are getting this error from the endpoint not from ServiceNow.
Thanks & Regards
Amit Verma
Please mark this response as correct and helpful if it assisted you with your question.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-02-2024 12:42 AM
Hey @Andr_1,
I'm facing the same issue. Did you manage to fix it?
Best,
JG
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-02-2024 10:08 AM
Hello @Kub
I did not... I simply change the approach and right now I am not using flow design anymore. I am calling the api via script, and inside the script I am including the code to run on asynchronous mode