As of April 12th, you must go to Progress SupportLink to create new support cases or to access existing cases. Please, bookmark the SupportLink URL and use the new portal to contact the support team.
Custom endpoint from within a custom endpoint timeout
S
Stephen Levy
started a topic
about 9 years ago
I am calling another custom endpoint from within a custom endpoint, but I am frequently (about 50% of the time seeing the following error being returned from the second custom endpoint (to the first endpoint):
{
"debug": {
"code": "ETIMEDOUT"
}
}
This happens even when I created a simple endpoint that didn't actually do anything except immediately return. Am I hitting the 2 second Kinvey BL timeout? It seems like it's returning in less than two seconds.
Note that I am calling the second endpoint via a modules.req.post call with the full kinvey URL. Is there a way to call a custom endpoint internally, without having to use the external URL? Is using a common code module the solution to this?
It looks like I might be hitting the 1500ms timeout for external endpoint requests? 1500ms seems like wayyyyy to short of a time period for this. You can't even seem support requests on your own server in that time frame.
M
Michael
said
about 9 years ago
What use case are you trying to solve in regards to a custom endpoint calling another custom endpoint? Common code is probably a better solution for this if you are simply attempting to break up reusable code, as there is overhead in making an endpoint request.
As far as the timeout goes, 1500ms has met the majority of our customer's use cases so far, although not all of them. In my own testing, our own service generally returns in
Stephen Levy
{
"debug": {
"code": "ETIMEDOUT"
}
}
This happens even when I created a simple endpoint that didn't actually do anything except immediately return. Am I hitting the 2 second Kinvey BL timeout? It seems like it's returning in less than two seconds.
Note that I am calling the second endpoint via a modules.req.post call with the full kinvey URL. Is there a way to call a custom endpoint internally, without having to use the external URL? Is using a common code module the solution to this?