Farmbot-Web-App
Farmbot-Web-App copied to clipboard
Device log throttling issues and improvements
- [ ] Frontend should receive
throttled_at
andthrottled_until
changes without a refresh. This is related todeviceIsThrottled
andBatchQueue
, which may not be working correctly. - [ ] It should be possible to initiate throttling from any log type. Currently it takes a log type other than
fun
ordebug
to initiate the cooldown period when the rate limit has already been reached by those log types. - [ ] Throttling should end when the cooldown period ends rather than after a log of a type other than
fun
ordebug
has been sent. - [ ] Users should be notified upon termination of throttling (cooldown period) rather than after a new log message has been sent.
- [ ] Logs that would not display on any filter setting should be removed from frontend resources after the maximum log count has been reached.
To reproduce
- Enable firmware response logs (
firmware_input_log
) with a device connected. - Wait a couple minutes. (Observe no throttling.)
- Perform an action that creates a normal log near the end of a clock minute. (Observe "throttle begin" notice while logs continue to appear in frontend.)
- Perform an action that creates a normal log near the beginning of the next clock minute. (Observe "throttle end" notice.)
- Repeat, this time refreshing after step 3. (Observe logs no longer appear in frontend.)
Will investigate item 1. Might be possible to send fatal_email when cooldown ends. The others probably won't get fixed, given current staffing.