Skip to content

Commit

Permalink
storage: default to TableFormatPebblev1 in backups
Browse files Browse the repository at this point in the history
If the v22.2 upgrade has not yet been finalized, so we're not permitted
to use the new TableFormatPebblev2 sstable format, default to
TableFormatPebblev1 which is the format used by v22.1 internally.

This change is intended to allow us to remove code for understanding the
old RocksDB table format version sooner (eg, v23.1).

Release justification: low-risk updates to existing functionality
Release note: None
  • Loading branch information
jbowens committed Aug 30, 2022
1 parent db1554b commit fdbeda5
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion pkg/storage/sst_writer.go
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@ func MakeBackupSSTWriter(ctx context.Context, cs *cluster.Settings, f io.Writer)
// By default, take a conservative approach and assume we don't have newer
// table features available. Upgrade to an appropriate version only if the
// cluster supports it.
opts := DefaultPebbleOptions().MakeWriterOptions(0, sstable.TableFormatRocksDBv2)
opts := DefaultPebbleOptions().MakeWriterOptions(0, sstable.TableFormatPebblev1)
if cs.Version.IsActive(ctx, clusterversion.EnablePebbleFormatVersionRangeKeys) {
opts.TableFormat = sstable.TableFormatPebblev2 // Range keys.
}
Expand Down

0 comments on commit fdbeda5

Please sign in to comment.