webapi

package
v1.0.3 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 23, 2026 License: GPL-2.0, GPL-3.0 Imports: 3 Imported by: 0

Documentation

Overview

Package webapi assembles knell's HTTP surface: the beat ingestion endpoint, the health endpoint, and Prometheus metrics, wrapped in the standard middleware stack.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func New

func New(b Beater, healthz, metricsHandler http.Handler) http.Handler

New assembles the routed and middleware-wrapped root handler. healthz answers liveness; metricsHandler serves the Prometheus exposition.

Types

type Beater

type Beater interface {
	// Beat records a ping for id, returning false for unknown ids.
	Beat(id string) bool
}

Beater records pings. Implemented by watch.Watcher.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL