kubernetes/vendor/go.etcd.io/etcd/client/v3/lease.go

type LeaseRevokeResponse

type LeaseID

type LeaseGrantResponse

type LeaseKeepAliveResponse

type LeaseTimeToLiveResponse

type LeaseStatus

type LeaseLeasesResponse

const defaultTTL

const NoLease

const retryConnWait

var LeaseResponseChSize

type ErrKeepAliveHalted

func (e ErrKeepAliveHalted) Error() string {}

type Lease

type lessor

type keepAlive

func NewLease(c *Client) Lease {}

func NewLeaseFromLeaseClient(remote pb.LeaseClient, c *Client, keepAliveTimeout time.Duration) Lease {}

func (l *lessor) Grant(ctx context.Context, ttl int64) (*LeaseGrantResponse, error) {}

func (l *lessor) Revoke(ctx context.Context, id LeaseID) (*LeaseRevokeResponse, error) {}

func (l *lessor) TimeToLive(ctx context.Context, id LeaseID, opts ...LeaseOption) (*LeaseTimeToLiveResponse, error) {}

func (l *lessor) Leases(ctx context.Context) (*LeaseLeasesResponse, error) {}

func (l *lessor) KeepAlive(ctx context.Context, id LeaseID) (<-chan *LeaseKeepAliveResponse, error) {}

func (l *lessor) KeepAliveOnce(ctx context.Context, id LeaseID) (*LeaseKeepAliveResponse, error) {}

func (l *lessor) Close() error {}

func (l *lessor) keepAliveCtxCloser(ctx context.Context, id LeaseID, donec <-chan struct{}

// closeRequireLeader scans keepAlives for ctxs that have require leader
// and closes the associated channels.
func (l *lessor) closeRequireLeader() {}

func (l *lessor) keepAliveOnce(ctx context.Context, id LeaseID) (karesp *LeaseKeepAliveResponse, ferr error) {}

func (l *lessor) recvKeepAliveLoop() (gerr error) {}

// resetRecv opens a new lease stream and starts sending keep alive requests.
func (l *lessor) resetRecv() (pb.Lease_LeaseKeepAliveClient, error) {}

// recvKeepAlive updates a lease based on its LeaseKeepAliveResponse
func (l *lessor) recvKeepAlive(resp *pb.LeaseKeepAliveResponse) {}

// deadlineLoop reaps any keep alive channels that have not received a response
// within the lease TTL
func (l *lessor) deadlineLoop() {}

// sendKeepAliveLoop sends keep alive requests for the lifetime of the given stream.
func (l *lessor) sendKeepAliveLoop(stream pb.Lease_LeaseKeepAliveClient) {}

func (ka *keepAlive) close() {}