worker

package
v0.1.2 Latest Latest
Warning

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

Go to latest
Published: Feb 18, 2026 License: MIT Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type BridgeDispatcher

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

func NewBridgeDispatcher

func NewBridgeDispatcher() BridgeDispatcher

NewBridgeDispatcher creates a new worker.BridgeDispatcher (different from impl.BridgeDispatcher) which is currently only used in the connector. The reason is to experiment with a simplifying wrapper layer over the existing implementation.

func (*BridgeDispatcher) RegisterBridge

func (b *BridgeDispatcher) RegisterBridge(bridge api.Bridge)

RegisterBridge registers a bridge with the dispatcher. It is simpler and more clear than the existing RegisterWorker method on impl.BridgeDispatcher.

type ConfighubConnector

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

func NewConnector

func NewConnector(opts ConnectorOptions) (*ConfighubConnector, error)

NewConnector creates a new ConfighubConnector. WorkerID and WorkerSecret are required. The rest of the configuration is loaded from ConfigHub after the worker connects.

func (*ConfighubConnector) Start

func (c *ConfighubConnector) Start() error

Start starts the worker. It opens a persistent connection to ConfigHub and starts performing work based on its configuration.

type ConnectorOptions

type ConnectorOptions struct {
	WorkerID         string
	WorkerSecret     string
	ConfigHubURL     string
	FunctionExecutor *function.FunctionExecutor
	BridgeDispatcher *BridgeDispatcher
}

type FunctionWorkerAdapter

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

func (*FunctionWorkerAdapter) Info

type NullBridgeWorker

type NullBridgeWorker struct{}

func (*NullBridgeWorker) Apply

func (*NullBridgeWorker) Destroy

func (*NullBridgeWorker) Finalize

func (*NullBridgeWorker) ID added in v0.1.1

func (*NullBridgeWorker) Import

func (*NullBridgeWorker) Info

func (*NullBridgeWorker) Refresh

Jump to

Keyboard shortcuts

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