-
Notifications
You must be signed in to change notification settings - Fork 3.8k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
95791: backup: allow restricting backup coordination by region r=dt a=dt The coordinator of a backup job needs to access the 'default' locality to read and write metadata including the backup checkpoint files and manifest. Prior to this change, this meant that every node in the cluster needed to be able to access this default locality storage location, since any node could become the coordinator. This change introduces a new locality filter option that can be specified when the backup job is created. If set, this new option will cause any node which attempts to execute the backup job to check if it meets the locality requirements and, if not, move the execution of the job to a node which does meet them, or fail if not such node can be found. A locality requirement is specified as any number of key=value pairs, each of which a node must match to be eligible to execute the job, for example, a job run with BACKUP ... WITH coordinator_locality = 'region=east,cloud=azure' would require a node have both 'region=east' and 'cloud=azure', however the order is not significant, only that each specified filter is met. Jobs typically begin executing directly on the node on which they are created so if that node has matching localities, it will execute the job, or relocate it if it does not. Relocated executions may take some amount of time to resume on the new node to which they were relocated, similar to the delay seen when a paused job is resumed, typically between a few seconds to a minute. Note that this only restricts the *coordination* of the backup job -- reading the row data from individual ranges and exporting that data to the destination storage location or locations is still performed by many nodes, typically the leaseholders for each range. Release note (enterprise change): coordination of BACKUP jobs and thus writing of BACKUP metadata can be restricted to nodes within designated localities using the new 'coordinator_locality' option. Epic: [CRDB-9547](https://cockroachlabs.atlassian.net/browse/CRDB-9547). 96802: opt: mark ConvertUncorrelatedExistsToCoalesceSubquery as essential r=mgartner a=mgartner This rule converts uncorrelated `EXISTS` subqueries into `COALESCE`+subquery expressions. It is essential because execbuilder cannot plan lazily-executed, uncorrelated `EXISTS` subqueries. Fixes #95546 Release note: None Co-authored-by: David Taylor <tinystatemachine@gmail.com> Co-authored-by: Marcus Gartner <marcus@cockroachlabs.com>
- Loading branch information
Showing
16 changed files
with
261 additions
and
24 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
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
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
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
Oops, something went wrong.