server

package
v2.2.1 Latest Latest
Warning

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

Go to latest
Published: Mar 21, 2024 License: MIT Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ReportsStore

type ReportsStore interface {
	Get(string) (*tabulator.Tabulator, error)
	Keys() []string
}

type Server

type Server struct {
	JSONServer *gjson.Server
	Handlers   map[string]gjson.Handler
	// contains filtered or unexported fields
}

Server groups Grafana JSON API handlers that retrieve Belgium COVID-19-related statistics

func New

func New(reportsStore ReportsStore, metrics gjson.PrometheusQueryMetrics, logger *slog.Logger) *Server

func (*Server) Health

func (s *Server) Health(w http.ResponseWriter, _ *http.Request)

func (*Server) Run

func (s *Server) Run(ctx context.Context) error

Run starts the supporting components

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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