server

package
v0.0.0-...-29002cc Latest Latest
Warning

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

Go to latest
Published: Mar 10, 2021 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Server

type Server struct {
	Stats
	Instance *echo.Echo
}

Server is a struct which wraps a server instance

func New

func New() *Server

New creates a server instance

func (*Server) Start

func (s *Server) Start()

Start starts the server execution

type Stats

type Stats struct {
	Status
	LastUpTime   time.Time
	LastDownTime time.Time
}

Stats is serve stats data

type Status

type Status int

Status is the server status

const (
	DOWN Status = iota // 0
	UP                 // 1
)

The server status values

func (Status) String

func (s Status) String() string

Jump to

Keyboard shortcuts

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