controllers

package
v0.0.0-...-e5be028 Latest Latest
Warning

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

Go to latest
Published: Dec 11, 2024 License: GPL-3.0 Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type StatusCheck

type StatusCheck func() (name string, msg string, err error)

TODO: app info things like uptime TODO: add metrics endpoint https://github.com/gin-contrib/expvar TODO: expose function to add StatusCheck and loop through them TODO: common status checks: db connectivity, db exists, tables exist, internet, twilio, aws resources. TODO: errors endpoint returning 500 / commons for stimulating / testing - should return example error body structures with metadata TODO: status websocket for connectivity checks

type StatusController

type StatusController struct {
}

func NewStatusController

func NewStatusController() *StatusController

func (*StatusController) Register

func (c *StatusController) Register(service *gin.RouterGroup)

func (*StatusController) Status

func (*StatusController) Status(ctx *gin.Context)

Status - an unauthenticated endpoint to verify the api is running @Summary returns a status message @Description returns a status message @Tags status @Accept json @Produce json @Success 200 {string} string "" @Router /status/ [get]

Jump to

Keyboard shortcuts

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