Documentation
¶
Index ¶
- Constants
- type ConnectorConfig
- type HubConfig
- type OperatorConfig
- type OperatorConfigManager
- func (o *OperatorConfigManager) GetConfig() *OperatorConfig
- func (o *OperatorConfigManager) LoadInitial(ctx context.Context) error
- func (o *OperatorConfigManager) Reconcile(ctx context.Context, req reconcile.Request) (reconcile.Result, error)
- func (o *OperatorConfigManager) SetAPIReader(reader client.Reader)
- func (o *OperatorConfigManager) SetupWithManager(mgr ctrl.Manager) error
- type TelemetryConfig
- type TemplatingConfig
Constants ¶
const (
// DefaultConnectorImage is the canonical image reference for connector sidecars.
DefaultConnectorImage = "ghcr.io/bubustack/bobravoz-grpc-connector:latest"
)
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ConnectorConfig ¶
type ConnectorConfig struct {
Image string `json:"image,omitempty"`
ImagePullPolicy corev1.PullPolicy `json:"imagePullPolicy,omitempty"`
}
ConnectorConfig captures injector defaults for the transport connector.
type HubConfig ¶
type HubConfig struct {
// SecurityMode selects the transport security model; only "tls" is supported.
SecurityMode string `json:"securityMode,omitempty"`
// BufferMaxMessages is the maximum number of messages retained per stream buffer (> 0).
BufferMaxMessages int `json:"bufferMaxMessages,omitempty"`
// BufferMaxBytes is the maximum total bytes retained per stream buffer (> 0).
BufferMaxBytes int `json:"bufferMaxBytes,omitempty"`
// BufferEvictionTTL is how long idle buffer entries are kept before eviction (> 0).
BufferEvictionTTL time.Duration `json:"bufferEvictionTTL,omitempty"`
// BufferEvictionPeriod is the interval between buffer eviction sweeps (> 0).
BufferEvictionPeriod time.Duration `json:"bufferEvictionPeriod,omitempty"`
// ChannelBufferSize is the capacity of per-stream send channels (> 0).
ChannelBufferSize int `json:"channelBufferSize,omitempty"`
// PerMessageTimeout is the maximum time allowed for sending a single message (> 0).
PerMessageTimeout time.Duration `json:"perMessageTimeout,omitempty"`
// MaxActiveStreams is the upper limit on concurrent hub streams (> 0).
MaxActiveStreams int `json:"maxActiveStreams,omitempty"`
// MaxBuffers is the maximum number of stream buffers the hub will allocate (> 0).
MaxBuffers int `json:"maxBuffers,omitempty"`
// MaxDownstreamsHardCap is the absolute maximum downstream subscribers per stream (1-256).
MaxDownstreamsHardCap int `json:"maxDownstreamsHardCap,omitempty"`
}
HubConfig captures hub-specific toggles.
type OperatorConfig ¶
type OperatorConfig struct {
Hub HubConfig `json:"hub,omitempty"`
Telemetry TelemetryConfig `json:"telemetry,omitempty"`
Templating TemplatingConfig `json:"templating,omitempty"`
Connector ConnectorConfig `json:"connector,omitempty"`
}
OperatorConfig represents the runtime configuration for the bobravoz-grpc controller.
func DefaultOperatorConfig ¶
func DefaultOperatorConfig() *OperatorConfig
DefaultOperatorConfig returns the default configuration used when the ConfigMap is absent.
func (*OperatorConfig) Clone ¶
func (cfg *OperatorConfig) Clone() *OperatorConfig
Clone returns a deep copy of the OperatorConfig.
type OperatorConfigManager ¶
type OperatorConfigManager struct {
// contains filtered or unexported fields
}
OperatorConfigManager watches a ConfigMap and keeps an in-memory copy of the configuration.
func NewOperatorConfigManager ¶
func NewOperatorConfigManager(k8sClient client.Client, namespace, configMapName string) (*OperatorConfigManager, error)
NewOperatorConfigManager creates a new manager instance. Returns an error if the underlying config manager cannot be initialised (e.g. invalid client).
func (*OperatorConfigManager) GetConfig ¶
func (o *OperatorConfigManager) GetConfig() *OperatorConfig
GetConfig returns the current configuration snapshot.
func (*OperatorConfigManager) LoadInitial ¶
func (o *OperatorConfigManager) LoadInitial(ctx context.Context) error
LoadInitial performs a synchronous load of the configuration ConfigMap.
func (*OperatorConfigManager) Reconcile ¶
func (o *OperatorConfigManager) Reconcile(ctx context.Context, req reconcile.Request) (reconcile.Result, error)
Reconcile reacts to ConfigMap changes and refreshes the cached configuration.
func (*OperatorConfigManager) SetAPIReader ¶
func (o *OperatorConfigManager) SetAPIReader(reader client.Reader)
SetAPIReader injects a non-cached reader for startup loads before the cache is ready.
func (*OperatorConfigManager) SetupWithManager ¶
func (o *OperatorConfigManager) SetupWithManager(mgr ctrl.Manager) error
SetupWithManager registers the manager as a controller so config updates are tracked.
type TelemetryConfig ¶
type TelemetryConfig struct {
TracePropagation bool `json:"tracePropagation,omitempty"`
}
TelemetryConfig captures OpenTelemetry-related toggles.
type TemplatingConfig ¶
type TemplatingConfig struct {
EvaluationTimeout time.Duration `json:"evaluationTimeout,omitempty"`
MaxOutputBytes int `json:"maxOutputBytes,omitempty"`
Deterministic bool `json:"deterministic,omitempty"`
OffloadedPolicy string `json:"offloadedPolicy,omitempty"`
MaterializeEngram string `json:"materializeEngram,omitempty"`
}
TemplatingConfig captures template evaluation tunables for realtime routing.