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.
|
|
|
||
| backup.restore( | ||
| tableId, | ||
| backup.restoreTo( |
There was a problem hiding this comment.
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.
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.
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.instancevalue forconfig.instance.Instance#createTableFromBackup()now respects bothBackupobject created on a different instance.stringof full backup name (path) that contains a different (formthis.id) instanceId.Other design options
!Breaking:
Backup#restore()with the proposedBackup#restoreTo()implementationNon Breaking:
instanceparameter toBackup#restore()