processmanager

package
v1.2.5 Latest Latest
Warning

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

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

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AddGoPathToDollarPath

func AddGoPathToDollarPath(path string) error

func GetBinaryVersion

func GetBinaryVersion(binaryPath string) (string, error)

func GetHomePath

func GetHomePath() (string, error)

func ReloadDaemon

func ReloadDaemon() error

func StartProcess

func StartProcess(process string) error

func ValidateMismatch

func ValidateMismatch(incoming *protocoltypes.Version, current string) bool

Types

type KeyRingPassword

type KeyRingPassword struct {
	Password   bool   // whether the password is required
	Passphrase string // the password
}

type ProtocolBinaryFetcher

type ProtocolBinaryFetcher struct {
	CurrentRunningVersion string
	AutoDownload          bool
	// contains filtered or unexported fields
}

func (*ProtocolBinaryFetcher) FetchProtocolBinary

func (pbf *ProtocolBinaryFetcher) FetchProtocolBinary(protocolConsensusVersion *protocoltypes.Version) (selectedBinaryPath string, err error)

func (*ProtocolBinaryFetcher) SetCurrentRunningVersion

func (pbf *ProtocolBinaryFetcher) SetCurrentRunningVersion(currentVersion string)

func (*ProtocolBinaryFetcher) SetupLavavisorDir

func (pbf *ProtocolBinaryFetcher) SetupLavavisorDir(dir string) error

func (*ProtocolBinaryFetcher) ValidateLavavisorDir

func (pbf *ProtocolBinaryFetcher) ValidateLavavisorDir(dir string) (lavavisorPath string, err error)

func (*ProtocolBinaryFetcher) VerifyGoInstallation

func (pbf *ProtocolBinaryFetcher) VerifyGoInstallation() (string, error)

type ProtocolBinaryFetcherInf

type ProtocolBinaryFetcherInf interface {
	SetCurrentRunningVersion(currentVersion string)
	FetchProtocolBinary(protocolConsensusVersion *protocoltypes.Version) (selectedBinaryPath string, err error)
}

type ProtocolBinaryFetcherWithoutBuild

type ProtocolBinaryFetcherWithoutBuild struct {
	CurrentRunningVersion string
	// contains filtered or unexported fields
}

func (*ProtocolBinaryFetcherWithoutBuild) FetchProtocolBinary

func (pbf *ProtocolBinaryFetcherWithoutBuild) FetchProtocolBinary(protocolConsensusVersion *protocoltypes.Version) (selectedBinaryPath string, err error)

func (*ProtocolBinaryFetcherWithoutBuild) SetCurrentRunningVersion

func (pbf *ProtocolBinaryFetcherWithoutBuild) SetCurrentRunningVersion(currentVersion string)

func (*ProtocolBinaryFetcherWithoutBuild) SetupLavavisorDir

func (pbf *ProtocolBinaryFetcherWithoutBuild) SetupLavavisorDir(dir string) error

func (*ProtocolBinaryFetcherWithoutBuild) ValidateLavavisorDir

func (pbf *ProtocolBinaryFetcherWithoutBuild) ValidateLavavisorDir(dir string) (lavavisorPath string, err error)

type ProtocolBinaryLinker

type ProtocolBinaryLinker struct {
	Fetcher *ProtocolBinaryFetcher
}
func (pbl *ProtocolBinaryLinker) CreateLink(binaryPath string) error

func (*ProtocolBinaryLinker) FindLavaProtocolPath

func (pbl *ProtocolBinaryLinker) FindLavaProtocolPath(binaryPath string) (string, error)

type VersionMonitor

type VersionMonitor struct {
	BinaryPath    string
	LavavisorPath string

	LaunchedServices bool // indicates whether version was matching or not so we can decide wether to launch services
	// contains filtered or unexported fields
}

func NewVersionMonitor

func NewVersionMonitor(initVersion string, lavavisorPath string, processes []string, autoDownload bool) *VersionMonitor

func NewVersionMonitorProcessPodFlow

func NewVersionMonitorProcessPodFlow(initVersion string, lavavisorPath string, command string) *VersionMonitor

func NewVersionMonitorProcessWrapFlow

func NewVersionMonitorProcessWrapFlow(initVersion string, lavavisorPath string, autoDownload bool, command string) *VersionMonitor

func (*VersionMonitor) StartProcess

func (vm *VersionMonitor) StartProcess(keyringPassword *KeyRingPassword)

func (*VersionMonitor) StopSubprocess

func (vm *VersionMonitor) StopSubprocess()

func (*VersionMonitor) TriggerRestartProcess

func (vm *VersionMonitor) TriggerRestartProcess() error

create a link for lavap from the binary path and restart the services

func (*VersionMonitor) ValidateProtocolVersion

func (vm *VersionMonitor) ValidateProtocolVersion(incoming *updaters.ProtocolVersionResponse) error

Jump to

Keyboard shortcuts

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