forked from cockroachdb/cockroach
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
lease: fix lease retention bug for tables taken offline
Tables can temporarily be taken offline, either permanently or temporarily. For example, executing a DROP TABLE statement will take a table offline permanently, and an IMPORT INTO will take a table offline only for the duration of the import and will bring it online again afterward. Previously, the lease manager would not distinguish between those two cases and would behave as if the table was gone forever. As a result any lease acquired after the table came back online would always be dropped upon dereferencing. Although this behavior is valid, it is inefficient, hence this patch. Fixes cockroachdb#57834. Release note: None
- Loading branch information
Marius Posta
committed
Jan 25, 2021
1 parent
59ee86b
commit a060650
Showing
4 changed files
with
131 additions
and
14 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters