Skip to content

Commit

Permalink
go.mod,vendor,backend: update coreos/etcd dependency to v3.4.9
Browse files Browse the repository at this point in the history
etcd rewrote its import path from coreos/etcd to go.etcd.io/etcd/v3.
Changed the imports path in this commit.

This lets us remove the github.com/ugorji/go/codec dependency, which
was pinned to a fairly old version. The net change is a loss of 30,000
lines of code in the vendor directory. (I first noticed this problem
because the outdated go/codec dependency was causing a dependency
failure when I tried to put Terraform and another project in the same
vendor directory.)

One oddity is that the commit shows up in go.mod as 3.3.0 but is
actually after 3.4.9, there's some discussion of that (and how to
resolve it) here.
etcd-io/etcd#12068 (comment)
  • Loading branch information
kevinburke1 committed Sep 30, 2020
1 parent b0f5847 commit 66fca7c
Show file tree
Hide file tree
Showing 8 changed files with 81 additions and 81 deletions.
2 changes: 1 addition & 1 deletion backend/remote-state/etcdv2/backend.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,11 +6,11 @@ import (
"context"
"strings"

etcdapi "github.com/coreos/etcd/client"
"github.com/hashicorp/terraform/backend"
"github.com/hashicorp/terraform/helper/schema"
"github.com/hashicorp/terraform/states/remote"
"github.com/hashicorp/terraform/states/statemgr"
etcdapi "go.etcd.io/etcd/v3/client"
)

func New() backend.Backend {
Expand Down
2 changes: 1 addition & 1 deletion backend/remote-state/etcdv2/client.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@ import (
"crypto/md5"
"fmt"

etcdapi "github.com/coreos/etcd/client"
"github.com/hashicorp/terraform/states/remote"
etcdapi "go.etcd.io/etcd/v3/client"
)

// EtcdClient is a remote client that stores data in etcd.
Expand Down
4 changes: 2 additions & 2 deletions backend/remote-state/etcdv3/backend.go
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,10 @@ package etcd
import (
"context"

etcdv3 "github.com/coreos/etcd/clientv3"
"github.com/coreos/etcd/pkg/transport"
"github.com/hashicorp/terraform/backend"
"github.com/hashicorp/terraform/helper/schema"
etcdv3 "go.etcd.io/etcd/v3/clientv3"
"go.etcd.io/etcd/v3/pkg/transport"
)

const (
Expand Down
3 changes: 1 addition & 2 deletions backend/remote-state/etcdv3/backend_state.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,12 +6,11 @@ import (
"sort"
"strings"

etcdv3 "github.com/coreos/etcd/clientv3"

"github.com/hashicorp/terraform/backend"
"github.com/hashicorp/terraform/states"
"github.com/hashicorp/terraform/states/remote"
"github.com/hashicorp/terraform/states/statemgr"
etcdv3 "go.etcd.io/etcd/v3/clientv3"
)

func (b *Backend) Workspaces() ([]string, error) {
Expand Down
2 changes: 1 addition & 1 deletion backend/remote-state/etcdv3/backend_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,8 @@ import (
"testing"
"time"

etcdv3 "github.com/coreos/etcd/clientv3"
"github.com/hashicorp/terraform/backend"
etcdv3 "go.etcd.io/etcd/v3/clientv3"
)

var (
Expand Down
4 changes: 2 additions & 2 deletions backend/remote-state/etcdv3/client.go
Original file line number Diff line number Diff line change
Expand Up @@ -8,11 +8,11 @@ import (
"sync"
"time"

etcdv3 "github.com/coreos/etcd/clientv3"
etcdv3sync "github.com/coreos/etcd/clientv3/concurrency"
"github.com/hashicorp/go-multierror"
"github.com/hashicorp/terraform/states/remote"
"github.com/hashicorp/terraform/states/statemgr"
etcdv3 "go.etcd.io/etcd/v3/clientv3"
etcdv3sync "go.etcd.io/etcd/v3/clientv3/concurrency"
)

const (
Expand Down
19 changes: 1 addition & 18 deletions go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -23,21 +23,14 @@ require (
github.com/baiyubin/aliyun-sts-go-sdk v0.0.0-20180326062324-cfa1a18b161f // indirect
github.com/bgentry/speakeasy v0.1.0
github.com/bmatcuk/doublestar v1.1.5
github.com/boltdb/bolt v1.3.1 // indirect
github.com/chzyer/logex v1.1.10 // indirect
github.com/chzyer/readline v0.0.0-20180603132655-2972be24d48e
github.com/chzyer/test v0.0.0-20180213035817-a1ea475d72b1 // indirect
github.com/coreos/bbolt v1.3.0 // indirect
github.com/coreos/etcd v3.3.10+incompatible
github.com/coreos/go-semver v0.2.0 // indirect
github.com/coreos/go-systemd v0.0.0-20181012123002-c6f51f82210d // indirect
github.com/coreos/pkg v0.0.0-20180928190104-399ea9e2e55f // indirect
github.com/davecgh/go-spew v1.1.1
github.com/dylanmei/iso8601 v0.1.0 // indirect
github.com/dylanmei/winrmtest v0.0.0-20190225150635-99b7fe2fddf1
github.com/go-test/deep v1.0.3
github.com/gofrs/uuid v3.3.0+incompatible // indirect
github.com/golang/groupcache v0.0.0-20180513044358-24b0969c4cb7 // indirect
github.com/golang/mock v1.3.1
github.com/golang/protobuf v1.3.4
github.com/golang/snappy v0.0.0-20180518054509-2e65f85255db // indirect
Expand All @@ -47,9 +40,6 @@ require (
github.com/gophercloud/utils v0.0.0-20200423144003-7c72efc7435d
github.com/gopherjs/gopherjs v0.0.0-20181017120253-0766667cb4d1 // indirect
github.com/gorilla/websocket v1.4.0 // indirect
github.com/grpc-ecosystem/go-grpc-middleware v1.0.0 // indirect
github.com/grpc-ecosystem/go-grpc-prometheus v1.2.0 // indirect
github.com/grpc-ecosystem/grpc-gateway v1.8.5 // indirect
github.com/hashicorp/aws-sdk-go-base v0.6.0
github.com/hashicorp/consul v0.0.0-20171026175957-610f3c86a089
github.com/hashicorp/errwrap v1.0.0
Expand Down Expand Up @@ -78,7 +68,6 @@ require (
github.com/hashicorp/yamux v0.0.0-20181012175058-2f1d1f20f75d // indirect
github.com/imdario/mergo v0.3.9 // indirect
github.com/jmespath/go-jmespath v0.3.0
github.com/jonboulle/clockwork v0.1.0 // indirect
github.com/joyent/triton-go v0.0.0-20180313100802-d8f9c0314926
github.com/jtolds/gls v4.2.1+incompatible // indirect
github.com/kardianos/osext v0.0.0-20190222173326-2bc1f35cddc0
Expand Down Expand Up @@ -109,25 +98,19 @@ require (
github.com/pkg/browser v0.0.0-20180916011732-0a3d74bf9ce4
github.com/pkg/errors v0.9.1
github.com/posener/complete v1.2.1
github.com/prometheus/client_golang v0.9.3-0.20190127221311-3c4408c8b829 // indirect
github.com/sean-/seed v0.0.0-20170313163322-e2103e2c3529 // indirect
github.com/smartystreets/assertions v0.0.0-20180927180507-b2de0cb4f26d // indirect
github.com/smartystreets/goconvey v0.0.0-20180222194500-ef6db91d284a // indirect
github.com/soheilhy/cmux v0.1.4 // indirect
github.com/spf13/afero v1.2.2
github.com/tencentcloud/tencentcloud-sdk-go v3.0.82+incompatible
github.com/tencentyun/cos-go-sdk-v5 v0.0.0-20190808065407-f07404cefc8c
github.com/tmc/grpc-websocket-proxy v0.0.0-20171017195756-830351dc03c6 // indirect
github.com/tombuildsstuff/giovanni v0.12.0
github.com/ugorji/go v0.0.0-20180813092308-00b869d2f4a5 // indirect
github.com/xanzy/ssh-agent v0.2.1
github.com/xiang90/probing v0.0.0-20160813154853-07dd2e8dfe18 // indirect
github.com/xlab/treeprint v0.0.0-20161029104018-1d6e34225557
github.com/zclconf/go-cty v1.6.2-0.20200923201117-36785d4dc4ac
github.com/zclconf/go-cty-yaml v1.0.2
go.uber.org/atomic v1.3.2 // indirect
go.uber.org/multierr v1.1.0 // indirect
go.uber.org/zap v1.9.1 // indirect
go.etcd.io/etcd/v3 v3.3.0-rc.0.0.20200710174459-07461ecc8c03
golang.org/x/crypto v0.0.0-20200622213623-75b288015ac9
golang.org/x/mod v0.2.0
golang.org/x/net v0.0.0-20200602114024-627f9648deb9
Expand Down
Loading

0 comments on commit 66fca7c

Please sign in to comment.