streamingccl,sql: add sql syntax and ingestion planning logic#59112
Merged
craig[bot] merged 2 commits intocockroachdb:masterfrom Jan 29, 2021
Merged
streamingccl,sql: add sql syntax and ingestion planning logic#59112craig[bot] merged 2 commits intocockroachdb:masterfrom
craig[bot] merged 2 commits intocockroachdb:masterfrom
Conversation
Member
pbardea
reviewed
Jan 19, 2021
| } | ||
|
|
||
| // We only support a TENANT target, so error out if that is nil. | ||
| if ingestionStmt.Targets.Tenant == (roachpb.TenantID{}) { |
Contributor
There was a problem hiding this comment.
Should we also check that the other targets are nil and error out if they're not?
| StreamAddress: streamingccl.StreamAddress(from[0]), | ||
| Span: roachpb.Span{Key: prefix, EndKey: prefix.Next()}, | ||
| // TODO: Figure out what the initial ts should be. | ||
| StartTime: hlc.Timestamp{}, |
Contributor
There was a problem hiding this comment.
This will end up being the endtime of the backup that we're restoring when that is hooked up. I think that keeping it at empty should be good for now.
09104ae to
70f88cc
Compare
This change adds basic SQL syntax to start the ingestion job which will read from the replication stream it is pointed to, and ingest the KVs into the destination tenant's keyspace. Release note (sql change): add SQL syntax for `RESTORE tenant x FROM REPLICATION STREAM FROM 'replication_stream'`. This allows the user to start an ingestion job to ingest KVs from the replication stream into the destination tenant's keyspace.
This change adds the boiler plate plan hook that configures and starts up the ingestion job. Release note: None
70f88cc to
320a77b
Compare
pbardea
approved these changes
Jan 29, 2021
Contributor
Author
|
TFTR! bors r=pbardea |
Contributor
|
Build succeeded: |
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
commit 1 - add ingestion job SQL syntax
commit 2 - add ingestion job plan hook and hookup planning, job, and processors.