auth

package
v0.2.13 Latest Latest
Warning

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

Go to latest
Published: May 6, 2026 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Overview

Package auth provides shared authentication helpers for the adaptive telemetry provider. It is a separate package to avoid import cycles between the parent adaptive package (which imports signal subpackages) and the signal subpackages (which need auth helpers).

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ExtractSignalInfo

func ExtractSignalInfo(stack cloud.StackInfo, signal string) (string, int, error)

ExtractSignalInfo maps a signal name to the corresponding StackInfo fields.

Types

type SignalAuth

type SignalAuth struct {
	BaseURL    string
	TenantID   int
	APIToken   string
	HTTPClient *http.Client
}

SignalAuth holds resolved auth credentials for a single adaptive telemetry signal.

func ResolveSignalAuth

func ResolveSignalAuth(ctx context.Context, loader *providers.ConfigLoader, signal string) (SignalAuth, error)

ResolveSignalAuth resolves auth credentials for the given signal ("metrics", "logs", or "traces"). It checks cached provider config first, falling back to a GCOM lookup via LoadCloudConfig. On GCOM lookup, it caches the resolved values for subsequent calls.

Jump to

Keyboard shortcuts

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