router

package
v0.0.0-...-f87157e Latest Latest
Warning

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

Go to latest
Published: Nov 8, 2019 License: GPL-3.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func App

func App(debug bool, name string) *echo.Echo

App creates new instance of Echo and configures it

func NewMetricWithConfig

func NewMetricWithConfig(config PrometheusConfig) echo.MiddlewareFunc

NewMetricWithConfig creates a new prometheus with config

func NewPrometheusMiddleware

func NewPrometheusMiddleware(namespace string) echo.MiddlewareFunc

NewPrometheusMiddleware returns new prometheus exporter with default config

Types

type DefaultValidator

type DefaultValidator struct {
	// contains filtered or unexported fields
}

DefaultValidator contains go-playground validator instance

func (*DefaultValidator) Validate

func (cv *DefaultValidator) Validate(i interface{}) error

Validate validates structs based on go-playground validator

type EchoMetrics

type EchoMetrics struct {
	// contains filtered or unexported fields
}

EchoMetrics represents prometheus metrics for echo

func NewEchoMetrics

func NewEchoMetrics(namespace string) EchoMetrics

NewEchoMetrics creates and registers echo metrics. This function will panic on multiple call.

type PrometheusConfig

type PrometheusConfig struct {
	// Skipper echo skipper
	Skipper   middleware.Skipper
	Namespace string
}

PrometheusConfig represents basic prometheus exporter

Jump to

Keyboard shortcuts

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