Skip to content

Commit be3e9d9

Browse files
committed
storage: use minimum supported version for TransportSSTWriter
MakeTransportSSTWriter is used when evaluating export requests. These requests can be issued by non-system tenants which can run older binaries. Since we have currently have no way of knowing what binary version that is, we must emit at the minimum supported version. Fixes #152723
1 parent dec7e21 commit be3e9d9

File tree

1 file changed

+7
-1
lines changed

1 file changed

+7
-1
lines changed

pkg/storage/sst_writer.go

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -117,7 +117,13 @@ func makeSSTRewriteOptions(
117117
// scanned and their keys inserted into new sstables (NB: constructed using
118118
// MakeIngestionSSTWriter) that ultimately are uploaded to object storage.
119119
func MakeTransportSSTWriter(ctx context.Context, cs *cluster.Settings, f io.Writer) SSTWriter {
120-
format := minPebbleFormatVersionInCluster(cs.Version.ActiveVersion(ctx).Version).MaxTableFormat()
120+
// MakeTransportSSTWriter is used to evaluate export requests. The export
121+
// requests could be issued by a non-system tenant with an older binary, so we
122+
// must emit at the minimum supported version.
123+
//
124+
// TODO(radu): ideally the tenant would be able to specify the desired format
125+
// version (#153283).
126+
format := MinimumSupportedFormatVersion.MaxTableFormat()
121127

122128
opts := DefaultPebbleOptions().MakeWriterOptions(0, format)
123129

0 commit comments

Comments
 (0)