feat: content-type headers, CLI tests, and spec promotion#19
Conversation
…cture Add contentType parameter to IBlobStorageService.UploadAsync so each blob type gets a descriptive HTTP Content-Type header (e.g. application/aes256cbc+tar+gzip for encrypted tar bundles, text/plain for thin pointers). This makes chunk types identifiable without inspecting custom metadata. Add IsEncrypted property to IEncryptionService to cleanly select encrypted vs plaintext content-type variants. Add ContentTypes constants class and wire content-type through all six upload call sites (large, tar, thin, snapshot, filetree, chunk-index). Add blob storage structure section to README with a mermaid diagram explaining the container layout, each prefix's purpose, and how snapshots, file trees, chunks, and the chunk index relate.
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## master #19 +/- ##
==========================================
+ Coverage 77.08% 77.23% +0.15%
==========================================
Files 21 21
Lines 2199 2214 +15
Branches 234 239 +5
==========================================
+ Hits 1695 1710 +15
Misses 446 446
Partials 58 58 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
|
Caution Review failedPull request was closed or merged during review 📝 WalkthroughWalkthroughThis PR introduces comprehensive specification documentation for the Arius archive and restore pipelines, blob storage architecture, encryption model, and CLI requirements. It extends the blob storage interface to support explicit content-type metadata, adds encryption state detection to services, and threads content-type values through archive/restore operations and service implementations. Changes
Estimated code review effort🎯 3 (Moderate) | ⏱️ ~25 minutes 🚥 Pre-merge checks | ✅ 2 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (2 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
Comment |
Summary
ContentTypesconstants class,IsEncryptedproperty onIEncryptionService, and wired content-type through all 6 upload call sites.Arius.Cli.Testsproject with TUnit/NSubstitute/Shouldly for testing CLI command parsing, option validation, and DI wiring without Azure credentials.arius-core-foundationchange: created main specs forblob-storage,encryption,archive-pipeline,ls-command,restore-pipeline, and added progress display requirements to the existingclispec.Content-Type mapping
application/aes256cbc+gzipapplication/gzipapplication/aes256cbc+tar+gzipapplication/tar+gziptext/plain; charset=utf-8text/plain; charset=utf-8application/jsonapplication/jsonapplication/aes256cbc+gzipapplication/gzipapplication/aes256cbc+gzipapplication/gzipTest results
All 133 tests pass (68 core + 3 architecture + 17 CLI + 45 integration).
Summary by CodeRabbit
Documentation
Chores