initialization

package
v0.4.0 Latest Latest
Warning

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

Go to latest
Published: Feb 8, 2026 License: MIT Imports: 12 Imported by: 0

Documentation

Overview

Package initialization provides centralized component initialization and lifecycle management for the observability plugin. It handles dependency injection, proper startup order, and graceful shutdown of all plugin components including Prometheus clients, security layers, caching systems, and external APIs.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Components

type Components struct {
	Client              *prometheus.Client
	CachedClient        *prometheus.CachedClient
	MetricsCollector    *metrics.Collector
	SecretsManager      *security.SecretsManager
	OverlayMgr          *overlays.OverlayManager
	SubscriptionMgr     *subscription.SubscriptionManager
	NotificationMgr     *subscription.NotificationManager
	Persistence         *subscription.SubscriptionPersistence
	HistoricalCollector *historical.HistoricalDataCollector
	HistoricalAnalyzer  *historical.HistoricalAnalyzer
	EfficiencyAnalyzer  *analysis.ResourceEfficiencyAnalyzer
	ExternalAPI         *endpoints.ExternalAPI
}

Components holds all initialized plugin components

func (*Components) Stop

func (c *Components) Stop() error

Stop gracefully stops all components

type Manager

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

Manager handles plugin component initialization

func NewManager

func NewManager(config *config.Config) *Manager

NewManager creates a new initialization manager

func NewManagerWithContext

func NewManagerWithContext(ctx context.Context, config *config.Config) *Manager

NewManagerWithContext creates a new initialization manager with context

func (*Manager) InitializeComponents

func (m *Manager) InitializeComponents() (*Components, error)

InitializeComponents initializes all plugin components

Jump to

Keyboard shortcuts

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