Performance Issue - Published Rest API

1
We have published a rest api for licensed app For initial hit (first transaction) it is taking about 21.896 seconds to process the request  For subsequent (immediate after 1st transaction) 2nd request it is taking about 3.806 seconds to process the request We let the api idle for 1 hr 30 mins and then hit the api 3rd request it is taking around 3.891 seconds to process the request. We let the api idle for 3 hrs and hit the api this time it took 37.895 seconds to process the request.   Mendix version: 7.23.8 Any thoughts on above mentioned issue. 
asked
2 answers
0

What does the API do?

For example, if there are a lot of retrieves or sorts are there indexes on the values used? Do retrieves return a large amount of data? If so, could that be paginated?

If you can share the microflow being executed in the API call we can see if there is anything else we can do to help.
 

answered
0

Hello Spandana, 

If your application is running in a sandbox environment (i.e. you deploy it by hitting run in the modeler), that is a free environment that goes to sleep after a certain time. If the environment is asleep, your call won’t be responded until the environment gets woken up, which takes a bit of time.

That doesn’t happen on paid apps. 

Hope this helps.

answered