http

package
v0.7.2 Latest Latest
Warning

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

Go to latest
Published: Jan 16, 2025 License: Apache-2.0 Imports: 19 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func New

func New(a i_api.API, config *Config) (i_api.Subsystem, error)

Types

type Config

type Config struct {
	Addr          string            `flag:"addr" desc:"http server address" default:":8001"`
	Auth          map[string]string `flag:"auth" desc:"http basic auth username password pairs"`
	Timeout       time.Duration     `flag:"timeout" desc:"http server graceful shutdown timeout" default:"10s"`
	TaskFrequency time.Duration     `flag:"task-frequency" desc:"default task frequency" default:"1m"`
}

type Http

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

func (*Http) Addr added in v0.7.0

func (h *Http) Addr() string

func (*Http) Kind added in v0.7.0

func (h *Http) Kind() string

func (*Http) Start

func (h *Http) Start(errors chan<- error)

func (*Http) Stop

func (h *Http) Stop() error

func (*Http) String

func (h *Http) String() string

Jump to

Keyboard shortcuts

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