Skip to content
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

CLOUDP-69270:Backup: atlas snapshots create #358

Merged
merged 6 commits into from
Aug 13, 2020
Merged

Conversation

andreaangiolillo
Copy link
Collaborator

@andreaangiolillo andreaangiolillo commented Aug 13, 2020

Proposed changes

Jira ticket: CLOUDP-69270

Checklist

  • I have signed the MongoDB CLA
  • I have added tests that prove my fix is effective or that my feature works
  • I have added any necessary documentation (if appropriate)
  • I have run make fmt and formatted my code

Further comments

./bin/mongocli atlas backups snapshots create Cluster1 --desc test2 --retention 3
Snapshot '5f35178eb21554136479ff0c' created.

./bin/mongocli atlas backups snapshots create Cluster0 --desc test
Snapshot '5f3516d0c600162315976f7c' created.
./bin/mongocli atlas backups snapshots create Cluster0 --desc test2 --retention 3 -o "json"
{
  "id": "5f35185dc60016231597711d",
  "createdAt": "2020-08-13T10:39:25Z",
  "expiresAt": "2020-08-16T10:39:25Z",
  "description": "test2",
  "links": [
    {
      "rel": "self",
      "href": "https://cloud-dev.mongodb.com/api/atlas/v1.0/groups/5e4e593f70dfbf1010295836/clusters/Cluster0/backup/snapshots/5f35185dc60016231597711d"
    },
    {
      "rel": "http://mms.mongodb.com/cluster",
      "href": "https://cloud-dev.mongodb.com/api/atlas/v1.0/groups/5e4e593f70dfbf1010295836/clusters/Cluster0"
    }
  ],
  "mongodVersion": "4.2.8",
  "snapshotType": "onDemand",
  "status": "queued",
  "type": "replicaSet"
}

Copy link
Collaborator

@gssbzn gssbzn left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Left a couple of small comments, nothing major, this looks great

func CreateBuilder() *cobra.Command {
opts := &CreateOpts{}
cmd := &cobra.Command{
Use: "create",
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[nit] can we add "take" as an alias to match the GUI?

}
}

// ContinuousSnapshots encapsulates the logic to manage different cloud providers
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
// ContinuousSnapshots encapsulates the logic to manage different cloud providers
// Snapshots encapsulates the logic to manage different cloud providers

// See the License for the specific language governing permissions and
// limitations under the License.

package snapshots
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍

Copy link
Collaborator

@gssbzn gssbzn left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@andreaangiolillo andreaangiolillo merged commit 9ef76be into master Aug 13, 2020
@andreaangiolillo andreaangiolillo deleted the CLOUDP-69270 branch August 13, 2020 14:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants