Skip to content

Commit 8ffc411

Browse files
committed
kvserver: rm unused ID in snapWriteBuilder
Epic: none Release note: none
1 parent 7396e56 commit 8ffc411

File tree

3 files changed

+1
-7
lines changed

3 files changed

+1
-7
lines changed

pkg/kv/kvserver/replica_raftstorage.go

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -627,8 +627,6 @@ func (r *Replica) applySnapshotRaftMuLocked(
627627
}
628628

629629
sb := snapWriteBuilder{
630-
id: r.ID(),
631-
632630
todoEng: r.store.TODOEngine(),
633631
sl: r.raftMu.stateLoader,
634632
writeSST: writeSST,

pkg/kv/kvserver/snapshot_apply_prepare.go

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,8 +22,6 @@ import (
2222
//
2323
// TODO(pav-kv): move this struct to kvstorage package.
2424
type snapWriteBuilder struct {
25-
id roachpb.FullReplicaID
26-
2725
todoEng storage.Engine
2826
sl kvstorage.StateLoader
2927
writeSST func(context.Context, func(context.Context, storage.Writer) error) error

pkg/kv/kvserver/snapshot_apply_prepare_test.go

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -86,7 +86,6 @@ func TestPrepareSnapApply(t *testing.T) {
8686
}
8787

8888
swb := snapWriteBuilder{
89-
id: id,
9089
todoEng: eng,
9190
sl: sl,
9291
writeSST: writeSST,
@@ -101,8 +100,7 @@ func TestPrepareSnapApply(t *testing.T) {
101100
},
102101
}
103102

104-
err := swb.prepareSnapApply(ctx)
105-
require.NoError(t, err)
103+
require.NoError(t, swb.prepareSnapApply(ctx))
106104

107105
// The snapshot construction code is spread across MultiSSTWriter and
108106
// snapWriteBuilder. We only test the latter here, but for information also

0 commit comments

Comments
 (0)