Versions in this module Expand all Collapse all v0 v0.11.0 Sep 11, 2026 Changes in this version + const ConfigMapDataKey + const ConfigMapPrefix + const LabelDeveloper + const LabelManagedBy + const LabelManagedByVal + const LabelService + const LabelSessionID + const StaleSessionDuration + var ErrConflict = errors.New("dev session conflict detected") + var ErrSessionNotFound = errors.New("dev session not found") + func ConfigMapNameForService(service string) string + func DetectHostname() string + type ConflictError struct + CurrentDeveloper string + ExistingSession DevSession + Service string + func (e *ConflictError) Error() string + func (e *ConflictError) FormatWarning(policy ConflictPolicy) string + type ConflictPolicy string + const ConflictPolicyAllow + const ConflictPolicyBlock + const ConflictPolicyWarn + type DevSession struct + Branch string + Developer string + GroupName string + Heartbeat time.Time + Hostname string + ID string + Namespace string + PID int + PreviewID string + Service string + StartedAt time.Time + func (s DevSession) IsStale(now time.Time) bool + type K8sSessionManager struct + func NewSessionManager(c client.Client) *K8sSessionManager + func (m *K8sSessionManager) Acquire(ctx context.Context, session DevSession, policy ConflictPolicy, force bool) (*DevSession, bool, error) + func (m *K8sSessionManager) Heartbeat(ctx context.Context, namespace, service, sessionID string) error + func (m *K8sSessionManager) List(ctx context.Context, namespace string) ([]DevSession, error) + func (m *K8sSessionManager) Release(ctx context.Context, namespace, service, sessionID string) error + type Manager interface + Acquire func(ctx context.Context, session DevSession, policy ConflictPolicy, force bool) (*DevSession, bool, error) + Heartbeat func(ctx context.Context, namespace, service, sessionID string) error + List func(ctx context.Context, namespace string) ([]DevSession, error) + Release func(ctx context.Context, namespace, service, sessionID string) error