services

package
v0.0.0-...-a5a14f1 Latest Latest
Warning

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

Go to latest
Published: Jan 3, 2026 License: MIT Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func RegisterService

func RegisterService(s Service)

func StartAll

func StartAll()

StartAll 启动所有服务

func StopAll

func StopAll(ctx context.Context)

StopAll 停止所有服务(需要 context)

Types

type CronService

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

func NewCronService

func NewCronService() *CronService

func (*CronService) Start

func (s *CronService) Start()

func (*CronService) Stop

func (s *CronService) Stop(ctx context.Context)

type GRPCService

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

func NewGRPCService

func NewGRPCService() *GRPCService

func (*GRPCService) Start

func (s *GRPCService) Start()

func (*GRPCService) Stop

func (s *GRPCService) Stop(ctx context.Context)

type HTTPService

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

func NewHTTPService

func NewHTTPService() *HTTPService

func (*HTTPService) Start

func (s *HTTPService) Start()

func (*HTTPService) Stop

func (s *HTTPService) Stop(ctx context.Context)

type Service

type Service interface {
	Start()
	Stop(ctx context.Context)
}

Jump to

Keyboard shortcuts

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