[18.09] Vendor swarmkit to 6186e40fb04a7681e25a9101dbc7418c37ef0c8b

Signed-off-by: Anshul Pundir <anshul.pundir@docker.com>
Upstream-commit: 46dfcd83bf1bb820840df91629c04c47b32d1e21
Component: engine
This commit is contained in:
Anshul Pundir
2018-10-31 16:04:51 -07:00
parent a659f7a44e
commit ccef7c659b
2 changed files with 11 additions and 1 deletions
@@ -4,6 +4,7 @@ package transport
import (
"context"
"math"
"net"
"sync"
"time"
@@ -354,6 +355,15 @@ func (t *Transport) dial(addr string) (*grpc.ClientConn, error) {
return net.DialTimeout("tcp", addr, timeout)
}))
// TODO(dperny): this changes the max received message size for outgoing
// client connections. this means if the server sends a message larger than
// this, we will still accept and unmarshal it. i'm unsure what the
// potential consequences are of setting this to be effectively unbounded,
// so after docker/swarmkit#2774 is fixed, we should remove this option
grpcOptions = append(grpcOptions, grpc.WithDefaultCallOptions(
grpc.MaxCallRecvMsgSize(math.MaxInt32),
))
cc, err := grpc.Dial(addr, grpcOptions...)
if err != nil {
return nil, err