summaryrefslogtreecommitdiff
AgeCommit message (Collapse)AuthorFilesLines
2022-10-26use new chnunk store for backup client fetch_chunkLars Wirzenius1-3/+1
Sponsored-by: author
2022-10-26use new ChunkStore for remote has_chunkLars Wirzenius2-16/+14
Sponsored-by: author
2022-10-26feat: add a new ChunkStore to store chunks locally or remotelyLars Wirzenius2-0/+305
Sponsored-by: author
2022-10-23Merge branch 'liw/chore' into 'main'Lars Wirzenius1-1/+1
chore: use push_back instead of deprecated push See merge request obnam/obnam!239
2022-10-23chore: use push_back instead of deprecated pushLars Wirzenius1-1/+1
Sponsored-by: author
2022-10-23Merge branch 'refactor-clap' into 'main'Lars Wirzenius18-362/+454
refactor: use clap instead of structopt Closes #209 See merge request obnam/obnam!238
2022-10-23refactor: use clap instead of structoptLars Wirzenius18-362/+454
clap version 3 basically replaces structopt entirely. Sponsored-by: author
2022-09-09Merge branch 'fixes' into 'main'Lars Wirzenius8-33/+31
fix things so ./chec k passes for me again See merge request obnam/obnam!237
2022-09-09fix: use separate subplot YAML metadata file for new SubplotLars Wirzenius3-26/+25
Subplot has just made a breaking change: the subplot document metadata must be in a separate YAML file, not embedded in the markdown. This adapts Obnam to that. It's a little awkward that Subplot hasn't made a release of this yet, but as I use Subplot from git, I need this now. Sponsored-by: author
2022-09-09chore: tidy up things to satisfy clippyLars Wirzenius5-7/+6
Sponsored-by: author
2022-08-14Merge branch 'liw/api-threat-model' into 'main'Lars Wirzenius1-0/+17
docs: add threat model for wide-open API See merge request obnam/obnam!236
2022-08-14docs: add threat model for wide-open APILars Wirzenius1-0/+17
Sponsored-by: author
2022-08-14Merge branch 'liw/chunking' into 'main'Lars Wirzenius1-0/+147
docs: add thoughts about chunk splitting approached to obnam.md Closes #125 See merge request obnam/obnam!235
2022-08-14docs: add thoughts about chunk splitting approached to obnam.mdLars Wirzenius1-0/+147
Sponsored-by: author
2022-07-24Merge branch 'release' into 'main'v0.8.0Lars Wirzenius5-253/+299
chore: update dependency versions, deny.toml See merge request obnam/obnam!234
2022-07-24fix: drop depeneency on pbkdf2 to 0.10, for rustc 1.56.0Lars Wirzenius2-7/+7
Sponsored-by: author
2022-07-24fix: drop back to rpassword 5 so that Rust 1.56.0 worksLars Wirzenius3-4/+4
Sponsored-by: author
2022-07-24chore: update debian/changelog for releaseLars Wirzenius1-0/+6
Sponsored-by: author
2022-07-24chore: update version number for releaseLars Wirzenius3-3/+3
Sponsored-by: author
2022-07-24docs: update release notesLars Wirzenius1-0/+52
Sponsored-by: author
2022-07-24chore: update dependency versions, deny.tomlLars Wirzenius4-262/+250
This is part of release preparation. Sponsored-by: author
2022-07-17Merge branch 'liw/chore' into 'main'Lars Wirzenius3-6/+4
chore: make code more idiomatic, based on clippy warnings See merge request obnam/obnam!233
2022-07-17chore: make code more idiomatic, based on clippy warningsLars Wirzenius3-6/+4
Sponsored-by: author
2022-05-15Merge branch 'fix-link' into 'main'Lars Wirzenius1-2/+2
fix: links to tutorial, subplot rendered output Closes #211 See merge request obnam/obnam!232
2022-05-15fix: links to tutorial, subplot rendered outputLars Wirzenius1-2/+2
Sponsored-by: author
2022-05-10Merge branch 'liw/integer-test' into 'main'Lars Wirzenius6-56/+199
add tests for storing max integers (change FileId to signed) Closes #188 See merge request obnam/obnam!231
2022-05-03refactor: add a builder for file system entriesLars Wirzenius2-83/+145
The previous commit introduced a function to create FilesystemEntry values from arbitrary data. Previously one could only be created from std::fs::Metadata. This complicated our own testing, which (now) needs to construct an arbitrary entry structure. However, while the function added in the last commit was straightforward, it had 11 arguments, and that's hard to keep track of. Replace that function with an EntryBuilder struct, for clarity. Sponsored-by: author
2022-05-03test: add test for storing, retrieving u64::MAX values in JSONLars Wirzenius3-15/+77
The test passes. We create a FilesystemEntry with a length field containing u64::MAX, store that into a generation, and read it back. This works. The entry is serialised into JSON for storing in SQLite, and this proves we can handle any u64 value in an entry. serde_json deals with it fine, and we don't need to worry about it. Sponsored-by: author
2022-05-03feat! only store signed 64-bit plain integers in databaseLars Wirzenius1-1/+14
This is a breaking change, but allows to store the largest signed 64-bit integers in SQLite and get it back. Sponsored-by: author
2022-05-03refactor: add a type for plain integers we store in a databaseLars Wirzenius4-17/+23
This will make it easier to change later, if need be. We may want to do that for various reasons, such as to save space. We may also want to change things to only use integer types that SQLite can handle: u64 is currently not well handled by our database layer. However, as this is a refactor, there's no change or fix to that. FileId is now explicitly a database integer. This doesn't break anything, for now, as the underlying integer type is still u64. Also, change a couple of places where it will matter if DbInt changes away from u64, and disable warnings for harmless conversions that may cause warnings depending on what type DbInt has. Sponsored-by: author
2022-04-22Merge branch 'liw/gen-size' into 'main'Lars Wirzenius2-5/+45
show SQLite file size Closes #29 See merge request obnam/obnam!230
2022-04-22Merge branch 'liw/cachedir.tag-doc' into 'main'Lars Wirzenius1-1/+3
docs: add a note of why CACHEDIR.TAG itself gets backed up Closes #190 See merge request obnam/obnam!229
2022-04-21feat: show-generation shows size of the generation's SQLite dbLars Wirzenius1-0/+9
Sponsored-by: author
2022-04-21feat: change "show-generation" output to JSONLars Wirzenius2-5/+36
This is more friendly towards anyone wanting to use the output in a script. Sponsored-by: author
2022-04-21docs: add a note of why CACHEDIR.TAG itself gets backed upLars Wirzenius1-1/+3
Sponsored-by: author
2022-04-19Merge branch 'liw/checksum-types-try2' into 'main'Lars Wirzenius20-124/+313
add support for migrating to new checksum types Closes #203 See merge request obnam/obnam!228
2022-04-16feat: use one checksum for all chunks in a backupLars Wirzenius11-42/+184
When making a backup, use the same checksum for any chunks it re-uses or creates. This is for performance: if we allowed two checksums to be used, we would have to compute the checksum for a chunk twice, and potentially look up both on the server. This is just a lot of work. Instead, we use only one. The trade-off here is that when (not if) the user wants to switch to a new checksum type, they'll have to do a full backup, uploading all their data to the server, even when it's already there, just with a different checksum. Hopefully this will be rare. Full backups always use the built-in, hardcoded default checksum, and incremental backups use whatever the previous backup used. The default is still SHA256, but this commit add code to support BLAKE2 if we decide to switch that as a default. It's also easy to add support for others, now. BLAKE2 was added to verify that Obnam can actually handle the checksum changing (manual test: not in the test suite). I don't think users need to be offered even the option of choosing a checksum algorithm to use. When one cares about both security and performance, choosing a checksum requires specialist, expert knowledge. Obnam developers should choose the default. Giving users a knob they can twiddle just makes it that much harder to configure and use Obnam. If the choice Obnam developers have made is shown to be sub-optimal, it seems better to change the default for everyone, rather than hope that every user changes their configuration to gain the benefit. Experience has shown that people mostly don't change the default configuration, and that they are especially bad at choosing well when security is a concern. (Obnam is free software. Expert users can choose their checksum by changing the source code. I'm not fundamentally limiting anyone's freedom or choice here.) Users can switch to a new default algorithm by triggering a full backup with the new "obnam backup --full". Sponsored-by: author
2022-04-16feat! change how chunk labels are serializedLars Wirzenius5-28/+65
Serialized labels now start with a type prefix: a character that says what type of label it is. This isn't strictly required: we _can_ just decide to always use a single type of checksum for all chunks in one backup, for one client, or in the whole repository. However, if it's ever possible to have more than one type, it helps debugging if every checksum, when serialized, is explicit about its type. Change things to use the new serialize method instead of the Display trait for Label. We're primarily serializing labels so they can be stored in a database, and used in URLs, only secondarily showing them to users. Sponsored-by: author
2022-04-16refactor: rename Checksum to LabelLars Wirzenius10-39/+39
Label is a clearer and more accurate name for the type now that it is not just a checksum. Also, serialize a Label in tests, rather than using string literals. This is more correct, and we'll be changing serialization later. Sponsored-by: author
2022-04-16refactor: add a Literal variant to ChecksumLars Wirzenius3-6/+16
We've had fake checksums that are just arbitrary literal strings, and this change makes this more explicit. It's a preliminary change for later support for additional checksum algorithms. Sponsored-by: author
2022-04-07Merge branch 'liw/api-v1' into 'main'Lars Wirzenius5-27/+35
feat! add chunk server API version to HTTP paths Closes #202 See merge request obnam/obnam!227
2022-04-06feat! add chunk server API version to HTTP pathsLars Wirzenius5-27/+35
What was /chunks is now /v1/chunks. This is the minimal step to start supporting multiple API versions. Also, /v1/chunks/foo/bar is no longer supported. Sponsored-by: author
2022-04-06Merge branch 'perf-stats-3' into 'main'Lars Wirzenius6-10/+209
Log some performance measurements Closes #174 See merge request obnam/obnam!226
2022-04-05feat: collect and log some time metricsLars Wirzenius5-32/+32
Log the complete run-time of the program, and the time spent downloading the previous generation, and uploading the new generation. Sponsored-by: author
2022-04-05feat: add data structures for accumulating time measurementsLars Wirzenius3-0/+199
Sponsored-by: author
2022-03-29Merge branch 'feature/remove-debug-prints' into 'main'Lars Wirzenius2-3/+0
Remove debug prints See merge request obnam/obnam!225
2022-03-28Remove debug printsAlexander Batischev2-3/+0
2022-03-23Merge branch 'liw/trust-root' into 'main'Lars Wirzenius17-179/+253
Add chunk that lists all generations Closes #62 and #34 See merge request obnam/obnam!224
2022-03-22docs: update obnam.md about client trust root chunkLars Wirzenius1-25/+18
Sponsored-by: author
2022-03-22feat! drop generation related fields from chunk metadataLars Wirzenius7-131/+21
Sponsored-by: author