mirror of
https://github.com/restic/restic.git
synced 2024-08-22 12:23:29 +02:00
The SemaphoreBackend now uniformly enforces the limit of concurrent backend operations. In addition, it unifies the parameter validation. The List() methods no longer uses a semaphore. Restic already never runs multiple list operations in parallel. By managing the semaphore in a wrapper backend, the sections that hold a semaphore token grow slightly. However, the main bottleneck is IO, so this shouldn't make much of a difference. The key insight that enables the SemaphoreBackend is that all of the complex semaphore handling in `openReader()` still happens within the original call to `Load()`. Thus, getting and releasing the semaphore tokens can be refactored to happen directly in `Load()`. This eliminates the need for wrapping the reader in `openReader()` to release the token. |
||
---|---|---|
.. | ||
archiver | ||
backend | ||
bloblru | ||
cache | ||
checker | ||
crypto | ||
debug | ||
dump | ||
errors | ||
filter | ||
fs | ||
fuse | ||
hashing | ||
index | ||
migrations | ||
options | ||
pack | ||
repository | ||
restic | ||
restorer | ||
selfupdate | ||
test | ||
textfile | ||
ui | ||
walker |