Commit Graph
183 Commits
Author SHA1 Message Date
Carl Johnsen 1a5fef36d7 Removed whitespace 2025-09-05 14:07:58 +02:00
Carl Johnsen b3fe276a13 Ensured that all temporary tables uset the same type of generated guid name 2025-09-05 14:06:55 +02:00
Carl Johnsen 2412800c0c Removed the sqlite page cache option. It should be set through the environment variable, or some other way of providing a custom database configurotion 2025-06-19 11:41:39 +02:00
Carl Johnsen 7e979a4e9b Found some methods in LocalBackupDatabase that didn't accept a cancellation token 2025-06-19 11:01:12 +02:00
Carl Johnsen 8039cbb0f6 Made the LocalBackupDatabase methods accept a cancellation token 2025-06-18 16:00:20 +02:00
Carl Johnsen 9ac583db94 Made all relevant using statements use await to use DisposeAsync 2025-06-18 11:53:11 +02:00
Carl Johnsen 859b65054d Simplified using statements that uses databases or accesses their methods 2025-06-18 11:52:05 +02:00
Carl Johnsen f221098c28 Formatted SQL queries - mainly adding double quotes where they were missing. 2025-06-18 10:42:08 +02:00
Carl Johnsen 8814fdebcc Added more docstrings 2025-06-17 15:13:33 +02:00
Carl Johnsen 1f97832546 Classes implementing DisposeAsync should also implement the interface 2025-06-17 15:11:25 +02:00
Carl Johnsen 1ece8398b6 Reordered tuple to match name 2025-06-17 14:02:18 +02:00
Carl Johnsen e81100de04 Started on adding docstrings 2025-06-17 09:59:22 +02:00
Carl Johnsen 3d11a05400 Added .ConfigureAwait(false) to all of the await statements 2025-06-12 08:34:29 +02:00
Carl Johnsen e5337e4d26 Formatted SQL queries 2025-06-11 12:09:58 +02:00
Carl Johnsen f373880c5a Renamed ExpandInClauseParameterAsync, as one of them isn't actually async.
Postfix mssqlite has been added as well to not clash with the IDb implementation
2025-06-11 10:47:40 +02:00
Carl Johnsen 9c2252f36c Ensured common order and interface for the async extension methods. 2025-06-11 10:46:04 +02:00
Carl Johnsen 087ff65646 Removed synchronous helper method 2025-06-11 07:41:03 +02:00
Carl Johnsen ff2e8ddd68 Found an SQL query missing the transaction 2025-05-28 05:53:44 +02:00
Carl Johnsen c4d550572a Added missing quotes around table name containing a dash (-), which led to a syntax error 2025-05-28 05:53:14 +02:00
Carl Johnsen e11d6377ac Construction chain was incorrect for LocalBackupDatabase 2025-05-26 09:06:42 +02:00
Carl Johnsen 5408570643 All SQL queries should be performed inside of a transaction 2025-05-26 09:03:21 +02:00
Carl Johnsen abc7c79841 Dispose made infinite recursion between different class derivations 2025-05-23 08:20:00 +02:00
Carl Johnsen dc4404e751 Added missing await 2025-05-22 15:28:35 +02:00
Carl Johnsen 22550be73c SQLite parameters are case sensitive. 2025-05-22 13:34:29 +02:00
Carl Johnsen 2cd1692532 Temporary fix to distinguish between new and legacy extension method 2025-05-22 13:25:42 +02:00
Carl Johnsen d11b4e58e7 Reworked the factory construction chains to forward an instantiated object where applicable 2025-05-21 07:24:36 +02:00
Carl Johnsen 3e3a9b5aa9 More SQL query restructuring 2025-05-20 06:07:45 +02:00
Carl Johnsen 0b508d2575 Started work on restructuring the SQL queries in LocalBackupDatabase. 2025-05-19 21:59:44 +02:00
Carl Johnsen d73a555647 Restructured the SQL queries in LocalBackupDatabase and made sure it's properly async 2025-05-19 15:43:55 +02:00
Carl Johnsen 48e6b61977 Purged IDb from LocalBackupDatabase 2025-05-19 14:40:00 +02:00
Carl Johnsen 4ab7f290a7 Updated LocalBackupDatabase to use factory construction 2025-05-19 13:19:24 +02:00
Kenneth SkovhedeandGitHub 171eb1bb12 Merge branch 'master' into feature/add-sqlite-cache-value 2025-04-23 16:34:55 +02:00
Kenneth Skovhede 3ff868b0f9 Removed tracking of files sizes, and implemented it with a database lookup 2025-04-23 15:39:32 +02:00
Kenneth Skovhede 0a7a1cd689 Added option to set the SQLite page cache
This adds an extra option to allow setting the SQLite page cache size as a regular option.

Prior to this commit it was only possible to set the SQLite page cache size via environment variables.

The option to use environment variables is preserved, and as options from the environment variable are applied after the new setting, environment variables take precedence.

The default value for the new option is to use 1% of the system memory for the page cache. For the restore process, a connection per worker may be made which defaults to half the number of cores, so the maximum amount of memory is 1% * half the CPU cores.

This is just the upper limit, and SQLite may choose not to use all of it.

This fixes #6178
2025-04-22 14:26:46 +02:00
Kenneth Skovhede 1095850965 Reworked the way deleted blocks are detected.
This should have a much lower performance impact.
2025-04-06 08:41:59 +02:00
Kenneth Skovhede cfad020ef2 Merge commit '61892a40d9aff663da86eda273505970268f6384' into feature/improve-block-reuse 2025-04-06 08:36:24 +02:00
Kenneth Skovhede 8b72528030 Re-implemented the change statistics calculation. 2025-04-05 21:42:05 +02:00
Kenneth Skovhede bb24036602 Fixed performance degradation after parameter queries 2025-04-05 09:25:10 +02:00
Kenneth Skovhede 0b735d79ff More cleanup and a few bug fixes 2025-04-03 16:38:51 +02:00
Kenneth Skovhede 2006556778 Fixed some more nullable support in the database layer 2025-04-03 15:46:20 +02:00
Kenneth Skovhede 9e3aa72d00 Added LocalBackupDatabase 2025-04-03 11:31:36 +02:00
Kenneth Skovhede f5061476c0 Merge remote-tracking branch 'origin/master' into feature/improve-block-reuse 2025-04-01 22:02:58 +02:00
Kenneth Skovhede 4a46918760 Additional cleanup in database files 2025-03-18 20:30:27 +01:00
Kenneth Skovhede 7234d43961 Fixed all SQL strings to use interpolation and forced them into the FormattableString handler using the invariant formatting. 2025-03-14 12:13:17 +01:00
Kenneth Skovhede f342d70819 Implemented forced invariant locale on all SQL strings.
This fixes #6023
2025-03-13 23:06:32 +01:00
Kenneth Skovhede be16323f24 General cleanup, common database validation exception 2025-03-10 14:38:45 +01:00
Kenneth Skovhede 9952e31f49 Fixed a bug where retention time was incorrectly parsed when reading from the database.
This effectively caused the retention time to be ignored when reading from the database.
Also moved some code related to finding an unfinished fileset into the common database class.
2025-03-08 15:13:03 +01:00
Kenneth Skovhede 9dfe977d3f Changed logic so the source providers are now logically mounted into the source directory structure.
This fixes the restore issues as all sources will now appear as if they were originally part of the source file system.

The backend implementation has now been simplified so the backends only return names of entries with no path information.  Most backends already do this, but the S3 backends did not, so this was fixed as well.

This also clears up the interfaces, so the backend does not know about the `ISourceProviderEntry`. All mapping is done by the `BackendSourceProvider`, making it simpler to support other backends as sources.
2025-02-21 16:06:55 +01:00
Kenneth Skovhede 1716d09b51 Fixed source providers for S3, CIFS, and SSH.
Made the SMBShareConnection slightly more robust.

Introduced v2 List API to S3 backend, currently it retains v1 as the default.

Changed S3 backends to not recurse, potentially making smaller listings. This option can be disabled if it breaks things.

Added support for relative paths in the SSH backend.
2025-02-21 13:20:52 +01:00
Kenneth SkovhedeandGitHub 9464caf622 Feature/update license 2025 (#5851)
* Fixed some minor whitespace issues

* Updated all copyright to 2025
2025-01-07 09:40:39 +01:00