Documentation ¶
Index ¶
- Constants
- func ReadMetrics(ctx context.Context, logger *slog.Logger, connectionInfo *pipe.SSHClientInfo) (io.Reader, error)
- func ReconnectReadMetrics(ctx context.Context, logger *slog.Logger, connectionInfo *pipe.SSHClientInfo, ...) io.Reader
- func RegisterReconnectMetricRecorder(ctx context.Context, logger *slog.Logger, info *pipe.SSHClientInfo, buffer int, ...) io.Writer
Constants ¶
View Source
const ( ID = "metrics" Topic = "metric-drain" PubCommand = "pub " + Topic + " -b=false" SubCommand = "sub " + Topic + " -k" )
Variables ¶
This section is empty.
Functions ¶
func ReadMetrics ¶
func ReadMetrics(ctx context.Context, logger *slog.Logger, connectionInfo *pipe.SSHClientInfo) (io.Reader, error)
ReadLogs reads metrics from a metric drain.
func ReconnectReadMetrics ¶
func ReconnectReadMetrics(ctx context.Context, logger *slog.Logger, connectionInfo *pipe.SSHClientInfo, buffer int, timeout time.Duration) io.Reader
ReconnectReadMetrics reads metrics from a remote metric drain and reconnects even if the initial connection fails.
func RegisterReconnectMetricRecorder ¶
func RegisterReconnectMetricRecorder(ctx context.Context, logger *slog.Logger, info *pipe.SSHClientInfo, buffer int, timeout time.Duration) io.Writer
RegisterReconnectMetricRecorder registers a logger that forwards log records to a remote log drain and reconnects even if the initial connection fails.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.