events

package
v1.0.0 Latest Latest
Warning

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

Go to latest
Published: Jun 13, 2026 License: MIT Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var GlobalEventBus = NewEventBus()

GlobalEventBus is the shared event stream used by the agent.

Functions

This section is empty.

Types

type DeploymentEvent

type DeploymentEvent struct {
	Type                 string    `json:"type"`
	Deployment           string    `json:"deployment"`
	Step                 string    `json:"step"`
	Message              string    `json:"message"`
	Timestamp            time.Time `json:"timestamp"`
	DurationMilliseconds int64     `json:"duration_milliseconds,omitempty"`
	JobID                string    `json:"job_id,omitempty"`
}

DeploymentEvent represents a real-time deployment lifecycle event.

type EventBus

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

EventBus provides a simple in-memory publish/subscribe event system.

Later this becomes: - websocket streaming - dashboard updates - slack notifications - persistent event history

func NewEventBus

func NewEventBus() *EventBus

NewEventBus creates a new event bus instance.

func (*EventBus) Publish

func (b *EventBus) Publish(
	event DeploymentEvent,
)

Publish sends an event to all subscribers.

func (*EventBus) Subscribe

func (b *EventBus) Subscribe() chan DeploymentEvent

Subscribe registers a new event listener

Jump to

Keyboard shortcuts

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