kubernetes-retired / etcdadm

[EOL] etcdadm is a command-line tool for operating an etcd cluster
Apache License 2.0
765 stars 135 forks source link

Use EtcdVersionForRestore in backuprestore test #313

Closed hakman closed 2 years ago

hakman commented 2 years ago

This makes the test similar to what etcd-manager does during the restore operation: https://github.com/kubernetes-sigs/etcdadm/blob/f9a20374ca1abc9a6083e6db21aeaa32e2560504/etcd-manager/pkg/etcd/restore.go#L125-L133

cluster.go:67] Starting new testharness for "TestBackupRestore/backupEtcdVersion=3.5.0/restoreEtcdVersion=3.5.4" in /tmp/1003361396
backuprestore_test.go:51] Starting backup node 127.0.0.1 with etcd version "3.5.0"
backuprestore_test.go:59] Writing key "/testing/backuprestore_3.5.0"="world-3.5.0" to backup node
backuprestore_test.go:65] Reading key "/testing/backuprestore_3.5.0" from backup node
backuprestore_test.go:74] Found key "/testing/backuprestore_3.5.0" with value "world-3.5.0" in backup
backuprestore_test.go:77] Waiting for backup
backuprestore_test.go:81] Stopping backup node 127.0.0.1
backuprestore_test.go:85] Removing backup node directory "/tmp/1003361396/testharnesscluster/nodes/127.0.0.1"
cluster.go:67] Starting new testharness for "TestBackupRestore/backupEtcdVersion=3.5.0/restoreEtcdVersion=3.5.4" in /tmp/1340905303
backuprestore_test.go:112] Adding command to restore backup "2022-05-01T09:22:49Z-000026"
backuprestore_test.go:124] Starting restore node 127.0.0.2 with etcd version "3.5.4"
backuprestore_test.go:129] Reading key "/testing/backuprestore_3.5.0" from restore node
backuprestore_test.go:138] Found key "/testing/backuprestore_3.5.0" with value "world-3.5.0" in backup
backuprestore_test.go:141] Stopping restore node 127.0.0.2

cluster.go:67] Starting new testharness for "TestBackupRestore/backupEtcdVersion=3.5.1/restoreEtcdVersion=3.5.4" in /tmp/2940031322
backuprestore_test.go:51] Starting backup node 127.0.0.1 with etcd version "3.5.1"
backuprestore_test.go:59] Writing key "/testing/backuprestore_3.5.1"="world-3.5.1" to backup node
backuprestore_test.go:65] Reading key "/testing/backuprestore_3.5.1" from backup node
backuprestore_test.go:74] Found key "/testing/backuprestore_3.5.1" with value "world-3.5.1" in backup
backuprestore_test.go:77] Waiting for backup
backuprestore_test.go:81] Stopping backup node 127.0.0.1
backuprestore_test.go:85] Removing backup node directory "/tmp/2940031322/testharnesscluster/nodes/127.0.0.1"
cluster.go:67] Starting new testharness for "TestBackupRestore/backupEtcdVersion=3.5.1/restoreEtcdVersion=3.5.4" in /tmp/3288148461
backuprestore_test.go:112] Adding command to restore backup "2022-05-01T09:23:13Z-000029"
backuprestore_test.go:124] Starting restore node 127.0.0.2 with etcd version "3.5.4"
backuprestore_test.go:129] Reading key "/testing/backuprestore_3.5.1" from restore node
backuprestore_test.go:138] Found key "/testing/backuprestore_3.5.1" with value "world-3.5.1" in backup
backuprestore_test.go:141] Stopping restore node 127.0.0.2

cluster.go:67] Starting new testharness for "TestBackupRestore/backupEtcdVersion=3.5.3/restoreEtcdVersion=3.5.4" in /tmp/4277173945
backuprestore_test.go:51] Starting backup node 127.0.0.1 with etcd version "3.5.3"
backuprestore_test.go:59] Writing key "/testing/backuprestore_3.5.3"="world-3.5.3" to backup node
backuprestore_test.go:65] Reading key "/testing/backuprestore_3.5.3" from backup node
backuprestore_test.go:74] Found key "/testing/backuprestore_3.5.3" with value "world-3.5.3" in backup
backuprestore_test.go:77] Waiting for backup
backuprestore_test.go:81] Stopping backup node 127.0.0.1
backuprestore_test.go:85] Removing backup node directory "/tmp/4277173945/testharnesscluster/nodes/127.0.0.1"
cluster.go:67] Starting new testharness for "TestBackupRestore/backupEtcdVersion=3.5.3/restoreEtcdVersion=3.5.4" in /tmp/2991766112
backuprestore_test.go:112] Adding command to restore backup "2022-05-01T09:23:36Z-000032"
backuprestore_test.go:124] Starting restore node 127.0.0.2 with etcd version "3.5.4"
backuprestore_test.go:129] Reading key "/testing/backuprestore_3.5.3" from restore node
backuprestore_test.go:138] Found key "/testing/backuprestore_3.5.3" with value "world-3.5.3" in backup
backuprestore_test.go:141] Stopping restore node 127.0.0.2

cluster.go:67] Starting new testharness for "TestBackupRestore/backupEtcdVersion=3.5.4/restoreEtcdVersion=3.5.4" in /tmp/487675563
backuprestore_test.go:51] Starting backup node 127.0.0.1 with etcd version "3.5.4"
backuprestore_test.go:59] Writing key "/testing/backuprestore_3.5.4"="world-3.5.4" to backup node
backuprestore_test.go:65] Reading key "/testing/backuprestore_3.5.4" from backup node
backuprestore_test.go:74] Found key "/testing/backuprestore_3.5.4" with value "world-3.5.4" in backup
backuprestore_test.go:77] Waiting for backup
backuprestore_test.go:81] Stopping backup node 127.0.0.1
backuprestore_test.go:85] Removing backup node directory "/tmp/487675563/testharnesscluster/nodes/127.0.0.1"
cluster.go:67] Starting new testharness for "TestBackupRestore/backupEtcdVersion=3.5.4/restoreEtcdVersion=3.5.4" in /tmp/2252333096
backuprestore_test.go:112] Adding command to restore backup "2022-05-01T09:24:03Z-000035"
backuprestore_test.go:124] Starting restore node 127.0.0.2 with etcd version "3.5.4"
backuprestore_test.go:129] Reading key "/testing/backuprestore_3.5.4" from restore node
backuprestore_test.go:138] Found key "/testing/backuprestore_3.5.4" with value "world-3.5.4" in backup
backuprestore_test.go:141] Stopping restore node 127.0.0.2
hakman commented 2 years ago

/cc @rifelpet

k8s-ci-robot commented 2 years ago

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: hakman, rifelpet

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files: - ~~[etcd-manager/OWNERS](https://github.com/kubernetes-sigs/etcdadm/blob/master/etcd-manager/OWNERS)~~ [hakman,rifelpet] Approvers can indicate their approval by writing `/approve` in a comment Approvers can cancel approval by writing `/approve cancel` in a comment