You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Some apps can take many minutes to initialize. During this time no progress messages are printed to the logs. Regular progress messages (1 every 10 seconds) should be printed so the app owner can tell what's happening.
From weekly meeting consensus was that having a ping service would be useful in determining if the app is ready - even if it wouldn't help know if the app is hanging. The service would start responding after run_server gets executed.
changed the title [-][Feature Request] Display progress message while loading long-to-load applications[/-][+][Feature Request] Add `ping` service to Dash[/+]on Aug 14, 2020
We could use the CHECKS file mechanism in Dash Enterprise to only finish the deployment when a certain endpoint is accessible. The dokku documentation is here (Also documented in Dash Enterprise on /Docs/dash-enterprise/checks).
Is there any advantage to using ping instead of /_dash-layout?
@chriddyp If I'm not mistaken /_dash-layout waits for the layout and the callbacks to finish the execution right ? In this case, my understanding is that the code that takes time to finish the execution is the code in publish_data.py which is not tied to a callback. CHECKS could help since it could be customised to what we check for. Though we could add a dummy callback that's tied to the slow code in publish_data.py and make this callback only return something (e.g. True) once the slow code execution has ended.
I could be misunderstanding or missing something though.
The advantage of ping is just avoiding layout generation, in case that’s an expensive function, and keeping the network load small in case the layout has a ton of data in it. Not a huge deal, but then it’s not a big feature to add if it provides some value.
I agree with the above and it seems like adding ping would also be good for monitoring. Or in my case, to simply implement a keep alive via cron in an environment like free Heroku where your app is taken down after 30 minutes of inactivity.
Activity
Marc-Andre-Rivet commentedon Aug 14, 2020
From weekly meeting consensus was that having a
pingservice would be useful in determining if the app is ready - even if it wouldn't help know if the app is hanging. The service would start responding afterrun_servergets executed.@Gzork If you have additional feedback.
[-][Feature Request] Display progress message while loading long-to-load applications[/-][+][Feature Request] Add `ping` service to Dash[/+][-][Feature Request] Add `ping` service to Dash[/-][+]Add `ping` service to Dash[/+]deepstqte commentedon Aug 20, 2020
We could use the
CHECKSfile mechanism in Dash Enterprise to only finish the deployment when a certain endpoint is accessible. The dokku documentation is here (Also documented in Dash Enterprise on/Docs/dash-enterprise/checks).chriddyp commentedon Aug 26, 2020
We already use the
/_dash-layoutendpoint for this. Is there any advantage to using ping instead of/_dash-layout?chriddyp commentedon Aug 26, 2020
How will this work architecturally? Some background process that gets kicked off?
deepstqte commentedon Aug 26, 2020
@chriddyp If I'm not mistaken
/_dash-layoutwaits for the layout and the callbacks to finish the execution right ? In this case, my understanding is that the code that takes time to finish the execution is the code inpublish_data.pywhich is not tied to a callback.CHECKScould help since it could be customised to what we check for. Though we could add a dummy callback that's tied to the slow code inpublish_data.pyand make this callback only return something (e.g.True) once the slow code execution has ended.I could be misunderstanding or missing something though.
alexcjohnson commentedon Aug 26, 2020
The advantage of ping is just avoiding layout generation, in case that’s an expensive function, and keeping the network load small in case the layout has a ton of data in it. Not a huge deal, but then it’s not a big feature to add if it provides some value.
nhoover commentedon Feb 13, 2021
I agree with the above and it seems like adding ping would also be good for monitoring. Or in my case, to simply implement a keep alive via cron in an environment like free Heroku where your app is taken down after 30 minutes of inactivity.