httpserver

package
v0.0.1 Latest Latest
Warning

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

Go to latest
Published: Jan 4, 2026 License: MIT Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func InitBaseRouter

func InitBaseRouter(handler *echo.Echo, aCfg any, aVer any)

Types

type BaseRoutes

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

type HTTP

type HTTP struct {
	Cors struct {
		Headers []string `yaml:"headers" json:"headers" validate:"required"`
		Methods []string `yaml:"methods" json:"methods" validate:"required"`
		Origins []string `yaml:"origins" json:"origins" validate:"required"`
	} `yaml:"cors" json:"cors"`
	Port     string `yaml:"port" json:"port"`
	Timeouts struct {
		Read     time.Duration `yaml:"read" json:"read"`
		Write    time.Duration `yaml:"write" json:"write"`
		Idle     time.Duration `yaml:"idle" json:"idle"`
		Shutdown time.Duration `yaml:"shutdown" json:"shutdown"`
	} `yaml:"timeouts" json:"timeouts"`
}

type Health

type Health struct {
	Status string
}

type Server

type Server struct {
	Handler *echo.Echo
	// contains filtered or unexported fields
}

func New

func New(c context.Context, log *svclogger.Log, opts *HTTP) *Server

New -.

func (*Server) Notify

func (s *Server) Notify() <-chan error

Notify -.

func (*Server) Shutdown

func (s *Server) Shutdown(shutdownTimeout time.Duration) error

Shutdown -.

Jump to

Keyboard shortcuts

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