MCPcopy Create free account
hub / github.com/PostHog/duckgres / HealthCheckLoop

Method HealthCheckLoop

controlplane/worker_pool.go:83–83  ·  view source on GitHub ↗

HealthCheckLoop runs periodic health checks on all workers. onCrash is called when a worker crash is detected. onProgress is called with per-session progress data after each successful check. Either callback may be nil.

(ctx context.Context, interval time.Duration, onCrash WorkerCrashHandler, onProgress ProgressHandler)

Source from the content-addressed store, hash-verified

81 // onProgress is called with per-session progress data after each successful check.
82 // Either callback may be nil.
83 HealthCheckLoop(ctx context.Context, interval time.Duration, onCrash WorkerCrashHandler, onProgress ProgressHandler)
84
85 // SetMaxWorkers updates the maximum number of workers. 0 means unlimited.
86 SetMaxWorkers(n int)

Implementers 10

recordingOrgRouterPoolcontrolplane/org_router_test.go
recordingFloorConfigPoolcontrolplane/org_router_test.go
K8sWorkerPoolcontrolplane/k8s_pool.go
OrgReservedPoolcontrolplane/org_reserved_pool.go
recordingWorkerPoolcontrolplane/session_mgr_drain_test.go
blockingReleaseWorkerPoolcontrolplane/session_mgr_drain_test.go
blockingCreateSessionPoolcontrolplane/session_mgr_drain_test.go
cancelAwareWorkerPoolcontrolplane/session_mgr_drain_test.go
FlightWorkerPoolcontrolplane/worker_mgr.go
acquireErrorPoolcontrolplane/session_mgr_test.go

Calls

no outgoing calls