Closed crisjf closed 4 years ago
Documenting solved issue.
When idle, this block of code was generating an insane amount of get requests:
do pause; idle_step_start<-machine_time/1000; loop while: (idle_mode) { string new_grid_hash_id <- get_grid_hash(); if ((new_grid_hash_id != grid_hash_id)) { idle_mode<-false; } } do resume;
The solution was to define idle_update_frequency and use machine_time to have control over the update frequency
idle_update_frequency
machine_time
do pause; idle_step_start<-machine_time/1000; loop while: (idle_mode) { if (machine_time/1000>=idle_step_start+idle_update_frequency) { string new_grid_hash_id <- get_grid_hash(); if ((new_grid_hash_id != grid_hash_id)) { idle_mode<-false; } idle_step_start<-machine_time/1000; } } do resume;
Documenting solved issue.
When idle, this block of code was generating an insane amount of get requests:
The solution was to define
idle_update_frequency
and usemachine_time
to have control over the update frequency