worker

package
v0.0.0-...-a6e60e5 Latest Latest
Warning

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

Go to latest
Published: Mar 20, 2024 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ListenAndServe

func ListenAndServe(log *slog.Logger, bindAddress string, tlsConfig api.TLSConfig, service *CapacityService) error

func Serve

func Serve(log *slog.Logger, tlsConfig api.TLSConfig, listener net.Listener, service *CapacityService) error

Types

type CapacityService

type CapacityService struct {
	Log *slog.Logger
	// contains filtered or unexported fields
}

func New

func New() *CapacityService

func (*CapacityService) AddRemaining

func (s *CapacityService) AddRemaining(value int32)

func (*CapacityService) GetCapacity

func (s *CapacityService) GetCapacity() int32

func (*CapacityService) GetRemaining

func (s *CapacityService) GetRemaining() int32

func (*CapacityService) Monitor

func (*CapacityService) SetCapacity

func (s *CapacityService) SetCapacity(value int32)

func (*CapacityService) SetRemaining

func (s *CapacityService) SetRemaining(value int32)

Jump to

Keyboard shortcuts

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