Replace "golang.org/x/net/context" with "context"

Kubernetes-commit: 70e45eccf27726f0e63dd1024924ccc7e2cd35a0
This commit is contained in:
hzxuzhonghu 2018-02-28 12:20:22 +08:00 committed by Kubernetes Publisher
parent a9479539b7
commit 6ab99203b7
20 changed files with 23 additions and 25 deletions

View File

@ -17,10 +17,10 @@ limitations under the License.
package request
import (
"context"
stderrs "errors"
"time"
"golang.org/x/net/context"
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
"k8s.io/apimachinery/pkg/types"
"k8s.io/apiserver/pkg/apis/audit"

View File

@ -17,10 +17,9 @@ limitations under the License.
package registry
import (
"context"
"net/http"
"golang.org/x/net/context"
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
"k8s.io/apimachinery/pkg/watch"
)

View File

@ -17,6 +17,7 @@ limitations under the License.
package storage
import (
"context"
"fmt"
"net/http"
"reflect"
@ -24,7 +25,6 @@ import (
"time"
"github.com/golang/glog"
"golang.org/x/net/context"
"k8s.io/apimachinery/pkg/api/errors"
"k8s.io/apimachinery/pkg/api/meta"

View File

@ -17,6 +17,7 @@ limitations under the License.
package etcd
import (
"context"
"errors"
"fmt"
"path"
@ -25,7 +26,6 @@ import (
etcd "github.com/coreos/etcd/client"
"github.com/golang/glog"
"golang.org/x/net/context"
"k8s.io/apimachinery/pkg/api/meta"
"k8s.io/apimachinery/pkg/conversion"

View File

@ -17,6 +17,7 @@ limitations under the License.
package etcd
import (
"context"
"fmt"
"path"
"reflect"
@ -26,7 +27,6 @@ import (
"time"
etcd "github.com/coreos/etcd/client"
"golang.org/x/net/context"
apitesting "k8s.io/apimachinery/pkg/api/testing"
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
"k8s.io/apimachinery/pkg/conversion"

View File

@ -17,6 +17,7 @@ limitations under the License.
package etcd
import (
"context"
"fmt"
"net/http"
"reflect"
@ -32,7 +33,6 @@ import (
etcd "github.com/coreos/etcd/client"
"github.com/golang/glog"
"golang.org/x/net/context"
)
// Etcd watch event actions

View File

@ -17,6 +17,7 @@ limitations under the License.
package etcd
import (
"context"
rt "runtime"
"testing"
@ -35,7 +36,6 @@ import (
etcdtesting "k8s.io/apiserver/pkg/storage/etcd/testing"
etcd "github.com/coreos/etcd/client"
"golang.org/x/net/context"
)
var versioner = APIObjectVersioner{}

View File

@ -32,6 +32,8 @@ import (
"k8s.io/apiserver/pkg/storage/etcd/testing/testingcert"
"k8s.io/apiserver/pkg/storage/storagebackend"
"context"
etcd "github.com/coreos/etcd/client"
"github.com/coreos/etcd/clientv3"
"github.com/coreos/etcd/etcdserver"
@ -42,7 +44,6 @@ import (
"github.com/coreos/etcd/pkg/transport"
"github.com/coreos/etcd/pkg/types"
"github.com/golang/glog"
"golang.org/x/net/context"
)
// EtcdTestServer encapsulates the datastructures needed to start local instance for testing

View File

@ -17,13 +17,13 @@ limitations under the License.
package etcd3
import (
"context"
"strconv"
"sync"
"time"
"github.com/coreos/etcd/clientv3"
"github.com/golang/glog"
"golang.org/x/net/context"
)
const (

View File

@ -17,12 +17,12 @@ limitations under the License.
package etcd3
import (
"context"
"testing"
"github.com/coreos/etcd/clientv3"
etcdrpc "github.com/coreos/etcd/etcdserver/api/v3rpc/rpctypes"
"github.com/coreos/etcd/integration"
"golang.org/x/net/context"
)
func TestCompact(t *testing.T) {

View File

@ -18,6 +18,7 @@ package etcd3
import (
"bytes"
"context"
"encoding/base64"
"encoding/json"
"errors"
@ -29,7 +30,6 @@ import (
"github.com/coreos/etcd/clientv3"
"github.com/golang/glog"
"golang.org/x/net/context"
apierrors "k8s.io/apimachinery/pkg/api/errors"
"k8s.io/apimachinery/pkg/api/meta"

View File

@ -18,6 +18,7 @@ package etcd3
import (
"bytes"
"context"
"encoding/base64"
"encoding/json"
"errors"
@ -30,7 +31,6 @@ import (
"github.com/coreos/etcd/clientv3"
"github.com/coreos/etcd/integration"
"github.com/coreos/pkg/capnslog"
"golang.org/x/net/context"
apierrors "k8s.io/apimachinery/pkg/api/errors"
apitesting "k8s.io/apimachinery/pkg/api/testing"
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"

View File

@ -17,6 +17,7 @@ limitations under the License.
package etcd3
import (
"context"
"errors"
"fmt"
"os"
@ -32,7 +33,6 @@ import (
"github.com/coreos/etcd/clientv3"
"github.com/golang/glog"
"golang.org/x/net/context"
)
const (

View File

@ -17,6 +17,7 @@ limitations under the License.
package etcd3
import (
"context"
"fmt"
"reflect"
"sync"
@ -25,7 +26,6 @@ import (
"github.com/coreos/etcd/clientv3"
"github.com/coreos/etcd/integration"
"golang.org/x/net/context"
apitesting "k8s.io/apimachinery/pkg/api/testing"
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"

View File

@ -17,7 +17,8 @@ limitations under the License.
package storage
import (
"golang.org/x/net/context"
"context"
"k8s.io/apimachinery/pkg/fields"
"k8s.io/apimachinery/pkg/labels"
"k8s.io/apimachinery/pkg/runtime"

View File

@ -17,11 +17,11 @@ limitations under the License.
package factory
import (
"context"
"time"
"github.com/coreos/etcd/clientv3"
"github.com/coreos/etcd/pkg/transport"
"golang.org/x/net/context"
"k8s.io/apiserver/pkg/storage"
"k8s.io/apiserver/pkg/storage/etcd3"

View File

@ -17,6 +17,7 @@ limitations under the License.
package factory
import (
"context"
"io/ioutil"
"os"
"path"
@ -25,7 +26,6 @@ import (
"github.com/coreos/etcd/integration"
"github.com/coreos/etcd/pkg/transport"
"golang.org/x/net/context"
apitesting "k8s.io/apimachinery/pkg/api/testing"
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"

View File

@ -17,9 +17,9 @@ limitations under the License.
package testing
import (
"context"
"path"
"golang.org/x/net/context"
"k8s.io/apimachinery/pkg/api/meta"
"k8s.io/apimachinery/pkg/runtime"
"k8s.io/apiserver/pkg/storage"

View File

@ -17,6 +17,7 @@ limitations under the License.
package tests
import (
"context"
"fmt"
"reflect"
goruntime "runtime"
@ -32,6 +33,7 @@ import (
"k8s.io/apimachinery/pkg/fields"
"k8s.io/apimachinery/pkg/labels"
"k8s.io/apimachinery/pkg/runtime"
"k8s.io/apimachinery/pkg/runtime/serializer"
"k8s.io/apimachinery/pkg/util/sets"
"k8s.io/apimachinery/pkg/util/wait"
"k8s.io/apimachinery/pkg/watch"
@ -43,10 +45,6 @@ import (
etcdtesting "k8s.io/apiserver/pkg/storage/etcd/testing"
"k8s.io/apiserver/pkg/storage/etcd3"
"k8s.io/apiserver/pkg/storage/value"
"golang.org/x/net/context"
"k8s.io/apimachinery/pkg/runtime/serializer"
)
var (

View File

@ -18,6 +18,7 @@ limitations under the License.
package envelope
import (
"context"
"fmt"
"net"
"net/url"
@ -27,8 +28,6 @@ import (
"google.golang.org/grpc"
"golang.org/x/net/context"
kmsapi "k8s.io/apiserver/pkg/storage/value/encrypt/envelope/v1beta1"
)