Thomas
Thomas5mo ago

Complex workflows -> timeout

I built rather complex buildship flows including website scrapers. Now when calling the api I get a timeout. Is there any best practice for the front end (flutterflow) on how to deal with long response times? My flow works fine when testing it on Buildship. I found a possible solution consulting gpt: 1. Frontend Request: Send an API request to start a task. 2. Backend Response: Return 202 Accepted with a task ID and status URL. 3. Backend Processing: Process the task in the background. 4. Result Storage: Store the result in Firebase. 5. Completion Notification: Use one of the methods above to notify the frontend (Polling, Websockets, Webhook). So I am trying to send a 202 return, but I do not want to stop the workflow. How do I do that? Thanks a lot!!!
2 Replies
Gaurav Chadha
Gaurav Chadha5mo ago
Hi @Thomas If your BuildShip workflow is making multiple API requests, there could be a probable chance that the POST request from FlutterFlow will timeout, I see a recent unresolved issue on the FlutterFlow community Forum on TimeOut issues, https://community.flutterflow.io/database-and-apis/post/how-to-solve-the-timeout-error-paGhalfumvpM1im. You can share your usecase in the above thread too. cc @Stu for expert insight.
Stu
Stu5mo ago
Super interesting, @Thomas - the timeout issue is a vexed one. As @Gaurav Chadha suggests, it would be great to see more of your workflow (both Buildship and Flutterflow, shared via DM if sensitive). There are definitely ways to increase timeouts on both sides.