code: func NewImpatientStream(conn *grpc.ClientConn, waitTimeout time.Duration) ImpatientStreamCreator {
  	return func() (*ImpatientStream, error) {
  		abc := orderer.NewAtomicBroadcastClient(conn)
  		ctx, cancel := context.WithCancel(context.Background())
  
  		stream, err := abc.Deliver(ctx)
  		if err != nil {
  			cancel()
  			return nil, err
  		}
  
  		once := &sync.Once{}
  		return &ImpatientStream{
  			waitTimeout: waitTimeout,
  			// The stream might be canceled while Close() is being called, but also
  			// while a timeout expires, so ensure it's only called once.
  			cancelFunc: func() {
  				once.Do(cancel)
  			},
  			AtomicBroadcast_DeliverClient: stream,
  		}, nil
  	}
  }
docs: // NewImpatientStream returns a ImpatientStreamCreator that creates impatientStreams.