If you run pause -wait-time 1h, then (before that hour is passed) run another pause command, you would expect that the previous action postponed to +1h is canceled. This is not the case.
The error is that the togglePause goroutine is never canceled.
If you run `pause -wait-time 1h`, then (before that hour is passed) run another pause command, you would expect that the previous action postponed to +1h is canceled. This is not the case.
Here is an example.
```
% curl --unix-socket /tmp/circologd-ctl.sock 'localhost/status' -s|jq .
{
"status": {
"paused": false,
"size": 20
}
}
% circologctl pause -wait-time '5s'
paused
% circologctl pause
unpaused
# wait some seconds...
toggling again
% curl --unix-socket /tmp/circologd-ctl.sock 'localhost/status' -s|jq .
{
"status": {
"paused": true,
"size": 20
}
}
```
The error is that the `togglePause` goroutine is never canceled.
If you run
pause -wait-time 1h
, then (before that hour is passed) run another pause command, you would expect that the previous action postponed to +1h is canceled. This is not the case.Here is an example.
The error is that the
togglePause
goroutine is never canceled.