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.
streamingccl: physical replication stream from given timestamp
This adds a RESUME TIMESTAMP option to CREATE VIRTUAL CLUSTER FROM REPLICATION. When provided, we allow the user to start a replication stream into an _existing_ virtual cluster. When the resume timestamp is provided, the replication stream will be started from that timestamp, with no initial scan. To facilitate this, we add a new argument to crdb_internal.start_replication_stream that allows us to pass a destination-choosen start timestamp. To avoid various catastrophic mistakes, we only allow this when: - The destination tenant must be in service mode None - The provided resume timestamp equals the last recorded "revert timestamp" of the destination tenant. The revert timestamp is set when the tenant has been forcibly reverted to a particular timestamp and is cleared when the tenant is modified in a way that may invalidate a resumption from that timestamp. - If the source tenant has a PreviousSourceTenant set, the new destination must match that previous source tenant field. WARNING: Using this correctly requires that the stream is resumed before garbage collection has progressed past the given resume timestamp. During normal operation, the replication stream maintains a protected timestamp to ensure this is the case. However, when resuming using this new feature, we have no such guarantee. Epic: none Release note: None
- Loading branch information
1 parent
330500d
commit 2e0f18b
Showing
33 changed files
with
755 additions
and
165 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
Oops, something went wrong.