-
Notifications
You must be signed in to change notification settings - Fork 59
New issue
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
feat: implement restore table to a different instance feature #830
feat: implement restore table to a different instance feature #830
Conversation
Codecov Report
@@ Coverage Diff @@
## backup-different-instance #830 +/- ##
==========================================================
Coverage 99.22% 99.22%
==========================================================
Files 18 18
Lines 17416 17488 +72
Branches 1025 1033 +8
==========================================================
+ Hits 17281 17353 +72
Misses 132 132
Partials 3 3
Continue to review full report at Codecov.
|
@AVaksman is there any additional context for the reasoning of this addition? |
Hey @stephenplusplus! We will be working on this in all languages, here's the Java draft for reference: googleapis/java-bigtable#515 |
@kolea2 thank you! |
Here is the summary of changes. You added 1 region tag.
You deleted 1 region tag.
This comment is generated by snippet-bot.
|
@@ -474,8 +577,8 @@ describe('Bigtable/Backup', () => { | |||
callback(null, ...args); | |||
}; | |||
|
|||
backup.restore( | |||
tableId, | |||
backup.restoreTo( |
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.
I think we may want to leave some of these tests as is, so we don't lose coverage on .restore()
functionality?
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.
To have gRPC call implementation only in one place Backup#restore()
(as more restrictive wrapper since can only restore to the same instance) delegates to Backup#restoreTo()
and passing this.cluster.instance
value as the config.instance
param.
The current unit tests for Backup#restore()
are to verify that it properly delegates to Backup#restoreTo()
with and without optional gaxOptions
param.
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.
got it, just want to confirm we still have at least one restore
test in place for coverage?
Looking good, merging into |
#ToDo
Backup#restoreTo()
Instance#createTableFromBackup()
This PR proposes the following design
Backup#restoreTo(config, callback?)
which accepts a config parameter of the typeBackup#restore()
delegates toBackup#restoreTo()
withthis.cluster.instance
value forconfig.instance
.Instance#createTableFromBackup()
now respects bothBackup
object created on a different instance.string
of full backup name (path) that contains a different (formthis.id
) instanceId.Other design options
!Breaking:
Backup#restore()
with the proposedBackup#restoreTo()
implementationNon Breaking:
instance
parameter toBackup#restore()