dropbigfish
6f9513d88c
chore: fix some function names
...
Signed-off-by: dropbigfish <fillfish@foxmail.com>
2024-09-01 00:54:39 +08:00
Michael Eischer
507842b614
fs: remove Open method from FS interface
2024-08-31 17:37:25 +02:00
Michael Eischer
263709da8c
fs: unexport isListxattrPermissionError
2024-08-31 17:37:25 +02:00
Michael Eischer
80ed863aab
repository: remove redundant cleanup code
...
The temp files used by the packer manager are either delete after
creation (unix) or marked as delete on close (windows). Thus, no
explicit cleanup is necessary.
2024-08-31 17:37:25 +02:00
Michael Eischer
0ddb4441d7
fs: clean up helper functions
2024-08-31 17:37:25 +02:00
Michael Eischer
fc549c9462
cleanup imports
2024-08-31 17:37:25 +02:00
Michael Eischer
b9b32e5647
restic: extract Node filesystem code to fs package
2024-08-31 17:37:25 +02:00
Michael Eischer
a2e54eac64
restic: simplify nodeCreateFileAt
...
The code to write the file content is never used.
2024-08-31 17:37:25 +02:00
Michael Eischer
5644079707
restic: prepare extraction of fs code from Node
2024-08-31 17:37:25 +02:00
Michael Eischer
97f696b937
backend: remove dead code
2024-08-31 17:25:24 +02:00
Michael Eischer
af989aab4e
backend/layout: unexport fields and simplify rest layout
2024-08-31 17:25:24 +02:00
Michael Eischer
6024597028
drop support for s3legacy layout
2024-08-31 17:25:24 +02:00
Michael Eischer
943b6ccfba
index: remove support for legacy index format
2024-08-31 17:12:43 +02:00
Michael Eischer
a5533344f9
Merge pull request #5028 from MichaelEischer/windows-allow-specifying-volumes
...
backup: support specifying volume instead of path on Windows
2024-08-31 16:43:20 +02:00
Michael Eischer
ddf35a60ad
Merge pull request #5026 from MichaelEischer/fix-handling-invalid-filenames
...
cache: Fix handling of invalid filenames
2024-08-31 16:42:13 +02:00
Michael Eischer
4fcedb4bae
backup: support specifying volume instead of path on Windows
...
"C:" (volume name) versus "C:\" (path)
2024-08-30 11:35:43 +02:00
Michael Eischer
a0f2dfbc19
Merge pull request #5019 from MichaelEischer/fix-windows-sd-race
...
backup: Fix spurious "A Required Privilege Is Not Held by the Client" error
2024-08-29 16:59:06 +02:00
Michael Eischer
0aadfe32bb
Merge pull request #5018 from MichaelEischer/rest-retry-http2-goaway
...
rest: improve handling of HTTP2 goaway
2024-08-29 16:58:04 +02:00
Michael Eischer
7bbf75237d
Merge pull request #5014 from MichaelEischer/configurable-slow-request-timeout
...
Make timeout for slow requests configurable
2024-08-29 16:52:24 +02:00
Michael Eischer
8eff4e0e5c
cache: correctly ignore files whose filename is no ID
...
this can for example be the case for temporary files created by the
backend implementation.
2024-08-29 16:32:15 +02:00
Michael Eischer
9c70794886
fs: fix error handling for retried get/set of security descriptor
...
The retry code path did not filter `ERROR_NOT_SUPPORTED`. Just call the
original function a second time to correctly follow the low privilege
code path.
2024-08-26 19:36:43 +02:00
Michael Eischer
6fbfccc2d3
fs: fix race condition in get/set security descriptor
...
Calling `Load()` twice for an atomic variable can return different
values each time. This resulted in trying to read the security
descriptor with high privileges, but then not entering the code path to
switch to low privileges when another thread has already done so
concurrently.
2024-08-26 19:31:21 +02:00
Michael Eischer
2296fdf668
lock: introduce short delay between failed locking retries
...
Failed locking attempts were immediately retried up to three times
without any delay between the retries. If a lock file is not found while
checking for other locks, with the reworked backend retries there is no
delay between those retries. This is a problem if a backend requires a
few seconds to reflect file deletions in the file listings. To work
around this problem, introduce a short exponentially increasing delay
between the retries. The number of retries is now increased to 4. This
results in delays of 5, 10 and 20 seconds between the retries.
2024-08-26 16:31:42 +02:00
Michael Eischer
89d216ca76
Merge pull request #5011 from MichaelEischer/fix-canceled-retry
...
backend/retry: don't trip circuit breaker if context is canceled
2024-08-26 16:30:03 +02:00
Michael Eischer
e24dd5a162
backend/retry: don't trip circuit breaker if context is canceled
...
When the context used for a load operation is canceled, then the result
is always an error independent of whether the file could be retrieved
from the backend. Do not false positively trip the circuit breaker in
this case.
The old behavior was problematic when trying to lock a repository. When
`Lock.checkForOtherLocks` listed multiple lock files in parallel and one
of them fails to load, then all other loads were canceled. This
cancelation was remembered by the circuit breaker, such that locking
retries would fail.
2024-08-26 16:22:21 +02:00
Michael Eischer
36c4475ad9
rest: improve handling of HTTP2 goaway
...
The HTTP client can only retry HTTP2 requests after receiving a GOAWAY
response if it can rewind the body. As we use a custom data type,
explicitly provide an implementation of `GetBody`.
2024-08-26 15:44:17 +02:00
Michael Eischer
b8f409723d
make timeout for slow requests configurable
2024-08-26 14:14:43 +02:00
Michael Eischer
311b27ced8
restic: cleanup redundant code in test case
2024-08-25 23:18:55 +02:00
Michael Eischer
43b36ad2b0
restore: test timestamps for macOS resource forks are restored correctly
2024-08-25 23:18:55 +02:00
Michael Eischer
2e55209b34
restic: restore timestamps after extended attributes
...
restoring the xattr containing resource forks on macOS apparently
modifies the file modification timestamps. Thus, restore the timestamp
after xattrs.
2024-08-25 23:18:55 +02:00
Michael Eischer
5cca6e66be
Merge pull request #4981 from konidev20/fix-gh-4934-cleanup-removed-snaphots-from-cache
...
cache: clear snapshot files from cache during load index
2024-08-16 19:04:59 +00:00
Srigovind Nayak
88174cd0a4
cache: remove redundant index file cleanup
...
addressing code review comments
2024-08-17 00:21:49 +05:30
Srigovind Nayak
b7d014b685
Revert "repository: removed redundant prepareCache method from Repository"
...
This reverts commit 720609f8ba
.
2024-08-17 00:18:13 +05:30
Michael Eischer
74d3f92cc7
Merge pull request #4993 from MichaelEischer/fix-timeout-error
...
backend: return correct error on upload/request timeout
2024-08-15 22:07:37 +02:00
Michael Eischer
80f24584a5
Merge pull request #4998 from zmanda/ea_vss_fix
...
Fix extended attributes handling for VSS snapshots
2024-08-15 19:51:35 +00:00
Michael Eischer
8e00158c34
Merge pull request #5000 from deining/fix-typo
...
Fix typos
2024-08-15 19:42:14 +00:00
Michael Eischer
36b5580c1c
Merge pull request #4989 from plant99/progress-bar-for-restore-verify
...
restore: Add progress bar to 'restore --verify'
2024-08-15 19:34:05 +00:00
aneesh-n
19f487750e
Add test cases and handle volume GUID paths
...
Gracefully handle errors while checking for EA and add debug logs.
2024-08-11 19:25:58 -06:00
Shivashis Padhi
f1407afd1f
restore: Add progress bar to 'restore --verify'
2024-08-11 22:25:21 +02:00
Andreas Deininger
4401265e36
Fix typos
2024-08-11 21:38:15 +02:00
Srigovind Nayak
5fd984ba6f
cache: add test for the automated cache clear to cache backend
2024-08-11 23:41:07 +05:30
Srigovind Nayak
720609f8ba
repository: removed redundant prepareCache method from Repository
...
* remove the prepareCache method from the Repository
* changed the signature of the SetIndex function to no longer return an error
2024-08-11 23:41:07 +05:30
Srigovind Nayak
a23e7bfb82
cache: check for context cancellation before clearing cache
2024-08-11 23:41:07 +05:30
Srigovind Nayak
f66624f5bf
cache: backend add List method and a cache clear functionality
...
* removes files which are no longer in the repository, including index files, snapshot files and pack files from the cache.
cache: fix ids set initialisation with NewIDSet()
2024-08-11 23:40:52 +05:30
aneesh-n
849c441455
Gracefully handle invalid prepared volume names
2024-08-11 01:48:25 -06:00
aneesh-n
1d392a36f9
Fix extended attributes handling for VSS snapshots
2024-08-11 01:23:47 -06:00
Michael Eischer
3f5e2160de
Merge pull request #4938 from MichaelEischer/bump-go-version
...
Bump go version to 1.21
2024-08-10 19:57:59 +02:00
Michael Eischer
283225f15f
Merge pull request #4994 from MichaelEischer/less-flaky-watchdog-test
...
backend: tweak timeouts to make watchdog timeout test less flaky
2024-08-10 19:35:38 +02:00
Michael Eischer
400ae55940
replace deprecated usages of math/rand
2024-08-10 19:34:49 +02:00
Michael Eischer
0b19f6cf5a
Switch back to sha256 from the std library
...
The std library now also supports the sha assembly instructions on
ARM64. Thus, sha256-simd no longer provides a performance benefit.
2024-08-10 19:16:10 +02:00