health

package
v1.0.1 Latest Latest
Warning

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

Go to latest
Published: Nov 1, 2017 License: MPL-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Service

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

Service struct keeps db object to avoid passing it around

func NewService

func NewService(db *gorm.DB) *Service

NewService returns a new Service instance

func (*Service) Close

func (s *Service) Close()

Close stops any running services

func (*Service) GetRoutes

func (s *Service) GetRoutes() []routes.Route

GetRoutes returns []routes.Route slice for the health service

func (*Service) RegisterRoutes

func (s *Service) RegisterRoutes(router *mux.Router, prefix string)

RegisterRoutes registers route handlers for the health service

type ServiceInterface

type ServiceInterface interface {
	// Exported methods
	GetRoutes() []routes.Route
	RegisterRoutes(router *mux.Router, prefix string)
	Close()
}

ServiceInterface defines exported methods

Jump to

Keyboard shortcuts

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