natsreloader

package
v0.0.0-...-e07045a Latest Latest
Warning

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

Go to latest
Published: May 10, 2024 License: BSD-3-Clause, Apache-2.0 Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Config

type Config struct {
	PidFile       string
	ConfigFiles   []string
	MaxRetries    int
	RetryWaitSecs int
}

Config represents the configuration of the reloader.

type Reloader

type Reloader struct {
	*Config
	// contains filtered or unexported fields
}

Reloader monitors the state from a single server config file and sends signal on updates.

func NewReloader

func NewReloader(config *Config) (*Reloader, error)

NewReloader returns a configured NATS server reloader.

func (*Reloader) Run

func (r *Reloader) Run(ctx context.Context) error

Run starts the main loop.

func (*Reloader) Stop

func (r *Reloader) Stop() error

Stop shutsdown the process.

Jump to

Keyboard shortcuts

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