Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bug 1815637: bump etcd v3.3.20 #45

Closed
wants to merge 42 commits into from

Conversation

hexfusion
Copy link

This PR bumps etcd to v3.3.20 which includes a few important bugfixes:

etcd server

client v3

gRPC Proxy

3.3.19 changelog: https://github.com/etcd-io/etcd/blob/master/CHANGELOG-3.3.md#v3319-2020-03-18
3.3.20 changelog https://github.com/etcd-io/etcd/blob/master/CHANGELOG-3.3.md#v3320-2020-04-01

Carry: 151bb84

horkhe and others added 30 commits November 20, 2019 16:45
Once chk(ai) fails with auth.ErrAuthOldRevision it will always do,
regardless how many times you retry. So the error is better be returned
to fail the pending request and make the client re-authenticate.
Remove auth validation loop in v3_server.raftRequest(). Re-validation
when error ErrAuthOldRevision occurs should be handled on client side.
Disable TestV3AuthOldRevConcurrent for now. See
etcd-io#10468 (comment)
…f-#10218-etcd-io#10468-upstream-release-3.3

Automated cherry pick of etcd-io#10218 etcd-io#10468 on release 3.3
…-#11613-origin-release-3.3

Automated cherry pick of etcd-io#11613 to release-3.3
Check if boltOpenOptions is nil before use it.
…f-#11630-upstream-release-3.3

Automated cherry pick of etcd-io#11630 to release-3.3
Use members information from member add response, which is
guaranteed to be up to date.
…f-#11638-upstream-release-3.3

Automated cherry pick of etcd-io#11638 on release-3.3
Signed-off-by: Sam Batschelet <sbatsche@redhat.com>
ref.
etcd-io#11704

Signed-off-by: Gyuho Lee <leegyuho@amazon.com>
ref.
etcd-io#11687

Signed-off-by: Gyuho Lee <leegyuho@amazon.com>

clientv3: fix racy writes to context key

=== RUN   TestWatchOverlapContextCancel

==================

WARNING: DATA RACE

Write at 0x00c42110dd40 by goroutine 99:

  runtime.mapassign()

      /usr/local/go/src/runtime/hashmap.go:485 +0x0

  github.com/coreos/etcd/clientv3.metadataSet()

      /go/src/github.com/coreos/etcd/gopath/src/github.com/coreos/etcd/clientv3/ctx.go:61 +0x8c

  github.com/coreos/etcd/clientv3.withVersion()

      /go/src/github.com/coreos/etcd/gopath/src/github.com/coreos/etcd/clientv3/ctx.go:47 +0x137

  github.com/coreos/etcd/clientv3.newStreamClientInterceptor.func1()

      /go/src/github.com/coreos/etcd/gopath/src/github.com/coreos/etcd/clientv3/client.go:309 +0x81

  google.golang.org/grpc.NewClientStream()

      /go/src/github.com/coreos/etcd/gopath/src/google.golang.org/grpc/stream.go:101 +0x10e

  github.com/coreos/etcd/etcdserver/etcdserverpb.(*watchClient).Watch()

      /go/src/github.com/coreos/etcd/gopath/src/github.com/coreos/etcd/etcdserver/etcdserverpb/rpc.pb.go:3193 +0xe9

  github.com/coreos/etcd/clientv3.(*watchGrpcStream).openWatchClient()

      /go/src/github.com/coreos/etcd/gopath/src/github.com/coreos/etcd/clientv3/watch.go:788 +0x143

  github.com/coreos/etcd/clientv3.(*watchGrpcStream).newWatchClient()

      /go/src/github.com/coreos/etcd/gopath/src/github.com/coreos/etcd/clientv3/watch.go:700 +0x5c3

  github.com/coreos/etcd/clientv3.(*watchGrpcStream).run()

      /go/src/github.com/coreos/etcd/gopath/src/github.com/coreos/etcd/clientv3/watch.go:431 +0x12b

Previous read at 0x00c42110dd40 by goroutine 130:

  reflect.maplen()

      /usr/local/go/src/runtime/hashmap.go:1165 +0x0

  reflect.Value.MapKeys()

      /usr/local/go/src/reflect/value.go:1090 +0x43b

  fmt.(*pp).printValue()

      /usr/local/go/src/fmt/print.go:741 +0x1885

  fmt.(*pp).printArg()

      /usr/local/go/src/fmt/print.go:682 +0x1b1

  fmt.(*pp).doPrintf()

      /usr/local/go/src/fmt/print.go:998 +0x1cad

  fmt.Sprintf()

      /usr/local/go/src/fmt/print.go:196 +0x77

  github.com/coreos/etcd/clientv3.streamKeyFromCtx()

      /go/src/github.com/coreos/etcd/gopath/src/github.com/coreos/etcd/clientv3/watch.go:825 +0xc8

  github.com/coreos/etcd/clientv3.(*watcher).Watch()

      /go/src/github.com/coreos/etcd/gopath/src/github.com/coreos/etcd/clientv3/watch.go:265 +0x426

  github.com/coreos/etcd/clientv3/integration.testWatchOverlapContextCancel.func1()

      /go/src/github.com/coreos/etcd/gopath/src/github.com/coreos/etcd/clientv3/integration/watch_test.go:959 +0x23e

Goroutine 99 (running) created at:

  github.com/coreos/etcd/clientv3.(*watcher).newWatcherGrpcStream()

      /go/src/github.com/coreos/etcd/gopath/src/github.com/coreos/etcd/clientv3/watch.go:236 +0x59d

  github.com/coreos/etcd/clientv3.(*watcher).Watch()

      /go/src/github.com/coreos/etcd/gopath/src/github.com/coreos/etcd/clientv3/watch.go:278 +0xbb6

  github.com/coreos/etcd/clientv3/integration.testWatchOverlapContextCancel.func1()

      /go/src/github.com/coreos/etcd/gopath/src/github.com/coreos/etcd/clientv3/integration/watch_test.go:959 +0x23e

Goroutine 130 (running) created at:

  github.com/coreos/etcd/clientv3/integration.testWatchOverlapContextCancel()

      /go/src/github.com/coreos/etcd/gopath/src/github.com/coreos/etcd/clientv3/integration/watch_test.go:979 +0x76d

  github.com/coreos/etcd/clientv3/integration.TestWatchOverlapContextCancel()

      /go/src/github.com/coreos/etcd/gopath/src/github.com/coreos/etcd/clientv3/integration/watch_test.go:922 +0x44

  testing.tRunner()

      /usr/local/go/src/testing/testing.go:657 +0x107

==================

Signed-off-by: Gyuho Lee <leegyuho@amazon.com>
ref.
etcd-io#11687

Signed-off-by: Gyuho Lee <leegyuho@amazon.com>
Signed-off-by: Gyuho Lee <leegyuho@amazon.com>
Signed-off-by: Gyuho Lee <leegyuho@amazon.com>
This reverts commit 3f6b978.
Signed-off-by: Gyuho Lee <leegyuho@amazon.com>
Signed-off-by: Gyuho Lee <leegyuho@amazon.com>
This reverts commit acb9746.
Signed-off-by: Gyuho Lee <leegyuho@amazon.com>
Signed-off-by: Gyuho Lee <leegyuho@amazon.com>
Signed-off-by: Gyuho Lee <leegyuho@amazon.com>
Signed-off-by: Gyuho Lee <leegyuho@amazon.com>
Signed-off-by: Gyuho Lee <leegyuho@amazon.com>
Signed-off-by: Sam Batschelet <sbatsche@redhat.com>
Signed-off-by: Sam Batschelet <sbatsche@redhat.com>
Correcting a typo from 2f10964 (version: openshift-v4.0, 2018-11-29).
…uild.

Signed-off-by: Sam Batschelet <sbatsche@redhat.com>
Signed-off-by: Sam Batschelet <sbatsche@redhat.com>
hexfusion and others added 12 commits April 17, 2020 10:17
Signed-off-by: Sam Batschelet <sbatsche@redhat.com>
Signed-off-by: Sam Batschelet <sbatsche@redhat.com>
make build performs a sanity test on the binary image which causes problems for unsupport arch. Because we run full CI tests against the image this check is not nessisary and will allow images to be build regardless of arch.

Signed-off-by: Sam Batschelet <sbatsche@redhat.com>
Signed-off-by: Sam Batschelet <sbatsche@redhat.com>
CARRY:

This bump resolves and issue where max frame size (16kb) was not
defined which has security implications.

Signed-off-by: Sam Batschelet <sbatsche@redhat.com>
@openshift-ci-robot openshift-ci-robot added bugzilla/severity-high Referenced Bugzilla bug's severity is high for the branch this PR is targeting. bugzilla/invalid-bug Indicates that a referenced Bugzilla bug is invalid for the branch this PR is targeting. labels Apr 17, 2020
@openshift-ci-robot
Copy link

@hexfusion: This pull request references Bugzilla bug 1815637, which is invalid:

  • expected the bug to target the "4.4.0" release, but it targets "4.5.0" instead
  • expected Bugzilla bug 1815637 to depend on a bug targeting a release in 4.5.0, 4.5.z and in one of the following states: VERIFIED, RELEASE_PENDING, CLOSED (ERRATA), but no dependents were found

Comment /bugzilla refresh to re-evaluate validity if changes to the Bugzilla bug are made, or edit the title of this pull request to link to a different bug.

In response to this:

Bug 1815637: bump etcd v3.3.20

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

@openshift-ci-robot
Copy link

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: hexfusion

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:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@openshift-ci-robot openshift-ci-robot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Apr 17, 2020
@hexfusion
Copy link
Author

hexfusion commented Apr 17, 2020

validate integrity of rebase.

git diff openshift-4.4-bump-etcd-v3.3.20..v3.3.20

diff --git a/.dockerignore b/.dockerignore
index e69de29bb..6b8710a71 100644
--- a/.dockerignore
+++ b/.dockerignore
@@ -0,0 +1 @@
+.git
diff --git a/Dockerfile.openshift b/Dockerfile.openshift
deleted file mode 100644
index 78303e525..000000000
--- a/Dockerfile.openshift
+++ /dev/null
@@ -1,20 +0,0 @@
-FROM registry.svc.ci.openshift.org/openshift/release:golang-1.12 AS builder
-
-WORKDIR /go/src/github.com/coreos/etcd
-
-COPY . .
-
-RUN ./build
-
-# stage 2
-FROM registry.svc.ci.openshift.org/openshift/origin-v4.0:base
-
-ENTRYPOINT ["/usr/bin/etcd"]
-
-COPY --from=builder /go/src/github.com/coreos/etcd/bin/etcd /usr/bin/
-COPY --from=builder /go/src/github.com/coreos/etcd/bin/etcdctl /usr/bin/
-COPY --from=builder /go/src/github.com/coreos/etcd/bin/discover-etcd-initial-cluster /usr/bin/
-
-LABEL io.k8s.display-name="etcd server" \
-      io.k8s.description="etcd is a distributed key-value store which stores the persistent master state for Kubernetes and OpenShift." \
-      maintainer="Sam Batschelet <sbatsche@redhat.com>"
diff --git a/Dockerfile.rhel b/Dockerfile.rhel
deleted file mode 100644
index bd353e1a3..000000000
--- a/Dockerfile.rhel
+++ /dev/null
@@ -1,20 +0,0 @@
-FROM openshift/golang-builder:1.12 AS builder
-
-WORKDIR /go/src/github.com/coreos/etcd
-
-COPY . .
-
-RUN ./build
-
-# stage 2
-FROM openshift/origin-base
-
-ENTRYPOINT ["/usr/bin/etcd"]
-
-COPY --from=builder /go/src/github.com/coreos/etcd/bin/etcd /usr/bin/
-COPY --from=builder /go/src/github.com/coreos/etcd/bin/etcdctl /usr/bin/
-COPY --from=builder /go/src/github.com/coreos/etcd/bin/discover-etcd-initial-cluster /usr/bin/
-
-LABEL io.k8s.display-name="etcd server" \
-      io.k8s.description="etcd is a distributed key-value store which stores the persistent master state for Kubernetes and OpenShift." \
-      maintainer="Sam Batschelet <sbatsche@redhat.com>"
diff --git a/OWNERS b/OWNERS
deleted file mode 100644
index 572c3af9d..000000000
--- a/OWNERS
+++ /dev/null
@@ -1,8 +0,0 @@
-approvers:
-- hexfusion
-reviewers:
-- deads2k
-- crawford
-- hexfusion
-- smarterclayton
-- wking
diff --git a/build b/build
index e0787aaa8..5cf4d7c64 100755
--- a/build
+++ b/build
@@ -64,20 +64,6 @@ etcd_build() {
 		-o "${out}/etcdctl" ${REPO_PATH}/etcdctl || return
 }
 
-
-openshift_tools_build() {
-	out="bin"
-	if [[ -n "${BINDIR}" ]]; then out="${BINDIR}"; fi
-	toggle_failpoints_default
-
-	# Static compilation is useful when etcd is run in a container. $GO_BUILD_FLAGS is OK
-	# shellcheck disable=SC2086
-	CGO_ENABLED=0 go build $GO_BUILD_FLAGS \
-		-installsuffix cgo \
-		-ldflags "$GO_LDFLAGS" \
-		-o "${out}/discover-etcd-initial-cluster" "github.com/coreos/etcd/openshift-tools/discover-etcd-initial-cluster" || return
-}
-
 tools_build() {
 	out="bin"
 	if [[ -n "${BINDIR}" ]]; then out="${BINDIR}"; fi
@@ -105,5 +91,4 @@ fi
 # only build when called directly, not sourced
 if echo "$0" | grep "build$" >/dev/null; then
 	etcd_build
-	openshift_tools_build
 fi
diff --git a/glide.lock b/glide.lock
index 31c787a2d..5fcf059ca 100644
--- a/glide.lock
+++ b/glide.lock
@@ -1,5 +1,5 @@
-hash: fb475a41a3ff034787f702d39abce833083d7fc3c37aa80e2bf35f82655c0a31
-updated: 2020-04-17T10:25:50.74702498-04:00
+hash: 3fece95d13153dbb91034bd2708f8f7a39510c682dfda4c3ff691f09a61a2fc1
+updated: 2019-08-19T20:45:29.93927922-07:00
 imports:
 - name: github.com/beorn7/perks
   version: 37c8de3658fcb183f997c4e13e8337516ab753e6
@@ -184,7 +184,7 @@ imports:
   - googleapis/api/annotations
   - googleapis/rpc/status
 - name: google.golang.org/grpc
-  version: 39e8a7b072a67ca2a75f57fa2e0d50995f5b22f6
+  version: 6eaf6f47437a6b4e2153a190160ef39a92c7eceb
   subpackages:
   - balancer
   - balancer/base
diff --git a/glide.yaml b/glide.yaml
index f9cbb2348..00b10851a 100644
--- a/glide.yaml
+++ b/glide.yaml
@@ -122,7 +122,7 @@ import:
   subpackages:
   - rate
 - package: google.golang.org/grpc
-  version: v1.23.1
+  version: v1.23.0
   subpackages:
   - balancer
   - codes
diff --git a/openshift-tools/discover-etcd-initial-cluster/main.go b/openshift-tools/discover-etcd-initial-cluster/main.go
deleted file mode 100644
index de62e32a9..000000000
--- a/openshift-tools/discover-etcd-initial-cluster/main.go
+++ /dev/null
@@ -1,35 +0,0 @@
-package main
-
-import (
-	goflag "flag"
-	"fmt"
-	"math/rand"
-	"os"
-	"strings"
-	"time"
-
-	discover_etcd_initial_cluster "github.com/coreos/etcd/openshift-tools/pkg/discover-etcd-initial-cluster"
-	"github.com/spf13/pflag"
-)
-
-// copy from `utilflag "k8s.io/component-base/cli/flag"`
-// WordSepNormalizeFunc changes all flags that contain "_" separators
-func WordSepNormalizeFunc(f *pflag.FlagSet, name string) pflag.NormalizedName {
-	if strings.Contains(name, "_") {
-		return pflag.NormalizedName(strings.Replace(name, "_", "-", -1))
-	}
-	return pflag.NormalizedName(name)
-}
-
-func main() {
-	rand.Seed(time.Now().UTC().UnixNano())
-
-	pflag.CommandLine.SetNormalizeFunc(WordSepNormalizeFunc)
-	pflag.CommandLine.AddGoFlagSet(goflag.CommandLine)
-
-	command := discover_etcd_initial_cluster.NewDiscoverEtcdInitialClusterCommand()
-	if err := command.Execute(); err != nil {
-		fmt.Fprintf(os.Stderr, "%v\n", err)
-		os.Exit(1)
-	}
-}
diff --git a/openshift-tools/pkg/discover-etcd-initial-cluster/initial-cluster.go b/openshift-tools/pkg/discover-etcd-initial-cluster/initial-cluster.go
deleted file mode 100644
index cbcb5de5f..000000000
--- a/openshift-tools/pkg/discover-etcd-initial-cluster/initial-cluster.go
+++ /dev/null
@@ -1,276 +0,0 @@
-package discover_etcd_initial_cluster
-
-import (
-	"context"
-	"fmt"
-	"os"
-	"path/filepath"
-	"strings"
-	"time"
-
-	"github.com/coreos/etcd/etcdserver/etcdserverpb"
-
-	"github.com/coreos/etcd/pkg/transport"
-	"google.golang.org/grpc"
-
-	"github.com/coreos/etcd/clientv3"
-
-	"github.com/spf13/pflag"
-
-	"github.com/spf13/cobra"
-)
-
-type DiscoverEtcdInitialClusterOptions struct {
-	// TargetPeerURLHost is the host portion of the peer URL.  It is used to match on. (either IP or hostname)
-	TargetPeerURLHost string
-	// TargetName is the name to assign to this peer if we create it
-	TargetName string
-
-	// CABundleFile is the file to use to trust the etcd server
-	CABundleFile string
-	// ClientCertFile is the client cert to use to authenticate this binary to etcd
-	ClientCertFile string
-	// ClientKeyFile is the client key to use to authenticate this binary to etcd
-	ClientKeyFile string
-	// Endpoints is a list of all the endpoints to use to try to contact etcd
-	Endpoints []string
-
-	// DataDir is the directory created when etcd starts the first time
-	DataDir string
-}
-
-func NewDiscoverEtcdInitialCluster() *DiscoverEtcdInitialClusterOptions {
-	return &DiscoverEtcdInitialClusterOptions{}
-}
-
-func NewDiscoverEtcdInitialClusterCommand() *cobra.Command {
-	o := NewDiscoverEtcdInitialCluster()
-
-	cmd := &cobra.Command{
-		Use:   "discover-etcd-initial-cluster",
-		Short: "output the value for ETCD_INITIAL_CLUSTER in openshift etcd static pod",
-		Long: `output the value for ETCD_INITIAL_CLUSTER in openshift etcd static pod
-
-1. If --data-dir exists, output a marker value and exit.
-2. It tries to contact every available etcd to get a list of member.
-3. Check each member to see if any one of them is the target.
-4. If so, and if it is started, use the member list to create the ETCD_INITIAL_CLUSTER value and print it out.
-5. If so, and if it it not started, use the existing member list and append the target value to create the ETCD_INITIAL_CLUSTER value and print it out.
-6. If not, try again until either you have it or you time out.
-`,
-		Run: func(cmd *cobra.Command, args []string) {
-			if err := o.Validate(); err != nil {
-				fmt.Fprint(os.Stderr, err)
-				os.Exit(1)
-			}
-
-			if err := o.Run(); err != nil {
-				fmt.Fprint(os.Stderr, err)
-				os.Exit(1)
-			}
-		},
-	}
-	o.BindFlags(cmd.Flags())
-
-	return cmd
-}
-
-func (o *DiscoverEtcdInitialClusterOptions) BindFlags(flags *pflag.FlagSet) {
-	flags.StringVar(&o.CABundleFile, "cacert", o.CABundleFile, "file to use to verify the identity of the etcd server")
-	flags.StringVar(&o.ClientCertFile, "cert", o.ClientCertFile, "client cert to use to authenticate this binary to etcd")
-	flags.StringVar(&o.ClientKeyFile, "key", o.ClientKeyFile, "client key to use to authenticate this binary to etcd")
-	flags.StringSliceVar(&o.Endpoints, "endpoints", o.Endpoints, "list of all the endpoints to use to try to contact etcd")
-	flags.StringVar(&o.DataDir, "data-dir", o.DataDir, "dir to stat for existence of the member directory")
-	flags.StringVar(&o.TargetPeerURLHost, "target-peer-url-host", o.TargetPeerURLHost, "host portion of the peer URL.  It is used to match on. (either IP or hostname)")
-	flags.StringVar(&o.TargetName, "target-name", o.TargetName, "name to assign to this peer if we create it")
-}
-
-func (o *DiscoverEtcdInitialClusterOptions) Validate() error {
-	if len(o.CABundleFile) == 0 {
-		return fmt.Errorf("missing --cacert")
-	}
-	if len(o.ClientCertFile) == 0 {
-		return fmt.Errorf("missing --cert")
-	}
-	if len(o.ClientKeyFile) == 0 {
-		return fmt.Errorf("missing --key")
-	}
-	if len(o.Endpoints) == 0 {
-		return fmt.Errorf("missing --endpoints")
-	}
-	if len(o.DataDir) == 0 {
-		return fmt.Errorf("missing --data-dir")
-	}
-	if len(o.TargetPeerURLHost) == 0 {
-		return fmt.Errorf("missing --target-peer-url-host")
-	}
-	if len(o.TargetName) == 0 {
-		return fmt.Errorf("missing --target-name")
-	}
-	return nil
-}
-
-func (o *DiscoverEtcdInitialClusterOptions) Run() error {
-
-	//Temporary hack to work with the current pod.yaml
-	var memberDir string
-	if strings.HasSuffix(o.DataDir, "member") {
-		memberDir = o.DataDir
-		o.DataDir = filepath.Dir(o.DataDir)
-	} else {
-		memberDir = filepath.Join(o.DataDir, "member")
-	}
-
-	memberDirExists := false
-	_, err := os.Stat(memberDir)
-	switch {
-	case os.IsNotExist(err):
-		// do nothing. This just means we fall through to the polling logic
-
-	case err == nil:
-		fmt.Fprintf(os.Stderr, "memberDir %s is present on %s\n", memberDir, o.TargetName)
-		memberDirExists = true
-
-	case err != nil:
-		return err
-	}
-
-	client, err := o.getClient()
-	if err != nil && memberDirExists {
-		// we weren't able to get client and need to return based previous memberDir so we can restart.  This is the off and on again flow.
-		fmt.Fprintf(os.Stderr, "Couldn't get client, but memberDir %s is present on %s, err=%s. Returning with no error.\n", memberDir, o.TargetName, err)
-		fmt.Printf(o.TargetName)
-		return nil
-	} else if err != nil {
-		return err
-	}
-	defer client.Close()
-
-	var targetMember *etcdserverpb.Member
-	var allMembers []*etcdserverpb.Member
-	for i := 0; i < 10; i++ {
-		fmt.Fprintf(os.Stderr, "#### attempt %d\n", i)
-		targetMember, allMembers, err = o.checkForTarget(client)
-
-		for _, member := range allMembers {
-			fmt.Fprintf(os.Stderr, "      member=%v\n", stringifyMember(member))
-		}
-		fmt.Fprintf(os.Stderr, "      target=%v, err=%v\n", stringifyMember(targetMember), err)
-
-		// we're done because we found what we want.
-		if targetMember != nil && err == nil {
-			break
-		}
-
-		fmt.Fprintf(os.Stderr, "#### sleeping...\n")
-		time.Sleep(1 * time.Second)
-	}
-
-	switch {
-	case targetMember == nil && memberDirExists:
-		// we weren't able to locate other members and need to return based previous memberDir so we can restart.  This is again the off and on flow.
-		fmt.Fprintf(os.Stderr, "Couldn't get targetMember, but memberDir %s is present on %s. Returning with no error.\n", memberDir, o.TargetName)
-		fmt.Printf(o.TargetName)
-		return nil
-
-	case err != nil:
-		fmt.Fprintf(os.Stderr, "Couldn't get targetMember. Returning error.\n")
-		return err
-
-	case targetMember == nil && !memberDirExists:
-		// our member has not been added to the cluster and we have no previous data to start based on.
-		return fmt.Errorf("timed out")
-
-	case targetMember != nil && len(targetMember.Name) == 0 && memberDirExists:
-		// our member has been added to the cluster and has never been started before, but a data directory exists. This means that we have dirty data we must remove
-		fmt.Fprintf(os.Stderr, "Found targetMember but is unstarted and memberDir exists. Archiving memberrDir\n")
-		archiveDataDir(memberDir)
-
-	default:
-		// a target member was found, but no exception circumstances.
-	}
-
-	etcdInitialClusterEntries := []string{}
-	for _, member := range allMembers {
-		if len(member.Name) == 0 { // this is the signal for whether or not a given peer is started
-			continue
-		}
-		for _, peerURL := range member.PeerURLs{
-			etcdInitialClusterEntries = append(etcdInitialClusterEntries, fmt.Sprintf("%s=%s", member.Name, peerURL))
-		}
-	}
-	if len(targetMember.Name) == 0 {
-		fmt.Fprintf(os.Stderr, "Adding the unstarted member to the end %s\n", o.TargetName)
-		etcdInitialClusterEntries = append(etcdInitialClusterEntries, fmt.Sprintf("%s=%s", o.TargetName, targetMember.PeerURLs[0]))
-	}
-
-	fmt.Printf(strings.Join(etcdInitialClusterEntries, ","))
-
-	return nil
-}
-
-// TO DO: instead of archiving, we should remove the directory to avoid any confusion with the backups.
-func archiveDataDir(sourceDir string) error {
-	targetDir := filepath.Join(sourceDir + "-removed-archive-" + time.Now().Format("2006-01-02-030405"))
-
-	fmt.Fprintf(os.Stderr, "attempting to archive %s to %s", sourceDir, targetDir)
-	if err := os.Rename(sourceDir, targetDir); err != nil {
-		return err
-	}
-	return nil
-}
-
-func stringifyMember(member *etcdserverpb.Member) string {
-	if member == nil {
-		return "nil"
-	}
-
-	return fmt.Sprintf("{name=%q, peerURLs=[%s}, clientURLs=[%s]", member.Name, strings.Join(member.PeerURLs, ","), strings.Join(member.ClientURLs, ","))
-}
-
-func (o *DiscoverEtcdInitialClusterOptions) checkForTarget(client *clientv3.Client) (*etcdserverpb.Member, []*etcdserverpb.Member, error) {
-	ctx, cancel := context.WithTimeout(context.Background(), 1*time.Second)
-	defer cancel()
-
-	memberResponse, err := client.MemberList(ctx)
-	if err != nil {
-		return nil, nil, err
-	}
-
-	var targetMember *etcdserverpb.Member
-	for i := range memberResponse.Members {
-		member := memberResponse.Members[i]
-		for _, peerURL := range member.PeerURLs {
-			if strings.Contains(peerURL, o.TargetPeerURLHost) {
-				targetMember = member
-			}
-		}
-	}
-
-	return targetMember, memberResponse.Members, err
-}
-
-func (o *DiscoverEtcdInitialClusterOptions) getClient() (*clientv3.Client, error) {
-	dialOptions := []grpc.DialOption{
-		grpc.WithBlock(), // block until the underlying connection is up
-	}
-
-	tlsInfo := transport.TLSInfo{
-		CertFile:      o.ClientCertFile,
-		KeyFile:       o.ClientKeyFile,
-		TrustedCAFile: o.CABundleFile,
-	}
-	tlsConfig, err := tlsInfo.ClientConfig()
-	if err != nil {
-		return nil, err
-	}
-
-	cfg := &clientv3.Config{
-		DialOptions: dialOptions,
-		Endpoints:   o.Endpoints,
-		DialTimeout: 15 * time.Second,
-		TLS:         tlsConfig,
-	}
-
-	return clientv3.New(*cfg)
-}
diff --git a/vendor/google.golang.org/grpc/internal/transport/http2_server.go b/vendor/google.golang.org/grpc/internal/transport/http2_server.go
index 4e26f6a1d..83439b562 100644
--- a/vendor/google.golang.org/grpc/internal/transport/http2_server.go
+++ b/vendor/google.golang.org/grpc/internal/transport/http2_server.go
@@ -138,10 +138,7 @@ func newHTTP2Server(conn net.Conn, config *ServerConfig) (_ ServerTransport, err
 	}
 	framer := newFramer(conn, writeBufSize, readBufSize, maxHeaderListSize)
 	// Send initial settings as connection preface to client.
-	isettings := []http2.Setting{{
-		ID:  http2.SettingMaxFrameSize,
-		Val: http2MaxFrameLen,
-	}}
+	var isettings []http2.Setting
 	// TODO(zhaoq): Have a better way to signal "no limit" because 0 is
 	// permitted in the HTTP2 spec.
 	maxStreams := config.MaxStreams
diff --git a/vendor/google.golang.org/grpc/internal/transport/http_util.go b/vendor/google.golang.org/grpc/internal/transport/http_util.go
index 8f5f3349d..9d212867c 100644
--- a/vendor/google.golang.org/grpc/internal/transport/http_util.go
+++ b/vendor/google.golang.org/grpc/internal/transport/http_util.go
@@ -667,7 +667,6 @@ func newFramer(conn net.Conn, writeBufferSize, readBufferSize int, maxHeaderList
 		writer: w,
 		fr:     http2.NewFramer(w, r),
 	}
-	f.fr.SetMaxReadFrameSize(http2MaxFrameLen)
 	// Opt-in to Frame reuse API on framer to reduce garbage.
 	// Frames aren't safe to read from after a subsequent call to ReadFrame.
 	f.fr.SetReuseFrames()
diff --git a/vendor/google.golang.org/grpc/version.go b/vendor/google.golang.org/grpc/version.go
index 588850563..5411a73a2 100644
--- a/vendor/google.golang.org/grpc/version.go
+++ b/vendor/google.golang.org/grpc/version.go
@@ -19,4 +19,4 @@
 package grpc
 
 // Version is the current grpc version.
-const Version = "1.23.1"
+const Version = "1.23.0"

@hexfusion
Copy link
Author

/retest

1 similar comment
@hexfusion
Copy link
Author

/retest

@hexfusion
Copy link
Author

/test e2e-gcp-upgrade

1 similar comment
@hexfusion
Copy link
Author

/test e2e-gcp-upgrade

@openshift-ci-robot
Copy link

@hexfusion: The following test failed, say /retest to rerun all failed tests:

Test name Commit Details Rerun command
ci/prow/e2e-gcp-upgrade 151bb84 link /test e2e-gcp-upgrade

Full PR test history. Your PR dashboard. Please help us cut down on flakes by linking to an open issue when you hit one in your PR.

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. I understand the commands that are listed here.

@hexfusion
Copy link
Author

/test all

@hexfusion hexfusion closed this May 11, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. bugzilla/invalid-bug Indicates that a referenced Bugzilla bug is invalid for the branch this PR is targeting. bugzilla/severity-high Referenced Bugzilla bug's severity is high for the branch this PR is targeting.
Projects
None yet
Development

Successfully merging this pull request may close these issues.