router

package
v0.0.0-...-d4ca7bd Latest Latest
Warning

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

Go to latest
Published: Mar 29, 2022 License: MIT Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetMonitoredURLs

func GetMonitoredURLs() []string

GetMonitoredURLs will return the list of URLs to be monitored

func HealthCheck

func HealthCheck(w http.ResponseWriter, r *http.Request)

HealthCheck is the health check handler

func ListMonitoredRoutes

func ListMonitoredRoutes(w http.ResponseWriter, r *http.Request)

ListMonitoredRoutes will fetch the list of monitored routes

func New

func New() *mux.Router

New will configure the routes

Types

type MonitoredRoutesResponse

type MonitoredRoutesResponse struct {
	URLs []string `json:"urls"`
}

type MonitoredURLConfig

type MonitoredURLConfig struct {
	Path                string
	HealthCheckDuration time.Duration
}

MonitoredURLConfig represents the health check configuration per monitored URL

func GetMonitoredURLsConfig

func GetMonitoredURLsConfig() []MonitoredURLConfig

GetMonitoredURLsConfig will return the configuration per URL

Jump to

Keyboard shortcuts

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