Skip to content

Commit

Permalink
Merge pull request #6 from soyking/dep/adjust-etcd
Browse files Browse the repository at this point in the history
dep: adjust etcd dependencies
  • Loading branch information
soyking authored Mar 6, 2022
2 parents 07f0894 + 501ef77 commit e090d8e
Show file tree
Hide file tree
Showing 15 changed files with 192 additions and 118 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ When listing/deleting a directory, e3ch will get key-value with the prefix. For
package main
import (
"go.etcd.io/etcd/clientv3"
clientv3 "go.etcd.io/etcd/client/v3"
"github.com/soyking/e3ch"
)
Expand Down
4 changes: 2 additions & 2 deletions auth.go
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,8 @@ package client
import (
"strings"

"go.etcd.io/etcd/auth/authpb"
"go.etcd.io/etcd/clientv3"
"go.etcd.io/etcd/api/v3/authpb"
clientv3 "go.etcd.io/etcd/client/v3"
)

func (clt *EtcdHRCHYClient) permPath(key string) (string, error) {
Expand Down
3 changes: 2 additions & 1 deletion auth_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,8 @@ package client

import (
"encoding/json"
"go.etcd.io/etcd/clientv3"

clientv3 "go.etcd.io/etcd/client/v3"
. "gopkg.in/check.v1"
)

Expand Down
7 changes: 4 additions & 3 deletions client.go
Original file line number Diff line number Diff line change
@@ -1,11 +1,12 @@
package client

import (
"context"
"errors"
"go.etcd.io/etcd/clientv3"
mvccpb "go.etcd.io/etcd/mvcc/mvccpb"
"golang.org/x/net/context"
"strings"

"go.etcd.io/etcd/api/v3/mvccpb"
clientv3 "go.etcd.io/etcd/client/v3"
)

const (
Expand Down
2 changes: 1 addition & 1 deletion client_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import (
"os"
"testing"

"go.etcd.io/etcd/clientv3"
clientv3 "go.etcd.io/etcd/client/v3"
. "gopkg.in/check.v1"
)

Expand Down
2 changes: 1 addition & 1 deletion create_test.go
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
package client

import (
"go.etcd.io/etcd/clientv3"
clientv3 "go.etcd.io/etcd/client/v3"
. "gopkg.in/check.v1"
)

Expand Down
2 changes: 1 addition & 1 deletion delete.go
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
package client

import (
"go.etcd.io/etcd/clientv3"
clientv3 "go.etcd.io/etcd/client/v3"
)

// list a directory
Expand Down
5 changes: 3 additions & 2 deletions delete_test.go
Original file line number Diff line number Diff line change
@@ -1,9 +1,10 @@
package client

import (
"go.etcd.io/etcd/clientv3"
. "gopkg.in/check.v1"
"strconv"

clientv3 "go.etcd.io/etcd/client/v3"
. "gopkg.in/check.v1"
)

const (
Expand Down
2 changes: 1 addition & 1 deletion get_test.go
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
package client

import (
"go.etcd.io/etcd/clientv3"
clientv3 "go.etcd.io/etcd/client/v3"
. "gopkg.in/check.v1"
)

Expand Down
4 changes: 2 additions & 2 deletions go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ module github.com/soyking/e3ch
go 1.14

require (
go.etcd.io/etcd v0.5.0-alpha.5.0.20200824191128-ae9734ed278b
golang.org/x/net v0.0.0-20190813141303-74dc4d7220e7
go.etcd.io/etcd/api/v3 v3.5.2
go.etcd.io/etcd/client/v3 v3.5.2
gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c
)
263 changes: 166 additions & 97 deletions go.sum

Large diffs are not rendered by default.

5 changes: 3 additions & 2 deletions list.go
Original file line number Diff line number Diff line change
@@ -1,9 +1,10 @@
package client

import (
"go.etcd.io/etcd/clientv3"
mvccpb "go.etcd.io/etcd/mvcc/mvccpb"
"strings"

"go.etcd.io/etcd/api/v3/mvccpb"
clientv3 "go.etcd.io/etcd/client/v3"
)

// list a directory
Expand Down
5 changes: 3 additions & 2 deletions list_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,10 @@ package client

import (
"encoding/json"
"go.etcd.io/etcd/clientv3"
. "gopkg.in/check.v1"
"strconv"

clientv3 "go.etcd.io/etcd/client/v3"
. "gopkg.in/check.v1"
)

const (
Expand Down
2 changes: 1 addition & 1 deletion put.go
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
package client

import (
"go.etcd.io/etcd/clientv3"
clientv3 "go.etcd.io/etcd/client/v3"
)

// set kv or directory
Expand Down
2 changes: 1 addition & 1 deletion put_test.go
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
package client

import (
"go.etcd.io/etcd/clientv3"
clientv3 "go.etcd.io/etcd/client/v3"
. "gopkg.in/check.v1"
)

Expand Down

0 comments on commit e090d8e

Please sign in to comment.