-
Notifications
You must be signed in to change notification settings - Fork 472
Add documentation for new backup and restore cloud API endpoints #20012
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Conversation
Files changed:
|
✅ Deploy Preview for cockroachdb-interactivetutorials-docs canceled.
|
✅ Deploy Preview for cockroachdb-api-docs canceled.
|
✅ Deploy Preview for cockroachdb-api-docs canceled.
|
❌ Deploy Preview for cockroachdb-docs failed. Why did it fail? →
|
❌ Deploy Preview for cockroachdb-docs failed. Why did it fail? →
|
❌ Deploy Preview for cockroachdb-docs failed. Why did it fail? →
|
✅ Netlify Preview
To edit notification comments on pull requests, go to your Netlify project configuration. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Would you be able to fix the first link for "Managed backups" in the following section? https://deploy-preview-20012--cockroachdb-docs.netlify.app/docs/cockroachcloud/backup-and-restore-overview#managed-backups
It currently points to the same page. Please make it point to https://deploy-preview-20012--cockroachdb-docs.netlify.app/docs/cockroachcloud/managed-backups
I just realized that it is in an include file as the intro paragraph for the managed-backup pages.
lgtm pending suggestions (mostly nits about verb tense)
src/current/_includes/cockroachcloud/backups/cloud-api-restore-endpoint.md
Outdated
Show resolved
Hide resolved
src/current/_includes/cockroachcloud/backups/cloud-api-restore-endpoint.md
Outdated
Show resolved
Hide resolved
src/current/_includes/cockroachcloud/backups/cloud-api-restore-endpoint.md
Outdated
Show resolved
Hide resolved
src/current/_includes/cockroachcloud/backups/cloud-api-restore-endpoint.md
Outdated
Show resolved
Hide resolved
src/current/_includes/cockroachcloud/backups/cloud-api-restore-endpoint.md
Outdated
Show resolved
Hide resolved
src/current/_includes/cockroachcloud/backups/cloud-api-restore-endpoint.md
Outdated
Show resolved
Hide resolved
src/current/_includes/cockroachcloud/backups/cloud-api-restore-endpoint.md
Outdated
Show resolved
Hide resolved
src/current/_includes/cockroachcloud/backups/cloud-api-restore-endpoint.md
Outdated
Show resolved
Hide resolved
src/current/_includes/cockroachcloud/backups/cloud-api-restore-endpoint.md
Outdated
Show resolved
Hide resolved
src/current/_includes/cockroachcloud/backups/cloud-api-backup-view.md
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lgtm - left a few notes!
"status": "PENDING", | ||
"created_at": "2025-07-25T16:45:14.064208710Z", | ||
"type": "CLUSTER", | ||
"completion_percent": 0 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nit - can we say 100 as that would be 100% completed aka successful?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@linhcrl I believe on Intrusion we return a float64 (i.e. 1
instead of 100
). Does Console update this to a percentage value?
@@ -0,0 +1,288 @@ | |||
### Restore from a managed backup | |||
|
|||
You can use the `/v1/clusters/{cluster_id}/restores` endpoint to restore the contents of a managed backup at the cluster, database, or table level. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
can we change {cluster_id} to {target_cluster_id} to indicate that its the cluster that we intend to restore to? and change that on all subsequent fields where this is used?
#### Restore a cluster | ||
|
||
{{site.data.alerts.callout_danger}} | ||
The restore operation completely erases all data in the destination cluster. All cluster data is replaced with the data from the backup. The destination cluster will be unavailable while the job is in progress. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We need to update the docs here - we actually don't delete everything anymore. The restore will be blocked from initiating if a user has a table/database that exists in the cluster. @benbardin in a full cluster restore, its blocked if there are objects in the target cluster right?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, it is now the responsibility of the user to wipe all tables in their cluster.
- Not Ben Bardin
@@ -0,0 +1,288 @@ | |||
### Restore from a managed backup | |||
|
|||
You can use the `/v1/clusters/{cluster_id}/restores` endpoint to restore the contents of a managed backup at the cluster, database, or table level. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
A database
or table
level backup can only be done on an Advanced cluster. Serverless clusters like Basic or Standard only support cluster level restores.
"backup_id": "example-2d25-4a64-8172-28af7a0d41cc", | ||
"status": "PENDING", | ||
"created_at": "2025-07-25T16:45:14.064208710Z", | ||
"type": "table", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
table
should be in all caps.
#### Restore a cluster | ||
|
||
{{site.data.alerts.callout_danger}} | ||
The restore operation completely erases all data in the destination cluster. All cluster data is replaced with the data from the backup. The destination cluster will be unavailable while the job is in progress. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, it is now the responsibility of the user to wipe all tables in their cluster.
- Not Ben Bardin
"status": "PENDING", | ||
"created_at": "2025-07-25T16:45:14.064208710Z", | ||
"type": "CLUSTER", | ||
"completion_percent": 0 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@linhcrl I believe on Intrusion we return a float64 (i.e. 1
instead of 100
). Does Console update this to a percentage value?
Co-authored-by: Florence Morris <[email protected]>
Fixes DOC-11599
Add task-oriented guidance to our docs around using the cloud API to:
Opted to break out our existing include(s) for human readability due to different functionality between Cloud plans