Kenneth Skovhede
b280432476
Changed logic to use HashCalculatingStream instead of CryptoStream, which should fix #4094 .
...
Removed VolumeHashFactory as it dit not support using another hashing algorithm for volumes.
2024-09-28 11:13:06 +02:00
Kenneth Skovhede
473c6cbbb8
Merge commit '4f577c65a4d8806f79637c50c21ca3a683c5a07a' into feature/kestrel-avalonia-upgrade
2024-03-04 12:21:53 +01:00
Kenneth Skovhede
40dd3c6816
Updated all license mentions to MIT
2024-02-28 15:45:30 +01:00
Thomas Suckow
d8ddd6982c
Refactor VolumeHash
2021-04-04 08:28:44 -07:00
Max
c882953fdd
upstream
2020-05-31 13:50:13 +02:00
Kenneth Hsu
0c9ca9a75c
Remove unused BackendHandler members.
2020-03-29 16:48:19 -07:00
Sean Templeton
9739517b0a
Fix bandwidth throttling inconsistency
...
In code the throttling generally works backwards than what one would expect.
The streams that are throttled are the streams that operate on files from the local machine.
This fixes the download throttling not working and the upload throttling applying to
both uploads and downloads.
When doing a Put operation the stream on the local machine is reading from the
local filesystem and hence the upload throttle bytes per second needs to be
applied to the reading of the stream, not the writing.
Similarly when doing a Get operation the download throttle bytes per second needs
to be applied to the writing of the stream.
Fixes #4115
2020-03-04 19:57:48 -06:00
Max
41a5591532
upstream
2019-12-25 16:34:56 +01:00
Kenneth Hsu
2aa76881a5
Mark fields that don't need to be reassigned as readonly.
...
This makes it explicit at compile-time that these fields should not be
reassigned outside the constructor.
2019-10-19 13:59:22 -07:00
Michal Naiman
1bc1e58737
upstream
2019-04-28 13:45:26 +02:00
Sean Templeton
4f4529a88a
Move upload related code from BackendHandler to BackendUploader
...
As the BackendUploader is in charge of uploads the code has been moved
there to centralize the responsibility and prepare for parallel uploads.
2019-03-03 21:35:09 -06:00
Rune Henriksen and GitHub
be7edb580d
Merge pull request #3410 from warwickmm/simplify_enumerating_collections
...
Simplify enumeration of collections
2018-10-07 19:06:28 +02:00
Kenneth Hsu
0c1ac9c489
Replace chained LINQ calls with call to overload with predicate.
...
This simplifies the code by reducing the number of enumerators created
while also making the code slightly more readable.
2018-10-06 16:20:18 -07:00
Kenneth Hsu
d72128ec83
Remove unused method parameters.
2018-10-06 15:09:43 -07:00
Kenneth Hsu
1c8bb276b4
Allow tasks to complete on any thread when context is irrelevant.
...
When the code following the await can be executed on any thread, it's
recommended to use ConfigureAwait(false) to avoid unnecessary context
switching and potential deadlocks.
2018-09-19 16:57:17 -07:00
Max
a22a7a7d24
remove of FasterHashing component
2018-09-09 14:42:40 +02:00
Kenneth Hsu
1a2ee3a5ef
Simplify return type of synchronous methods.
...
Since these methods no longer have the async modifier, they do not need
to return a Task, and do not need to be awaited.
2018-07-04 15:35:14 -07:00
Kenneth Hsu
6c38651f19
Rename methods to clarify their synchronous behavior.
...
Since these methods no longer have the async modifier, we should not
include 'Async' in their names.
2018-07-04 15:35:14 -07:00
Kenneth Hsu
5e3f15ada4
Remove async modifier from methods that lack await.
...
A method marked async that does not use await will run synchronously.
By removing the async modifiers, we make it more explicit that these are
synchronous methods. This also addresses some compiler warnings, and
avoids the creation of the state machine used to handle asynchronous
operations.
2018-07-04 15:35:09 -07:00
Kenneth Skovhede
166ef2976b
Merge branch 'feature/cleanup_temp_files'
...
# Conflicts:
# Duplicati/Library/Main/Operation/Common/BackendHandler.cs
2018-06-28 12:17:22 +02:00
Kenneth Hsu
54c4f9224d
Allow tasks to complete on any thread when context is irrelevant.
...
When the code following the await can be executed on any thread, it's
recommended to use ConfigureAwait(false) to avoid unnecessary context
switching and potential deadlocks.
2018-06-21 19:28:27 -07:00
Kenneth Skovhede
be6093b7a6
Fixed unecrypted temporary files stored for upload were not removed.
2018-06-20 10:11:56 +02:00
Kenneth Skovhede
729baf76e6
Fixed registering the newly created index volume after upload has completed
2018-06-13 21:43:06 +02:00
Kenneth Hsu
f12858e6a5
Mark fields that shouldn't be reassigned as readonly.
...
This makes it explicit at compile-time that these fields should not be
reassigned outside the constructor.
2018-05-25 10:04:52 -07:00
Kenneth Skovhede
79f7b22e0f
Merge branch 'master' into concurrent_processing
...
Changed a few things on the way, removing the log process
# Conflicts:
# Duplicati/Library/Main/Controller.cs
# Duplicati/Library/Main/Database/ExtensionMethods.cs
# Duplicati/Library/Main/Database/LocalBackupDatabase.cs
# Duplicati/Library/Main/Duplicati.Library.Main.csproj
# Duplicati/Library/Main/Operation/BackupHandler.cs
# Duplicati/Library/Main/Operation/FilelistProcessor.cs
# Duplicati/Library/Main/Operation/PurgeBrokenFilesHandler.cs
# Duplicati/Library/Main/Operation/TestFilterHandler.cs
# Duplicati/Library/Main/Options.cs
# Duplicati/Library/Main/ResultClasses.cs
# Duplicati/UnitTest/BasicSetupHelper.cs
2018-04-11 23:02:47 +02:00
Kenneth Skovhede
75bf6857c1
Merge branch 'master' into concurrent_processing
...
# Conflicts:
# .travis.yml
# Duplicati/Library/Main/Database/LocalBackupDatabase.cs
# Duplicati/Library/Main/Operation/BackupHandler.cs
# Duplicati/Library/Main/ResultClasses.cs
# Duplicati/Library/Main/Volumes/VolumeWriterBase.cs
# Duplicati/Library/Utility/TempFile.cs
2018-01-20 15:02:41 +01:00
Kenneth Skovhede
860924bb62
Updated main functions to new CoCoL library
2017-09-20 21:03:24 +02:00
Kenneth Skovhede
bc6e32d049
Updated the new backend handler to support the same features as the previous: throttle, error message, and deleteGraceTime.
2017-09-19 14:24:59 +02:00
Kenneth Skovhede
14f1c58c64
Improved shutdown to avoid exceptions being masked by errors that occur during shutdown
2016-04-06 21:16:34 +02:00
Kenneth Skovhede
850c8e432b
Fixed a spelling error
2016-03-14 09:38:19 +01:00
Kenneth Skovhede
a3f2b39d23
Implemented handling of pause/stop/abort in the concurrent code.
...
Implemented the dry-run feature for backups.
2016-02-29 21:52:11 +01:00
Kenneth Skovhede
35f9a70b3d
Fixed resetting the backend
2016-02-25 23:33:55 +01:00
Kenneth Skovhede
537fe20838
Added a lot of comments.
...
Fixed a few issues that caused parallel uploads.
Fixed the use of the encryption module so the encryption module is not re-used for multiple jobs.
2016-02-25 19:15:51 +01:00
Kenneth Skovhede
20f7b42945
Fixed channels to use type-safe initializations.
...
Updated logging channel to use a wrapper for later early-filter optimizations.
Various bug fixes and optimizations.
2016-02-24 23:48:42 +01:00
Kenneth Skovhede
3ff2f1eb98
The concurrent processing now seems to work, at least in the base case.
...
Rewrote the handling of index volumes to create them on-demand instead of in-advance.
This makes it much simpler to handle upload failures.
2016-02-22 21:27:12 +01:00
Kenneth Skovhede
c297ca58dd
Fixed the duplicate hash computation solved in #1584
2016-02-18 22:39:47 +01:00
Kenneth Skovhede
086547e655
Implemented the missing details for the concurrent setup, it now compiles
2016-02-18 17:20:52 +01:00
Kenneth Skovhede
ec877696b0
More work on concurrent processing
2016-02-18 16:46:53 +01:00
Kenneth Skovhede
01c3b3f5c0
More work on a concurrent implementation of the backup process
2016-02-09 09:17:31 +01:00