Merge pull request #11823 from philips/v3-mod-attempt2

go.mod: name packages with go.etcd.io/etcd/v3
This commit is contained in:
Brandon Philips 2020-04-28 15:24:29 -07:00 committed by GitHub
commit b28a6272b7
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
571 changed files with 1474 additions and 1461 deletions

View File

@ -1,5 +1,5 @@
language: go
go_import_path: go.etcd.io/etcd
go_import_path: go.etcd.io/etcd/v3
sudo: required

View File

@ -21,6 +21,7 @@ See [code changes](https://github.com/etcd-io/etcd/compare/v3.4.0...v3.5.0) and
### Breaking Changes
- `go.etcd.io/etcd` Go packages have moved to `go.etcd.io/etcd/v3` to follow the [Go modules](https://github.com/golang/go/wiki/Modules) conventions
- Changed behavior of clienv3 API [MemberList](https://github.com/etcd-io/etcd/pull/11639).
- Previously, it is directly served with server's local data, which could be stale.
- Now, it is served with linearizable guarantee. If the server is disconnected from quorum, `MemberList` call will fail.

View File

@ -10,8 +10,8 @@ The etcd client provides a gRPC resolver for resolving gRPC endpoints with an et
```go
import (
"go.etcd.io/etcd/clientv3"
etcdnaming "go.etcd.io/etcd/clientv3/naming"
"go.etcd.io/etcd/v3/clientv3"
etcdnaming "go.etcd.io/etcd/v3/clientv3/naming"
"google.golang.org/grpc"
)

View File

@ -28,8 +28,8 @@ To build a vendored `etcd` from the `master` branch via `go get`:
# GOPATH should be set
$ echo $GOPATH
/Users/example/go
$ go get -v go.etcd.io/etcd
$ go get -v go.etcd.io/etcd/etcdctl
$ go get -v go.etcd.io/etcd/v3
$ go get -v go.etcd.io/etcd/v3/etcdctl
```
## Test the installation

View File

@ -26,8 +26,8 @@ import (
"bytes"
"encoding/json"
"fmt"
"go.etcd.io/etcd/clientv3"
"go.etcd.io/etcd/clientv3/concurrency"
"go.etcd.io/etcd/v3/clientv3"
"go.etcd.io/etcd/v3/clientv3/concurrency"
"io/ioutil"
"net/http"
"os"

View File

@ -15,9 +15,9 @@
package auth
import (
"go.etcd.io/etcd/auth/authpb"
"go.etcd.io/etcd/mvcc/backend"
"go.etcd.io/etcd/pkg/adt"
"go.etcd.io/etcd/v3/auth/authpb"
"go.etcd.io/etcd/v3/mvcc/backend"
"go.etcd.io/etcd/v3/pkg/adt"
"go.uber.org/zap"
)

View File

@ -17,8 +17,8 @@ package auth
import (
"testing"
"go.etcd.io/etcd/auth/authpb"
"go.etcd.io/etcd/pkg/adt"
"go.etcd.io/etcd/v3/auth/authpb"
"go.etcd.io/etcd/v3/pkg/adt"
"go.uber.org/zap"
)

View File

@ -24,11 +24,11 @@ import (
"sync"
"sync/atomic"
"go.etcd.io/etcd/auth/authpb"
"go.etcd.io/etcd/etcdserver/api/v3rpc/rpctypes"
"go.etcd.io/etcd/etcdserver/cindex"
pb "go.etcd.io/etcd/etcdserver/etcdserverpb"
"go.etcd.io/etcd/mvcc/backend"
"go.etcd.io/etcd/v3/auth/authpb"
"go.etcd.io/etcd/v3/etcdserver/api/v3rpc/rpctypes"
"go.etcd.io/etcd/v3/etcdserver/cindex"
pb "go.etcd.io/etcd/v3/etcdserver/etcdserverpb"
"go.etcd.io/etcd/v3/mvcc/backend"
"go.uber.org/zap"
"golang.org/x/crypto/bcrypt"

View File

@ -24,10 +24,10 @@ import (
"testing"
"time"
"go.etcd.io/etcd/auth/authpb"
"go.etcd.io/etcd/etcdserver/api/v3rpc/rpctypes"
pb "go.etcd.io/etcd/etcdserver/etcdserverpb"
"go.etcd.io/etcd/mvcc/backend"
"go.etcd.io/etcd/v3/auth/authpb"
"go.etcd.io/etcd/v3/etcdserver/api/v3rpc/rpctypes"
pb "go.etcd.io/etcd/v3/etcdserver/etcdserverpb"
"go.etcd.io/etcd/v3/mvcc/backend"
"go.uber.org/zap"
"golang.org/x/crypto/bcrypt"

View File

@ -315,7 +315,7 @@
]
},
{
"project": "go.etcd.io/etcd",
"project": "go.etcd.io/etcd/v3",
"licenses": [
{
"type": "Apache License 2.0",

2
build
View File

@ -2,7 +2,7 @@
# set some environment variables
ORG_PATH="go.etcd.io"
REPO_PATH="${ORG_PATH}/etcd"
REPO_PATH="${ORG_PATH}/etcd/v3"
GIT_SHA=$(git rev-parse --short HEAD || echo "GitNotFound")
if [[ -n "$FAILPOINTS" ]]; then

View File

@ -9,7 +9,7 @@ For full compatibility, it is recommended to vendor builds using etcd's vendored
## Install
```bash
go get go.etcd.io/etcd/client
go get go.etcd.io/etcd/v3/client
```
## Usage
@ -22,7 +22,7 @@ import (
"time"
"context"
"go.etcd.io/etcd/client"
"go.etcd.io/etcd/v3/client"
)
func main() {

View File

@ -29,7 +29,7 @@ import (
"sync"
"time"
"go.etcd.io/etcd/version"
"go.etcd.io/etcd/v3/version"
)
var (

View File

@ -29,8 +29,8 @@ import (
"testing"
"time"
"go.etcd.io/etcd/pkg/testutil"
"go.etcd.io/etcd/version"
"go.etcd.io/etcd/v3/pkg/testutil"
"go.etcd.io/etcd/v3/version"
)
type actionAssertingHTTPClient struct {

View File

@ -15,7 +15,7 @@
package client
import (
"go.etcd.io/etcd/pkg/srv"
"go.etcd.io/etcd/v3/pkg/srv"
)
// Discoverer is an interface that wraps the Discover method.

View File

@ -21,7 +21,7 @@ Create a Config and exchange it for a Client:
"net/http"
"context"
"go.etcd.io/etcd/client"
"go.etcd.io/etcd/v3/client"
)
cfg := client.Config{

View File

@ -20,7 +20,7 @@ import (
"log"
"sort"
"go.etcd.io/etcd/client"
"go.etcd.io/etcd/v3/client"
)
func ExampleKeysAPI_directory() {

View File

@ -24,9 +24,9 @@ import (
"sync/atomic"
"testing"
"go.etcd.io/etcd/client"
"go.etcd.io/etcd/integration"
"go.etcd.io/etcd/pkg/testutil"
"go.etcd.io/etcd/v3/client"
"go.etcd.io/etcd/v3/integration"
"go.etcd.io/etcd/v3/pkg/testutil"
)
// TestV2NoRetryEOF tests destructive api calls won't retry on a disconnection.

View File

@ -8,7 +8,7 @@ import (
"os"
"testing"
"go.etcd.io/etcd/pkg/testutil"
"go.etcd.io/etcd/v3/pkg/testutil"
)
func TestMain(m *testing.M) {

View File

@ -19,7 +19,7 @@ import (
"encoding/json"
"errors"
"fmt"
"go.etcd.io/etcd/pkg/pathutil"
"go.etcd.io/etcd/v3/pkg/pathutil"
"net/http"
"net/url"
"strconv"

View File

@ -23,9 +23,9 @@ import (
"testing"
"time"
"go.etcd.io/etcd/integration"
"go.etcd.io/etcd/pkg/testutil"
"go.etcd.io/etcd/pkg/transport"
"go.etcd.io/etcd/v3/integration"
"go.etcd.io/etcd/v3/pkg/testutil"
"go.etcd.io/etcd/v3/pkg/transport"
)
var exampleEndpoints []string

View File

@ -23,7 +23,7 @@ import (
"net/url"
"path"
"go.etcd.io/etcd/pkg/types"
"go.etcd.io/etcd/v3/pkg/types"
)
var (

View File

@ -23,7 +23,7 @@ import (
"reflect"
"testing"
"go.etcd.io/etcd/pkg/types"
"go.etcd.io/etcd/v3/pkg/types"
)
func TestMembersAPIActionList(t *testing.T) {

View File

@ -19,8 +19,8 @@ import (
"fmt"
"strings"
"go.etcd.io/etcd/auth/authpb"
pb "go.etcd.io/etcd/etcdserver/etcdserverpb"
"go.etcd.io/etcd/v3/auth/authpb"
pb "go.etcd.io/etcd/v3/etcdserver/etcdserverpb"
"google.golang.org/grpc"
)

View File

@ -20,8 +20,8 @@ import (
"sync"
"time"
"go.etcd.io/etcd/clientv3/balancer/connectivity"
"go.etcd.io/etcd/clientv3/balancer/picker"
"go.etcd.io/etcd/v3/clientv3/balancer/connectivity"
"go.etcd.io/etcd/v3/clientv3/balancer/picker"
"go.uber.org/zap"
"google.golang.org/grpc/balancer"

View File

@ -21,10 +21,10 @@ import (
"testing"
"time"
"go.etcd.io/etcd/clientv3/balancer/picker"
"go.etcd.io/etcd/clientv3/balancer/resolver/endpoint"
pb "go.etcd.io/etcd/etcdserver/etcdserverpb"
"go.etcd.io/etcd/pkg/mock/mockserver"
"go.etcd.io/etcd/v3/clientv3/balancer/picker"
"go.etcd.io/etcd/v3/clientv3/balancer/resolver/endpoint"
pb "go.etcd.io/etcd/v3/etcdserver/etcdserverpb"
"go.etcd.io/etcd/v3/pkg/mock/mockserver"
"go.uber.org/zap"
"google.golang.org/grpc"

View File

@ -26,12 +26,12 @@ import (
"time"
"github.com/google/uuid"
"go.etcd.io/etcd/clientv3/balancer"
"go.etcd.io/etcd/clientv3/balancer/picker"
"go.etcd.io/etcd/clientv3/balancer/resolver/endpoint"
"go.etcd.io/etcd/clientv3/credentials"
"go.etcd.io/etcd/etcdserver/api/v3rpc/rpctypes"
"go.etcd.io/etcd/pkg/logutil"
"go.etcd.io/etcd/v3/clientv3/balancer"
"go.etcd.io/etcd/v3/clientv3/balancer/picker"
"go.etcd.io/etcd/v3/clientv3/balancer/resolver/endpoint"
"go.etcd.io/etcd/v3/clientv3/credentials"
"go.etcd.io/etcd/v3/etcdserver/api/v3rpc/rpctypes"
"go.etcd.io/etcd/v3/pkg/logutil"
"go.uber.org/zap"
"google.golang.org/grpc"
"google.golang.org/grpc/codes"

View File

@ -21,8 +21,8 @@ import (
"testing"
"time"
"go.etcd.io/etcd/etcdserver/api/v3rpc/rpctypes"
"go.etcd.io/etcd/pkg/testutil"
"go.etcd.io/etcd/v3/etcdserver/api/v3rpc/rpctypes"
"go.etcd.io/etcd/v3/pkg/testutil"
"google.golang.org/grpc"
)

View File

@ -18,8 +18,8 @@ import (
"context"
"log"
"go.etcd.io/etcd/clientv3"
"go.etcd.io/etcd/clientv3/clientv3util"
"go.etcd.io/etcd/v3/clientv3"
"go.etcd.io/etcd/v3/clientv3/clientv3util"
)
func ExampleKeyMissing() {

View File

@ -16,7 +16,7 @@
package clientv3util
import (
"go.etcd.io/etcd/clientv3"
"go.etcd.io/etcd/v3/clientv3"
)
// KeyExists returns a comparison operation that evaluates to true iff the given

View File

@ -17,8 +17,8 @@ package clientv3
import (
"context"
pb "go.etcd.io/etcd/etcdserver/etcdserverpb"
"go.etcd.io/etcd/pkg/types"
pb "go.etcd.io/etcd/v3/etcdserver/etcdserverpb"
"go.etcd.io/etcd/v3/pkg/types"
"google.golang.org/grpc"
)

View File

@ -15,7 +15,7 @@
package clientv3
import (
pb "go.etcd.io/etcd/etcdserver/etcdserverpb"
pb "go.etcd.io/etcd/v3/etcdserver/etcdserverpb"
)
// CompactOp represents a compact operation.

View File

@ -18,7 +18,7 @@ import (
"reflect"
"testing"
"go.etcd.io/etcd/etcdserver/etcdserverpb"
"go.etcd.io/etcd/v3/etcdserver/etcdserverpb"
)
func TestCompactOp(t *testing.T) {

View File

@ -15,7 +15,7 @@
package clientv3
import (
pb "go.etcd.io/etcd/etcdserver/etcdserverpb"
pb "go.etcd.io/etcd/v3/etcdserver/etcdserverpb"
)
type CompareTarget int

View File

@ -19,9 +19,9 @@ import (
"errors"
"fmt"
v3 "go.etcd.io/etcd/clientv3"
pb "go.etcd.io/etcd/etcdserver/etcdserverpb"
"go.etcd.io/etcd/mvcc/mvccpb"
v3 "go.etcd.io/etcd/v3/clientv3"
pb "go.etcd.io/etcd/v3/etcdserver/etcdserverpb"
"go.etcd.io/etcd/v3/mvcc/mvccpb"
)
var (

View File

@ -21,8 +21,8 @@ import (
"testing"
"time"
"go.etcd.io/etcd/clientv3"
"go.etcd.io/etcd/clientv3/concurrency"
"go.etcd.io/etcd/v3/clientv3"
"go.etcd.io/etcd/v3/clientv3/concurrency"
)
func TestResumeElection(t *testing.T) {

View File

@ -21,8 +21,8 @@ import (
"sync"
"time"
"go.etcd.io/etcd/clientv3"
"go.etcd.io/etcd/clientv3/concurrency"
"go.etcd.io/etcd/v3/clientv3"
"go.etcd.io/etcd/v3/clientv3/concurrency"
)
func ExampleElection_Campaign() {

View File

@ -19,8 +19,8 @@ import (
"fmt"
"log"
"go.etcd.io/etcd/clientv3"
"go.etcd.io/etcd/clientv3/concurrency"
"go.etcd.io/etcd/v3/clientv3"
"go.etcd.io/etcd/v3/clientv3/concurrency"
)
func ExampleMutex_TryLock() {

View File

@ -21,8 +21,8 @@ import (
"math/rand"
"sync"
"go.etcd.io/etcd/clientv3"
"go.etcd.io/etcd/clientv3/concurrency"
"go.etcd.io/etcd/v3/clientv3"
"go.etcd.io/etcd/v3/clientv3/concurrency"
)
// ExampleSTM_apply shows how to use STM with a transactional

View File

@ -18,9 +18,9 @@ import (
"context"
"fmt"
v3 "go.etcd.io/etcd/clientv3"
pb "go.etcd.io/etcd/etcdserver/etcdserverpb"
"go.etcd.io/etcd/mvcc/mvccpb"
v3 "go.etcd.io/etcd/v3/clientv3"
pb "go.etcd.io/etcd/v3/etcdserver/etcdserverpb"
"go.etcd.io/etcd/v3/mvcc/mvccpb"
)
func waitDelete(ctx context.Context, client *v3.Client, key string, rev int64) error {

View File

@ -20,8 +20,8 @@ import (
"testing"
"time"
"go.etcd.io/etcd/integration"
"go.etcd.io/etcd/pkg/testutil"
"go.etcd.io/etcd/v3/integration"
"go.etcd.io/etcd/v3/pkg/testutil"
)
var endpoints []string

View File

@ -20,8 +20,8 @@ import (
"fmt"
"sync"
v3 "go.etcd.io/etcd/clientv3"
pb "go.etcd.io/etcd/etcdserver/etcdserverpb"
v3 "go.etcd.io/etcd/v3/clientv3"
pb "go.etcd.io/etcd/v3/etcdserver/etcdserverpb"
)
// ErrLocked is returned by TryLock when Mutex is already locked by another session.

View File

@ -18,8 +18,8 @@ import (
"context"
"testing"
"go.etcd.io/etcd/clientv3"
"go.etcd.io/etcd/clientv3/concurrency"
"go.etcd.io/etcd/v3/clientv3"
"go.etcd.io/etcd/v3/clientv3/concurrency"
)
func TestMutexLockSessionExpired(t *testing.T) {

View File

@ -18,7 +18,7 @@ import (
"context"
"time"
v3 "go.etcd.io/etcd/clientv3"
v3 "go.etcd.io/etcd/v3/clientv3"
)
const defaultSessionTTL = 60

View File

@ -18,7 +18,7 @@ import (
"context"
"math"
v3 "go.etcd.io/etcd/clientv3"
v3 "go.etcd.io/etcd/v3/clientv3"
)
// STM is an interface for software transactional memory.

View File

@ -22,7 +22,7 @@ import (
"net"
"sync"
"go.etcd.io/etcd/etcdserver/api/v3rpc/rpctypes"
"go.etcd.io/etcd/v3/etcdserver/api/v3rpc/rpctypes"
grpccredentials "google.golang.org/grpc/credentials"
)

View File

@ -17,8 +17,8 @@ package clientv3
import (
"context"
"go.etcd.io/etcd/etcdserver/api/v3rpc/rpctypes"
"go.etcd.io/etcd/version"
"go.etcd.io/etcd/v3/etcdserver/api/v3rpc/rpctypes"
"go.etcd.io/etcd/v3/version"
"google.golang.org/grpc/metadata"
)

View File

@ -19,8 +19,8 @@ import (
"reflect"
"testing"
"go.etcd.io/etcd/etcdserver/api/v3rpc/rpctypes"
"go.etcd.io/etcd/version"
"go.etcd.io/etcd/v3/etcdserver/api/v3rpc/rpctypes"
"go.etcd.io/etcd/v3/version"
"google.golang.org/grpc/metadata"
)

View File

@ -19,7 +19,7 @@ import (
"fmt"
"log"
"go.etcd.io/etcd/clientv3"
"go.etcd.io/etcd/v3/clientv3"
)
func ExampleAuth() {

View File

@ -19,7 +19,7 @@ import (
"fmt"
"log"
"go.etcd.io/etcd/clientv3"
"go.etcd.io/etcd/v3/clientv3"
)
func ExampleCluster_memberList() {

View File

@ -19,8 +19,8 @@ import (
"fmt"
"log"
"go.etcd.io/etcd/clientv3"
"go.etcd.io/etcd/etcdserver/api/v3rpc/rpctypes"
"go.etcd.io/etcd/v3/clientv3"
"go.etcd.io/etcd/v3/etcdserver/api/v3rpc/rpctypes"
)
func ExampleKV_put() {

View File

@ -19,7 +19,7 @@ import (
"fmt"
"log"
"go.etcd.io/etcd/clientv3"
"go.etcd.io/etcd/v3/clientv3"
)
func ExampleLease_grant() {

View File

@ -19,7 +19,7 @@ import (
"fmt"
"log"
"go.etcd.io/etcd/clientv3"
"go.etcd.io/etcd/v3/clientv3"
)
func ExampleMaintenance_status() {

View File

@ -23,7 +23,7 @@ import (
"net/http"
"strings"
"go.etcd.io/etcd/clientv3"
"go.etcd.io/etcd/v3/clientv3"
grpcprom "github.com/grpc-ecosystem/go-grpc-prometheus"
"github.com/prometheus/client_golang/prometheus/promhttp"

View File

@ -20,8 +20,8 @@ import (
"os"
"time"
"go.etcd.io/etcd/clientv3"
"go.etcd.io/etcd/pkg/transport"
"go.etcd.io/etcd/v3/clientv3"
"go.etcd.io/etcd/v3/pkg/transport"
"google.golang.org/grpc/grpclog"
)

View File

@ -19,7 +19,7 @@ import (
"fmt"
"log"
"go.etcd.io/etcd/clientv3"
"go.etcd.io/etcd/v3/clientv3"
)
func ExampleWatcher_watch() {

View File

@ -21,10 +21,10 @@ import (
"testing"
"time"
"go.etcd.io/etcd/clientv3"
"go.etcd.io/etcd/etcdserver/api/v3rpc/rpctypes"
"go.etcd.io/etcd/integration"
"go.etcd.io/etcd/pkg/testutil"
"go.etcd.io/etcd/v3/clientv3"
"go.etcd.io/etcd/v3/etcdserver/api/v3rpc/rpctypes"
"go.etcd.io/etcd/v3/integration"
"go.etcd.io/etcd/v3/pkg/testutil"
"google.golang.org/grpc"
)

View File

@ -22,9 +22,9 @@ import (
"testing"
"time"
"go.etcd.io/etcd/integration"
"go.etcd.io/etcd/pkg/testutil"
"go.etcd.io/etcd/pkg/types"
"go.etcd.io/etcd/v3/integration"
"go.etcd.io/etcd/v3/pkg/testutil"
"go.etcd.io/etcd/v3/pkg/types"
)
func TestMemberList(t *testing.T) {

View File

@ -21,11 +21,11 @@ import (
"testing"
"time"
"go.etcd.io/etcd/clientv3"
pb "go.etcd.io/etcd/etcdserver/etcdserverpb"
"go.etcd.io/etcd/integration"
"go.etcd.io/etcd/pkg/testutil"
"go.etcd.io/etcd/pkg/transport"
"go.etcd.io/etcd/v3/clientv3"
pb "go.etcd.io/etcd/v3/etcdserver/etcdserverpb"
"go.etcd.io/etcd/v3/integration"
"go.etcd.io/etcd/v3/pkg/testutil"
"go.etcd.io/etcd/v3/pkg/transport"
"google.golang.org/grpc"
)

View File

@ -25,12 +25,12 @@ import (
"testing"
"time"
"go.etcd.io/etcd/clientv3"
"go.etcd.io/etcd/etcdserver/api/v3rpc/rpctypes"
"go.etcd.io/etcd/integration"
"go.etcd.io/etcd/mvcc/mvccpb"
"go.etcd.io/etcd/pkg/testutil"
"go.etcd.io/etcd/version"
"go.etcd.io/etcd/v3/clientv3"
"go.etcd.io/etcd/v3/etcdserver/api/v3rpc/rpctypes"
"go.etcd.io/etcd/v3/integration"
"go.etcd.io/etcd/v3/mvcc/mvccpb"
"go.etcd.io/etcd/v3/pkg/testutil"
"go.etcd.io/etcd/v3/version"
"google.golang.org/grpc"
"google.golang.org/grpc/codes"

View File

@ -23,11 +23,11 @@ import (
"testing"
"time"
"go.etcd.io/etcd/clientv3"
"go.etcd.io/etcd/clientv3/concurrency"
"go.etcd.io/etcd/etcdserver/api/v3rpc/rpctypes"
"go.etcd.io/etcd/integration"
"go.etcd.io/etcd/pkg/testutil"
"go.etcd.io/etcd/v3/clientv3"
"go.etcd.io/etcd/v3/clientv3/concurrency"
"go.etcd.io/etcd/v3/etcdserver/api/v3rpc/rpctypes"
"go.etcd.io/etcd/v3/integration"
"go.etcd.io/etcd/v3/pkg/testutil"
)
func TestLeaseNotFoundError(t *testing.T) {

View File

@ -23,11 +23,11 @@ import (
"testing"
"time"
"go.etcd.io/etcd/clientv3"
"go.etcd.io/etcd/clientv3/concurrency"
"go.etcd.io/etcd/clientv3/leasing"
"go.etcd.io/etcd/integration"
"go.etcd.io/etcd/pkg/testutil"
"go.etcd.io/etcd/v3/clientv3"
"go.etcd.io/etcd/v3/clientv3/concurrency"
"go.etcd.io/etcd/v3/clientv3/leasing"
"go.etcd.io/etcd/v3/integration"
"go.etcd.io/etcd/v3/pkg/testutil"
)
func TestLeasingPutGet(t *testing.T) {

View File

@ -17,7 +17,7 @@ package integration
import (
"io/ioutil"
"go.etcd.io/etcd/clientv3"
"go.etcd.io/etcd/v3/clientv3"
"google.golang.org/grpc/grpclog"
)

View File

@ -8,7 +8,7 @@ import (
"os"
"testing"
"go.etcd.io/etcd/pkg/testutil"
"go.etcd.io/etcd/v3/pkg/testutil"
)
func TestMain(m *testing.M) {

View File

@ -28,13 +28,13 @@ import (
"go.uber.org/zap"
"google.golang.org/grpc"
"go.etcd.io/etcd/clientv3"
"go.etcd.io/etcd/etcdserver/api/v3rpc/rpctypes"
"go.etcd.io/etcd/integration"
"go.etcd.io/etcd/lease"
"go.etcd.io/etcd/mvcc"
"go.etcd.io/etcd/mvcc/backend"
"go.etcd.io/etcd/pkg/testutil"
"go.etcd.io/etcd/v3/clientv3"
"go.etcd.io/etcd/v3/etcdserver/api/v3rpc/rpctypes"
"go.etcd.io/etcd/v3/integration"
"go.etcd.io/etcd/v3/lease"
"go.etcd.io/etcd/v3/mvcc"
"go.etcd.io/etcd/v3/mvcc/backend"
"go.etcd.io/etcd/v3/pkg/testutil"
)
func TestMaintenanceHashKV(t *testing.T) {

View File

@ -25,10 +25,10 @@ import (
"testing"
"time"
"go.etcd.io/etcd/clientv3"
"go.etcd.io/etcd/integration"
"go.etcd.io/etcd/pkg/testutil"
"go.etcd.io/etcd/pkg/transport"
"go.etcd.io/etcd/v3/clientv3"
"go.etcd.io/etcd/v3/integration"
"go.etcd.io/etcd/v3/pkg/testutil"
"go.etcd.io/etcd/v3/pkg/transport"
grpcprom "github.com/grpc-ecosystem/go-grpc-prometheus"
"github.com/prometheus/client_golang/prometheus/promhttp"

View File

@ -22,10 +22,10 @@ import (
"testing"
"time"
"go.etcd.io/etcd/clientv3/mirror"
"go.etcd.io/etcd/integration"
"go.etcd.io/etcd/mvcc/mvccpb"
"go.etcd.io/etcd/pkg/testutil"
"go.etcd.io/etcd/v3/clientv3/mirror"
"go.etcd.io/etcd/v3/integration"
"go.etcd.io/etcd/v3/mvcc/mvccpb"
"go.etcd.io/etcd/v3/pkg/testutil"
)
func TestMirrorSync(t *testing.T) {

View File

@ -19,11 +19,11 @@ import (
"reflect"
"testing"
"go.etcd.io/etcd/clientv3"
"go.etcd.io/etcd/clientv3/namespace"
"go.etcd.io/etcd/integration"
"go.etcd.io/etcd/mvcc/mvccpb"
"go.etcd.io/etcd/pkg/testutil"
"go.etcd.io/etcd/v3/clientv3"
"go.etcd.io/etcd/v3/clientv3/namespace"
"go.etcd.io/etcd/v3/integration"
"go.etcd.io/etcd/v3/mvcc/mvccpb"
"go.etcd.io/etcd/v3/pkg/testutil"
)
func TestNamespacePutGet(t *testing.T) {

View File

@ -22,11 +22,11 @@ import (
"testing"
"time"
"go.etcd.io/etcd/clientv3"
"go.etcd.io/etcd/etcdserver/api/v3rpc/rpctypes"
pb "go.etcd.io/etcd/etcdserver/etcdserverpb"
"go.etcd.io/etcd/integration"
"go.etcd.io/etcd/pkg/testutil"
"go.etcd.io/etcd/v3/clientv3"
"go.etcd.io/etcd/v3/etcdserver/api/v3rpc/rpctypes"
pb "go.etcd.io/etcd/v3/etcdserver/etcdserverpb"
"go.etcd.io/etcd/v3/integration"
"go.etcd.io/etcd/v3/pkg/testutil"
"google.golang.org/grpc"
)

View File

@ -18,9 +18,9 @@ import (
"context"
"testing"
"go.etcd.io/etcd/etcdserver/api/v3rpc/rpctypes"
"go.etcd.io/etcd/integration"
"go.etcd.io/etcd/pkg/testutil"
"go.etcd.io/etcd/v3/etcdserver/api/v3rpc/rpctypes"
"go.etcd.io/etcd/v3/integration"
"go.etcd.io/etcd/v3/pkg/testutil"
)
func TestRoleError(t *testing.T) {

View File

@ -21,10 +21,10 @@ import (
"testing"
"time"
"go.etcd.io/etcd/clientv3"
"go.etcd.io/etcd/etcdserver/api/v3rpc/rpctypes"
"go.etcd.io/etcd/integration"
"go.etcd.io/etcd/pkg/testutil"
"go.etcd.io/etcd/v3/clientv3"
"go.etcd.io/etcd/v3/etcdserver/api/v3rpc/rpctypes"
"go.etcd.io/etcd/v3/integration"
"go.etcd.io/etcd/v3/pkg/testutil"
"google.golang.org/grpc/codes"
"google.golang.org/grpc/status"

View File

@ -20,11 +20,11 @@ import (
"testing"
"time"
"go.etcd.io/etcd/clientv3"
"go.etcd.io/etcd/embed"
"go.etcd.io/etcd/etcdserver/api/v3rpc/rpctypes"
"go.etcd.io/etcd/integration"
"go.etcd.io/etcd/pkg/testutil"
"go.etcd.io/etcd/v3/clientv3"
"go.etcd.io/etcd/v3/embed"
"go.etcd.io/etcd/v3/etcdserver/api/v3rpc/rpctypes"
"go.etcd.io/etcd/v3/integration"
"go.etcd.io/etcd/v3/pkg/testutil"
)
func TestTxnError(t *testing.T) {

View File

@ -19,10 +19,10 @@ import (
"testing"
"time"
"go.etcd.io/etcd/clientv3"
"go.etcd.io/etcd/etcdserver/api/v3rpc/rpctypes"
"go.etcd.io/etcd/integration"
"go.etcd.io/etcd/pkg/testutil"
"go.etcd.io/etcd/v3/clientv3"
"go.etcd.io/etcd/v3/etcdserver/api/v3rpc/rpctypes"
"go.etcd.io/etcd/v3/integration"
"go.etcd.io/etcd/v3/pkg/testutil"
"google.golang.org/grpc"
)

View File

@ -19,7 +19,7 @@ import (
"testing"
"time"
"go.etcd.io/etcd/clientv3"
"go.etcd.io/etcd/v3/clientv3"
)
// mustWaitPinReady waits up to 3-second until connection is up (pin endpoint).

View File

@ -23,9 +23,9 @@ import (
"testing"
"time"
"go.etcd.io/etcd/clientv3"
"go.etcd.io/etcd/integration"
"go.etcd.io/etcd/pkg/testutil"
"go.etcd.io/etcd/v3/clientv3"
"go.etcd.io/etcd/v3/integration"
"go.etcd.io/etcd/v3/pkg/testutil"
)
// TestWatchFragmentDisable ensures that large watch

View File

@ -24,13 +24,13 @@ import (
"testing"
"time"
"go.etcd.io/etcd/clientv3"
"go.etcd.io/etcd/etcdserver/api/v3rpc"
"go.etcd.io/etcd/etcdserver/api/v3rpc/rpctypes"
"go.etcd.io/etcd/integration"
mvccpb "go.etcd.io/etcd/mvcc/mvccpb"
"go.etcd.io/etcd/pkg/testutil"
"go.etcd.io/etcd/version"
"go.etcd.io/etcd/v3/clientv3"
"go.etcd.io/etcd/v3/etcdserver/api/v3rpc"
"go.etcd.io/etcd/v3/etcdserver/api/v3rpc/rpctypes"
"go.etcd.io/etcd/v3/integration"
mvccpb "go.etcd.io/etcd/v3/mvcc/mvccpb"
"go.etcd.io/etcd/v3/pkg/testutil"
"go.etcd.io/etcd/v3/version"
"google.golang.org/grpc/metadata"
)

View File

@ -17,7 +17,7 @@ package clientv3
import (
"context"
pb "go.etcd.io/etcd/etcdserver/etcdserverpb"
pb "go.etcd.io/etcd/v3/etcdserver/etcdserverpb"
"google.golang.org/grpc"
)

View File

@ -19,8 +19,8 @@ import (
"sync"
"time"
"go.etcd.io/etcd/etcdserver/api/v3rpc/rpctypes"
pb "go.etcd.io/etcd/etcdserver/etcdserverpb"
"go.etcd.io/etcd/v3/etcdserver/api/v3rpc/rpctypes"
pb "go.etcd.io/etcd/v3/etcdserver/etcdserverpb"
"go.uber.org/zap"
"google.golang.org/grpc"

View File

@ -20,9 +20,9 @@ import (
"sync"
"time"
v3 "go.etcd.io/etcd/clientv3"
v3pb "go.etcd.io/etcd/etcdserver/etcdserverpb"
"go.etcd.io/etcd/mvcc/mvccpb"
v3 "go.etcd.io/etcd/v3/clientv3"
v3pb "go.etcd.io/etcd/v3/etcdserver/etcdserverpb"
"go.etcd.io/etcd/v3/mvcc/mvccpb"
)
const revokeBackoff = 2 * time.Second

View File

@ -20,11 +20,11 @@ import (
"sync"
"time"
v3 "go.etcd.io/etcd/clientv3"
"go.etcd.io/etcd/clientv3/concurrency"
"go.etcd.io/etcd/etcdserver/api/v3rpc/rpctypes"
pb "go.etcd.io/etcd/etcdserver/etcdserverpb"
"go.etcd.io/etcd/mvcc/mvccpb"
v3 "go.etcd.io/etcd/v3/clientv3"
"go.etcd.io/etcd/v3/clientv3/concurrency"
"go.etcd.io/etcd/v3/etcdserver/api/v3rpc/rpctypes"
pb "go.etcd.io/etcd/v3/etcdserver/etcdserverpb"
"go.etcd.io/etcd/v3/mvcc/mvccpb"
"google.golang.org/grpc/codes"
"google.golang.org/grpc/status"

View File

@ -18,8 +18,8 @@ import (
"context"
"strings"
v3 "go.etcd.io/etcd/clientv3"
v3pb "go.etcd.io/etcd/etcdserver/etcdserverpb"
v3 "go.etcd.io/etcd/v3/clientv3"
v3pb "go.etcd.io/etcd/v3/etcdserver/etcdserverpb"
)
type txnLeasing struct {

View File

@ -17,8 +17,8 @@ package leasing
import (
"bytes"
v3 "go.etcd.io/etcd/clientv3"
v3pb "go.etcd.io/etcd/etcdserver/etcdserverpb"
v3 "go.etcd.io/etcd/v3/clientv3"
v3pb "go.etcd.io/etcd/v3/etcdserver/etcdserverpb"
)
func compareInt64(a, b int64) int {

View File

@ -18,7 +18,7 @@ import (
"io/ioutil"
"sync"
"go.etcd.io/etcd/pkg/logutil"
"go.etcd.io/etcd/v3/pkg/logutil"
"google.golang.org/grpc/grpclog"
)

View File

@ -22,8 +22,8 @@ import (
"testing"
"time"
"go.etcd.io/etcd/integration"
"go.etcd.io/etcd/pkg/testutil"
"go.etcd.io/etcd/v3/integration"
"go.etcd.io/etcd/v3/pkg/testutil"
)
// TestMain sets up an etcd cluster if running the examples.

View File

@ -19,7 +19,7 @@ import (
"fmt"
"io"
pb "go.etcd.io/etcd/etcdserver/etcdserverpb"
pb "go.etcd.io/etcd/v3/etcdserver/etcdserverpb"
"google.golang.org/grpc"
)

View File

@ -18,7 +18,7 @@ package mirror
import (
"context"
"go.etcd.io/etcd/clientv3"
"go.etcd.io/etcd/v3/clientv3"
)
const (

View File

@ -17,9 +17,9 @@ package namespace
import (
"context"
"go.etcd.io/etcd/clientv3"
"go.etcd.io/etcd/etcdserver/api/v3rpc/rpctypes"
pb "go.etcd.io/etcd/etcdserver/etcdserverpb"
"go.etcd.io/etcd/v3/clientv3"
"go.etcd.io/etcd/v3/etcdserver/api/v3rpc/rpctypes"
pb "go.etcd.io/etcd/v3/etcdserver/etcdserverpb"
)
type kvPrefix struct {

View File

@ -18,7 +18,7 @@ import (
"bytes"
"context"
"go.etcd.io/etcd/clientv3"
"go.etcd.io/etcd/v3/clientv3"
)
type leasePrefix struct {

View File

@ -18,7 +18,7 @@ import (
"context"
"sync"
"go.etcd.io/etcd/clientv3"
"go.etcd.io/etcd/v3/clientv3"
)
type watcherPrefix struct {

View File

@ -17,8 +17,8 @@
// To use, first import the packages:
//
// import (
// "go.etcd.io/etcd/clientv3"
// etcdnaming "go.etcd.io/etcd/clientv3/naming"
// "go.etcd.io/etcd/v3/clientv3"
// etcdnaming "go.etcd.io/etcd/v3/clientv3/naming"
//
// "google.golang.org/grpc"
// "google.golang.org/grpc/naming"

View File

@ -19,7 +19,7 @@ import (
"encoding/json"
"fmt"
etcd "go.etcd.io/etcd/clientv3"
etcd "go.etcd.io/etcd/v3/clientv3"
"google.golang.org/grpc/codes"
"google.golang.org/grpc/naming"

View File

@ -20,9 +20,9 @@ import (
"reflect"
"testing"
etcd "go.etcd.io/etcd/clientv3"
"go.etcd.io/etcd/integration"
"go.etcd.io/etcd/pkg/testutil"
etcd "go.etcd.io/etcd/v3/clientv3"
"go.etcd.io/etcd/v3/integration"
"go.etcd.io/etcd/v3/pkg/testutil"
"google.golang.org/grpc/naming"
)

View File

@ -14,7 +14,7 @@
package clientv3
import pb "go.etcd.io/etcd/etcdserver/etcdserverpb"
import pb "go.etcd.io/etcd/v3/etcdserver/etcdserverpb"
type opType int

View File

@ -18,7 +18,7 @@ import (
"reflect"
"testing"
pb "go.etcd.io/etcd/etcdserver/etcdserverpb"
pb "go.etcd.io/etcd/v3/etcdserver/etcdserverpb"
)
// TestOpWithSort tests if WithSort(ASCEND, KEY) and WithLimit are specified,

View File

@ -18,7 +18,7 @@ import (
"context"
"sync"
"go.etcd.io/etcd/clientv3"
"go.etcd.io/etcd/v3/clientv3"
)
// kvOrdering ensures that serialized requests do not return

View File

@ -22,10 +22,10 @@ import (
"testing"
"time"
"go.etcd.io/etcd/clientv3"
pb "go.etcd.io/etcd/etcdserver/etcdserverpb"
"go.etcd.io/etcd/integration"
"go.etcd.io/etcd/pkg/testutil"
"go.etcd.io/etcd/v3/clientv3"
pb "go.etcd.io/etcd/v3/etcdserver/etcdserverpb"
"go.etcd.io/etcd/v3/integration"
"go.etcd.io/etcd/v3/pkg/testutil"
)
func TestDetectKvOrderViolation(t *testing.T) {

View File

@ -17,7 +17,7 @@ package ordering
import (
"io/ioutil"
"go.etcd.io/etcd/clientv3"
"go.etcd.io/etcd/v3/clientv3"
"google.golang.org/grpc/grpclog"
)

View File

@ -19,7 +19,7 @@ import (
"sync"
"time"
"go.etcd.io/etcd/clientv3"
"go.etcd.io/etcd/v3/clientv3"
)
type OrderViolationFunc func(op clientv3.Op, resp clientv3.OpResponse, prevRev int64) error

View File

@ -19,9 +19,9 @@ import (
"testing"
"time"
"go.etcd.io/etcd/clientv3"
"go.etcd.io/etcd/integration"
"go.etcd.io/etcd/pkg/testutil"
"go.etcd.io/etcd/v3/clientv3"
"go.etcd.io/etcd/v3/integration"
"go.etcd.io/etcd/v3/pkg/testutil"
)
func TestEndpointSwitchResolvesViolation(t *testing.T) {

View File

@ -17,8 +17,8 @@ package clientv3
import (
"context"
"go.etcd.io/etcd/etcdserver/api/v3rpc/rpctypes"
pb "go.etcd.io/etcd/etcdserver/etcdserverpb"
"go.etcd.io/etcd/v3/etcdserver/api/v3rpc/rpctypes"
pb "go.etcd.io/etcd/v3/etcdserver/etcdserverpb"
"google.golang.org/grpc"
"google.golang.org/grpc/codes"

Some files were not shown because too many files have changed in this diff Show More