mirror of
				https://gitea.com/Lydanne/buildx.git
				synced 2025-11-04 10:03:42 +08:00 
			
		
		
		
	deps: update buildkit, vendor changes
Signed-off-by: Laura Brehm <laurabrehm@hey.com>
This commit is contained in:
		
							
								
								
									
										15
									
								
								vendor/github.com/moby/buildkit/frontend/gateway/grpcclient/client.go
									
									
									
										generated
									
									
										vendored
									
									
								
							
							
						
						
									
										15
									
								
								vendor/github.com/moby/buildkit/frontend/gateway/grpcclient/client.go
									
									
									
										generated
									
									
										vendored
									
									
								
							@@ -43,8 +43,9 @@ type GrpcClient interface {
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
func New(ctx context.Context, opts map[string]string, session, product string, c pb.LLBBridgeClient, w []client.WorkerInfo) (GrpcClient, error) {
 | 
			
		||||
	pingCtx, pingCancel := context.WithTimeout(ctx, 15*time.Second)
 | 
			
		||||
	defer pingCancel()
 | 
			
		||||
	pingCtx, pingCancel := context.WithCancelCause(ctx)
 | 
			
		||||
	pingCtx, _ = context.WithTimeoutCause(pingCtx, 15*time.Second, errors.WithStack(context.DeadlineExceeded))
 | 
			
		||||
	defer pingCancel(errors.WithStack(context.Canceled))
 | 
			
		||||
	resp, err := c.Ping(pingCtx, &pb.PingRequest{})
 | 
			
		||||
	if err != nil {
 | 
			
		||||
		return nil, err
 | 
			
		||||
@@ -616,7 +617,7 @@ func (b *procMessageForwarder) Close() {
 | 
			
		||||
type messageForwarder struct {
 | 
			
		||||
	client pb.LLBBridgeClient
 | 
			
		||||
	ctx    context.Context
 | 
			
		||||
	cancel func()
 | 
			
		||||
	cancel func(error)
 | 
			
		||||
	eg     *errgroup.Group
 | 
			
		||||
	mu     sync.Mutex
 | 
			
		||||
	pids   map[string]*procMessageForwarder
 | 
			
		||||
@@ -630,7 +631,7 @@ type messageForwarder struct {
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
func newMessageForwarder(ctx context.Context, client pb.LLBBridgeClient) *messageForwarder {
 | 
			
		||||
	ctx, cancel := context.WithCancel(ctx)
 | 
			
		||||
	ctx, cancel := context.WithCancelCause(ctx)
 | 
			
		||||
	eg, ctx := errgroup.WithContext(ctx)
 | 
			
		||||
	return &messageForwarder{
 | 
			
		||||
		client: client,
 | 
			
		||||
@@ -719,7 +720,7 @@ func (m *messageForwarder) Send(msg *pb.ExecMessage) error {
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
func (m *messageForwarder) Release() error {
 | 
			
		||||
	m.cancel()
 | 
			
		||||
	m.cancel(errors.WithStack(context.Canceled))
 | 
			
		||||
	return m.eg.Wait()
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
@@ -949,7 +950,7 @@ func (ctr *container) Start(ctx context.Context, req client.StartRequest) (clien
 | 
			
		||||
				closeDoneOnce.Do(func() {
 | 
			
		||||
					close(done)
 | 
			
		||||
				})
 | 
			
		||||
				return ctx.Err()
 | 
			
		||||
				return context.Cause(ctx)
 | 
			
		||||
			}
 | 
			
		||||
 | 
			
		||||
			if file := msg.GetFile(); file != nil {
 | 
			
		||||
@@ -1145,7 +1146,7 @@ func grpcClientConn(ctx context.Context) (context.Context, *grpc.ClientConn, err
 | 
			
		||||
		return nil, nil, errors.Wrap(err, "failed to create grpc client")
 | 
			
		||||
	}
 | 
			
		||||
 | 
			
		||||
	ctx, cancel := context.WithCancel(ctx)
 | 
			
		||||
	ctx, cancel := context.WithCancelCause(ctx)
 | 
			
		||||
	_ = cancel
 | 
			
		||||
	// go monitorHealth(ctx, cc, cancel)
 | 
			
		||||
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user