Versions in this module Expand all Collapse all v0 v0.1.0 Aug 10, 2026 Changes in this version + var ErrConnectionClosed = errors.New("monolock: connection closed") + var ErrHeartbeatTimeout = errors.New("monolock: heartbeat confirmation timeout") + var ErrProtocolViolation = errors.New("monolock: protocol violation") + type Client struct + func New(cfg Config) *Client + func (c *Client) Do(ctx context.Context, lockName string, lease time.Duration, ...) error + func (c *Client) DoRetry(ctx context.Context, lockName string, lease time.Duration, ...) error + type Config struct + Address string + Dialer ContextDialer + type ContextDialer interface + DialContext func(ctx context.Context, network, address string) (net.Conn, error) + type ServerError struct + Code uint8 + Reason string + func (e *ServerError) Error() string + func (e *ServerError) Temporary() bool + func (e *ServerError) Unwrap() error