Hi!Im getting the following error while retrieving data in DataAction set OnStart, data action finishes without problem on backend , (already debugged it), but on screen I get status 504 and therefore I cannot get data I require
It is always after 30 secs, and happens only in QA environment, in development is not happening, I have already increased Module ServerAction Timeout, dataActions timeout using HTTPRequestHandler/SetRequestTimeout, and also the data action Server Request Timeout on 300 secs each one of them, but nothing seems to work,
Any help is appreciated
@Franc
How you are retrieving data in DataAction? By default Advance SQL or Aggregate has 30s timeout. Try to increase timeout in SQL/Aggregate. So seems timeout throwing from SQL/Aggerate.
Moreover, you can check from service-center how much time your query is taking.
Hi @Franc ,
Have you checked the service center error logs? If possible, could you please share?
What you are doing in data action OnAfterFetch. Are you using any for each loop on that? Can you please share the screenshot?
So in dev its working, but only in QA its not working, is there any data issue. Can you please check that as well.
This happens when a request to an external service or data source takes too long to respond, causing the server or the network gateway to timeout.
If you already increase the timeout then Review and optimize any complex logic or queries within the Data Action to reduce execution time.
Regards,
Rajat
Hello Franc,
The generic resolution to fix 504 is to increase timeouts. Besides everything else you tried, please try to increase timeout of specific aggregate or SQL which is fetching data as suggested in above response.
However increasing the timeout is not a recommended way to resolve issues, rather we must address the root cause.
In order to find the root cause you might proceed this way:
Check if it is happening with all the data actions or just this one. If it is only for particular data action you might try to understand which database entities are causing this. This way you should be able to dig deeper and finally be able to find the root cause.
Hope it helps!
Junaid