You can schedule Hex apps to re-run on a set schedule, at Hourly, Daily, Weekly, or Monthly frequencies.
$hex_scheduled variable is a boolean that evaluates to
true if the logic run is scheduled, e.g., so a database write-back is only triggered on a scheduled run. This can be useful for workflows with long-running or computationally expensive query steps, so the app is more responsive for end users. This can be achieved using a pattern like the below:
if $hex_scheduled:## expensive query step## write results out to a file or databaseelse:## read from written file or database