host

package
v0.0.0-...-69805f1 Latest Latest
Warning

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

Go to latest
Published: Dec 11, 2024 License: MIT Imports: 21 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type APIConfig

type APIConfig struct {
	Vendors []vendors.VendorConfig `json:"vendors"`
	PubSub  PubSubConfig           `json:"pubsub,omitempty"`
	KeyLock KeyLockConfig          `json:"keylock,omitempty"`
}

type APIHost

type APIHost struct {
	Vendors               []VendorSpec
	Bindings              []bindings.IBinding
	SharedPubSubProvider  pv.IProvider
	SharedKeyLockProvider pv.IProvider
	ShutdownGracePeriod   time.Duration
}

func (*APIHost) Launch

func (h *APIHost) Launch(config HostConfig,
	vendorFactories []vendors.IVendorFactory,
	managerFactories []mf.IManagerFactroy,
	providerFactories []pf.IProviderFactory, wait bool) error

func (*APIHost) WaitForShutdown

func (h *APIHost) WaitForShutdown(wg *sync.WaitGroup, cancel context.CancelFunc) error

type BindingConfig

type BindingConfig struct {
	Type   string      `json:"type"`
	Config interface{} `json:"config"`
}

type HostConfig

type HostConfig struct {
	SiteInfo            v1alpha2.SiteInfo `json:"siteInfo"`
	API                 APIConfig         `json:"api"`
	Bindings            []BindingConfig   `json:"bindings"`
	ShutdownGracePeriod string            `json:"shutdownGracePeriod"`
}

type KeyLockConfig

type KeyLockConfig struct {
	Shared   bool                 `json:"shared"`
	Provider PublicProviderConfig `json:"provider"`
}

type KeyLockProviderConfig

type KeyLockProviderConfig struct {
	Mode string `json:"mode"`
}

type PubSubConfig

type PubSubConfig struct {
	Shared   bool              `json:"shared"`
	Provider mf.ProviderConfig `json:"provider"`
}

type PublicProviderConfig

type PublicProviderConfig struct {
	Type   string                `json:"type"`
	Config KeyLockProviderConfig `json:"config"`
}

type VendorSpec

type VendorSpec struct {
	Vendor       vendors.IVendor
	LoopInterval int
}

Jump to

Keyboard shortcuts

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