Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add ability to cancel PKI tidy operations, pause between tidying certs (
#16958) * Allow tidy operations to be cancelled When tidy operations take a long time to execute (and especially when executing them automatically), having the ability to cancel them becomes useful to reduce strain on Vault clusters (and let them be rescheduled at a later time). To this end, we add the /tidy-cancel write endpoint. Signed-off-by: Alexander Scheel <[email protected]> * Add missing auto-tidy synopsis / description Signed-off-by: Alexander Scheel <[email protected]> * Add a pause duration between tidying certificates By setting pause_duration, operators can have a little control over the resource utilization of a tidy operation. While the list of certificates remain in memory throughout the entire operation, a pause is added between processing certificates and the revocation lock is released. This allows other operations to occur during this gap and potentially allows the tidy operation to consume less resources per unit of time (due to the sleep -- though obviously consumes the same resources over the time of the operation). Signed-off-by: Alexander Scheel <[email protected]> * Add tests for cancellation, pause Signed-off-by: Alexander Scheel <[email protected]> * Add API docs on pause_duration, /tidy-cancel Signed-off-by: Alexander Scheel <[email protected]> * Add changelog entry Signed-off-by: Alexander Scheel <[email protected]> * Add lock releasing around tidy pause Signed-off-by: Alexander Scheel <[email protected]> * Reset cancel guard, return errors Signed-off-by: Alexander Scheel <[email protected]> Signed-off-by: Alexander Scheel <[email protected]>
- Loading branch information