From c1e88c078efb4076a87fc4a89de51f5d781df288 Mon Sep 17 00:00:00 2001 From: Andrew Werner Date: Thu, 22 Sep 2022 13:06:07 -0400 Subject: [PATCH] keys: mark 49 as reserved Release note: None --- pkg/keys/constants.go | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/pkg/keys/constants.go b/pkg/keys/constants.go index 67bbe31131c1..f2d6b7c86a6c 100644 --- a/pkg/keys/constants.go +++ b/pkg/keys/constants.go @@ -467,8 +467,20 @@ const ( SQLInstancesTableID = 46 SpanConfigurationsTableID = 47 RoleIDSequenceID = 48 + + // reservedSystemTableID is a sentinel constant to reserve the use of the + // last remaining constant reserved descriptor ID. In 22.1, we added support + // for creating system tables with dynamically allocated IDs. Use of this ID + // should be well motivated. There are cases where having a constant ID can + // dramatically simplify cluster bootstrap. Any table which is not going to + // be used quite early in the server startup process should not need a + // constant ID. Note that there are some values we could reclaim, like 9 and + // 10, but let's not go there unless we need to. + reservedSystemTableID = 49 ) +var _ = reservedSystemTableID // defeat the unused linter + // CommentType the type of the schema object on which a comment has been // applied. type CommentType int