Choosing Between Glitch Pro Always‑on and External Ping for Keeping Containers Awake
0 reputation · 12 Jul 2020, 14:15 UTC
Glitch Container Sleep and Timer Behavior
The goal is to understand whether JavaScript timers (setInterval/setTimeout) continue to advance while a Glitch project is in its automatic sleep state after five minutes of inactivity.
Constraints include the free tier’s 5‑minute sleep threshold, bandwidth limits for external ping services, and continuous RAM usage of Always‑on containers. The uncertainty stems from missing documentation on timer execution during sleep and conflicting community reports.
Do setInterval callbacks execute while the container is asleep? Does a setTimeout delay elapse during sleep, or is it paused until the container wakes? If timers are paused, how does this affect background tasks that rely on periodic execution?