mirror of
https://github.com/etcd-io/etcd.git
synced 2024-09-27 06:25:44 +00:00
10
.travis.yml
10
.travis.yml
@@ -6,7 +6,7 @@ sudo: required
|
||||
services: docker
|
||||
|
||||
go:
|
||||
- 1.10.3
|
||||
- 1.11
|
||||
- tip
|
||||
|
||||
notifications:
|
||||
@@ -30,13 +30,13 @@ env:
|
||||
matrix:
|
||||
fast_finish: true
|
||||
allow_failures:
|
||||
- go: 1.10.3
|
||||
- go: 1.11
|
||||
env: TARGET=linux-amd64-grpcproxy
|
||||
- go: 1.10.3
|
||||
- go: 1.11
|
||||
env: TARGET=linux-amd64-coverage
|
||||
- go: tip
|
||||
env: TARGET=linux-amd64-fmt-unit-go-tip
|
||||
- go: 1.10.3
|
||||
- go: 1.11
|
||||
env: TARGET=linux-386-unit
|
||||
exclude:
|
||||
- go: tip
|
||||
@@ -57,7 +57,7 @@ matrix:
|
||||
env: TARGET=linux-amd64-grpcproxy
|
||||
- go: tip
|
||||
env: TARGET=linux-amd64-coverage
|
||||
- go: 1.10.3
|
||||
- go: 1.11
|
||||
env: TARGET=linux-amd64-fmt-unit-go-tip
|
||||
- go: tip
|
||||
env: TARGET=linux-386-unit
|
||||
|
||||
6
Makefile
6
Makefile
@@ -51,7 +51,7 @@ docker-remove:
|
||||
|
||||
|
||||
|
||||
GO_VERSION ?= 1.10.3
|
||||
GO_VERSION ?= 1.11
|
||||
ETCD_VERSION ?= $(shell git rev-parse --short HEAD || echo "GitNotFound")
|
||||
|
||||
TEST_SUFFIX = $(shell date +%s | base64 | head -c 15)
|
||||
@@ -65,11 +65,11 @@ endif
|
||||
|
||||
|
||||
# Example:
|
||||
# GO_VERSION=1.8.7 make build-docker-test
|
||||
# GO_VERSION=1.10.3 make build-docker-test
|
||||
# make build-docker-test
|
||||
#
|
||||
# gcloud docker -- login -u _json_key -p "$(cat /etc/gcp-key-etcd-development.json)" https://gcr.io
|
||||
# GO_VERSION=1.8.7 make push-docker-test
|
||||
# GO_VERSION=1.10.3 make push-docker-test
|
||||
# make push-docker-test
|
||||
#
|
||||
# gsutil -m acl ch -u allUsers:R -r gs://artifacts.etcd-development.appspot.com
|
||||
|
||||
@@ -825,8 +825,11 @@ func TestLeaseWithRequireLeader(t *testing.T) {
|
||||
// kaReqLeader may issue multiple requests while waiting for the first
|
||||
// response from proxy server; drain any stray keepalive responses
|
||||
time.Sleep(100 * time.Millisecond)
|
||||
for len(kaReqLeader) > 0 {
|
||||
for {
|
||||
<-kaReqLeader
|
||||
if len(kaReqLeader) == 0 {
|
||||
break
|
||||
}
|
||||
}
|
||||
|
||||
select {
|
||||
|
||||
@@ -199,7 +199,7 @@ func NewLeaseFromLeaseClient(remote pb.LeaseClient, c *Client, keepAliveTimeout
|
||||
keepAlives: make(map[LeaseID]*keepAlive),
|
||||
remote: remote,
|
||||
firstKeepAliveTimeout: keepAliveTimeout,
|
||||
lg: c.lg,
|
||||
lg: c.lg,
|
||||
}
|
||||
if l.firstKeepAliveTimeout == time.Second {
|
||||
l.firstKeepAliveTimeout = defaultTTL
|
||||
|
||||
@@ -76,12 +76,12 @@ func handleV2(lg *zap.Logger, mux *http.ServeMux, server etcdserver.ServerV2, ti
|
||||
}
|
||||
|
||||
mh := &membersHandler{
|
||||
lg: lg,
|
||||
sec: sec,
|
||||
server: server,
|
||||
cluster: server.Cluster(),
|
||||
timeout: timeout,
|
||||
clock: clockwork.NewRealClock(),
|
||||
lg: lg,
|
||||
sec: sec,
|
||||
server: server,
|
||||
cluster: server.Cluster(),
|
||||
timeout: timeout,
|
||||
clock: clockwork.NewRealClock(),
|
||||
clientCertAuthEnabled: server.ClientCertAuthEnabled(),
|
||||
}
|
||||
|
||||
|
||||
@@ -196,8 +196,8 @@ func TestWALDir(t *testing.T) {
|
||||
|
||||
func TestShouldDiscover(t *testing.T) {
|
||||
tests := map[string]bool{
|
||||
"": false,
|
||||
"foo": true,
|
||||
"": false,
|
||||
"foo": true,
|
||||
"http://discovery.etcd.io/asdf": true,
|
||||
}
|
||||
for durl, w := range tests {
|
||||
|
||||
@@ -64,10 +64,10 @@ func NewServer(
|
||||
address string,
|
||||
) *Server {
|
||||
return &Server{
|
||||
lg: lg,
|
||||
network: network,
|
||||
address: address,
|
||||
last: rpcpb.Operation_NOT_STARTED,
|
||||
lg: lg,
|
||||
network: network,
|
||||
address: address,
|
||||
last: rpcpb.Operation_NOT_STARTED,
|
||||
advertiseClientPortToProxy: make(map[int]proxy.Server),
|
||||
advertisePeerPortToProxy: make(map[int]proxy.Server),
|
||||
}
|
||||
|
||||
@@ -291,8 +291,8 @@ func (c *cluster) mustNewMember(t *testing.T) *member {
|
||||
grpcKeepAliveTimeout: c.cfg.GRPCKeepAliveTimeout,
|
||||
clientMaxCallSendMsgSize: c.cfg.ClientMaxCallSendMsgSize,
|
||||
clientMaxCallRecvMsgSize: c.cfg.ClientMaxCallRecvMsgSize,
|
||||
useIP: c.cfg.UseIP,
|
||||
leaseCheckpointInterval: c.cfg.LeaseCheckpointInterval,
|
||||
useIP: c.cfg.UseIP,
|
||||
leaseCheckpointInterval: c.cfg.LeaseCheckpointInterval,
|
||||
})
|
||||
m.DiscoveryURL = c.cfg.DiscoveryURL
|
||||
if c.cfg.UseGRPC {
|
||||
|
||||
@@ -70,13 +70,13 @@ func CheckAfterTest(d time.Duration) error {
|
||||
}
|
||||
var bad string
|
||||
badSubstring := map[string]string{
|
||||
").writeLoop(": "a Transport",
|
||||
").writeLoop(": "a Transport",
|
||||
"created by net/http/httptest.(*Server).Start": "an httptest.Server",
|
||||
"timeoutHandler": "a TimeoutHandler",
|
||||
"net.(*netFD).connect(": "a timing out dial",
|
||||
").noteClientGone(": "a closenotifier sender",
|
||||
").readLoop(": "a Transport",
|
||||
".grpc": "a gRPC resource",
|
||||
"timeoutHandler": "a TimeoutHandler",
|
||||
"net.(*netFD).connect(": "a timing out dial",
|
||||
").noteClientGone(": "a closenotifier sender",
|
||||
").readLoop(": "a Transport",
|
||||
".grpc": "a gRPC resource",
|
||||
}
|
||||
|
||||
var stacks string
|
||||
|
||||
@@ -175,10 +175,10 @@ func TestRemoveSingleHopHeaders(t *testing.T) {
|
||||
"Keep-Alive": {"foo"},
|
||||
"Proxy-Authenticate": {"Basic realm=example.com"},
|
||||
"Proxy-Authorization": {"foo"},
|
||||
"Te": {"deflate,gzip"},
|
||||
"Trailers": {"ETag"},
|
||||
"Transfer-Encoding": {"chunked"},
|
||||
"Upgrade": {"WebSocket"},
|
||||
"Te": {"deflate,gzip"},
|
||||
"Trailers": {"ETag"},
|
||||
"Transfer-Encoding": {"chunked"},
|
||||
"Upgrade": {"WebSocket"},
|
||||
|
||||
// headers that should persist
|
||||
"Accept": {"application/json"},
|
||||
|
||||
Reference in New Issue
Block a user