handler

package
v0.0.0-...-32ffdae Latest Latest
Warning

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

Go to latest
Published: Oct 4, 2023 License: GPL-3.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func RouteExists

func RouteExists(engine *gin.Engine, methods []string, path string) bool

Types

type Handler

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

func NewHandler

func NewHandler(db *database.Database, logger *zap.Logger) *Handler

func (*Handler) DeleteAPI

func (h *Handler) DeleteAPI(c *gin.Context)

func (*Handler) GetMetrics

func (h *Handler) GetMetrics(c *gin.Context)

func (*Handler) ListAPIs

func (h *Handler) ListAPIs(c *gin.Context)

func (*Handler) RegisterAPI

func (h *Handler) RegisterAPI(c *gin.Context)

func (*Handler) ServeHTTP

func (h *Handler) ServeHTTP(w http.ResponseWriter, r *http.Request)

func (*Handler) UpdateAPI

func (h *Handler) UpdateAPI(c *gin.Context)

type RouteMetrics

type RouteMetrics struct {
	CallCount     int           `json:"callCount"`
	TotalResponse time.Duration `json:"totalResponse"`
	ServiceURL    string        `json:"serviceURL"`
	Path          string        `json:"path"`
}

Jump to

Keyboard shortcuts

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