instance

package
v3.0.0-...-6fc1f16 Latest Latest
Warning

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

Go to latest
Published: Feb 25, 2025 License: Apache-2.0 Imports: 31 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Info

type Info struct {
	ConfigureArgs   map[string]interface{}
	Version         string
	Prefix          string
	ConfPath        string
	ExePath         string
	LoadableModules []string
	DynamicModules  []string
	ProcessID       int32
}

type InstanceUpdates

type InstanceUpdates struct {
	NewInstances     []*mpi.Instance
	UpdatedInstances []*mpi.Instance
	DeletedInstances []*mpi.Instance
}

type InstanceUpdatesMessage

type InstanceUpdatesMessage struct {
	CorrelationID   slog.Attr
	InstanceUpdates InstanceUpdates
}

type InstanceWatcherService

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

func NewInstanceWatcherService

func NewInstanceWatcherService(agentConfig *config.Config) *InstanceWatcherService

func (*InstanceWatcherService) ReparseConfig

func (iw *InstanceWatcherService) ReparseConfig(ctx context.Context, instanceID string)

func (*InstanceWatcherService) ReparseConfigs

func (iw *InstanceWatcherService) ReparseConfigs(ctx context.Context)

func (*InstanceWatcherService) Watch

func (iw *InstanceWatcherService) Watch(
	ctx context.Context,
	instancesChannel chan<- InstanceUpdatesMessage,
	nginxConfigContextChannel chan<- NginxConfigContextMessage,
)

type NginxConfigContextMessage

type NginxConfigContextMessage struct {
	CorrelationID      slog.Attr
	NginxConfigContext *model.NginxConfigContext
}

type NginxConfigParser

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

func NewNginxConfigParser

func NewNginxConfigParser(agentConfig *config.Config) *NginxConfigParser

func (*NginxConfigParser) Parse

func (ncp *NginxConfigParser) Parse(ctx context.Context, instance *mpi.Instance) (*model.NginxConfigContext, error)

func (*NginxConfigParser) SocketClient

func (ncp *NginxConfigParser) SocketClient(socketPath string) http.Client

type NginxProcessParser

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

func NewNginxProcessParser

func NewNginxProcessParser() *NginxProcessParser

func (*NginxProcessParser) Parse

func (npp *NginxProcessParser) Parse(ctx context.Context, processes []*nginxprocess.Process) map[string]*mpi.Instance

cognitive complexity of 16 because of the if statements in the for loop don't think can be avoided due to the need for continue nolint: revive

Directories

Path Synopsis
Code generated by counterfeiter.
Code generated by counterfeiter.

Jump to

Keyboard shortcuts

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