aboutsummaryrefslogtreecommitdiff
path: root/object/store/packed/internal
diff options
context:
space:
mode:
authorGravatar Runxi Yu2026-03-30 15:20:21 +0000
committerGravatar Runxi Yu2026-03-30 15:20:21 +0000
commitff4f4633d3896006616313038e7322ed7c4ced8c (patch)
tree73c3e78bb2ddbaaaec56da468b3a002dc7d7753b /object/store/packed/internal
parentobject/store: Expose pack writing options (diff)
signatureNo signature
object/store/packed: Rename Base to ThinBase
Diffstat (limited to 'object/store/packed/internal')
-rw-r--r--object/store/packed/internal/ingest/ingest_test.go2
-rw-r--r--object/store/packed/internal/ingest/options.go4
-rw-r--r--object/store/packed/internal/ingest/thin_fix.go4
3 files changed, 5 insertions, 5 deletions
diff --git a/object/store/packed/internal/ingest/ingest_test.go b/object/store/packed/internal/ingest/ingest_test.go
index 86a3e8e1..76e18a1e 100644
--- a/object/store/packed/internal/ingest/ingest_test.go
+++ b/object/store/packed/internal/ingest/ingest_test.go
@@ -280,7 +280,7 @@ func TestIngestThinPackWithFixThin(t *testing.T) {
result, err := writePack(bytes.NewReader(thinPack), packRoot, algo, ingest.Options{
FixThin: true,
WriteRev: true,
- Base: receiverRepo.Objects(),
+ ThinBase: receiverRepo.Objects(),
RequireTrailingEOF: true,
})
if err != nil {
diff --git a/object/store/packed/internal/ingest/options.go b/object/store/packed/internal/ingest/options.go
index 1ed4a123..06c334c0 100644
--- a/object/store/packed/internal/ingest/options.go
+++ b/object/store/packed/internal/ingest/options.go
@@ -11,8 +11,8 @@ type Options struct {
FixThin bool
// WriteRev writes a .rev alongside the .pack and .idx.
WriteRev bool
- // Base supplies existing objects for thin-pack fixup.
- Base objectstore.Reader
+ // ThinBase supplies existing objects for thin-pack fixup.
+ ThinBase objectstore.Reader
// Progress receives human-readable progress messages.
//
// When nil, no progress output is emitted.
diff --git a/object/store/packed/internal/ingest/thin_fix.go b/object/store/packed/internal/ingest/thin_fix.go
index f66ed279..5d701c52 100644
--- a/object/store/packed/internal/ingest/thin_fix.go
+++ b/object/store/packed/internal/ingest/thin_fix.go
@@ -25,7 +25,7 @@ func maybeFixThin(state *ingestState) error {
return &ThinPackUnresolvedError{Count: len(state.unresolvedRefDeltas)}
}
- if state.opts.Base == nil {
+ if state.opts.ThinBase == nil {
return &ThinPackUnresolvedError{Count: len(state.unresolvedRefDeltas)}
}
@@ -68,7 +68,7 @@ func maybeFixThin(state *ingestState) error {
var appended uint64
for _, id := range baseIDs {
- ty, content, err := state.opts.Base.ReadBytesContent(id)
+ ty, content, err := state.opts.ThinBase.ReadBytesContent(id)
if err != nil {
if errors.Is(err, objectstore.ErrObjectNotFound) {
continue