20
Views
2
Comments
Communication error to Api


Hi All,

while communicating with api getting below error  but few times data is getting stored properly but after getting below exception also sometime data is storing,In logs it is giving 10s timesout ,operation cancelled.

Do need to increase timeout,

I have increased timeout on api methods,But is it image 2 below ,I need to increase,

Please suggest



what actions to be taken to resolve the issue,

Increaded to 60 sec,and working now,Is any other change required for more apis handling in future  on submission of button.

2020-05-07 18-53-00
Rui Barradas
 
MVP

Hello Preeti,

Hope you're doing well.

First of all, I would suggest some extra care in writing your future questions. In fact, it becomes quite difficult to understand what your question really is.

The Default Timeout in Seconds property basically refers to the maximum time in seconds that your app will wait for a server request, which is 10 seconds by default.


This means that, when a Server Action invokes an external API, if the API response time exceeds this limit, the platform will raise a Communication Exception.

Did you verify the actual response time of the API? You can do it going to Service Center -> Monitoring -> Integration Logs. 


Eventually increasing this timeout to 60 seconds may mitigate / resolve the issue, as it allows longer server requests to complete. However, this can negatively impact the user experience of your app. In most cases, response times approaching 60 seconds are not acceptable for an app to interact to the user.


Additionally keep in mind that, if a Server Action performs multiple API calls, the cumulative execution time must still remain within the defined timeout limit. Otherwise, the application will still raise an exception.


Kind regards,

Rui Barradas

UserImage.jpg
Preeti zade

Hi Rui,

The server actions calls multiple api calls and future more apis will be added based on each other status to be passed as input to subsequent api.Hence due to multiple apis although they are excuting in max 300 ms.

As you said cumulative execution time but it is showing below error from logs.


Revision 1382

OS-CLRT-60900 - The timeout of 10s was reached while executing this server action.

Please suggest 


Community GuidelinesBe kind and respectful, give credit to the original source of content, and search for duplicates before posting.