diff --git a/cmd/rds-agent/agent.go b/cmd/rds-agent/agent.go index f0eeb212f..32b2ee8bc 100644 --- a/cmd/rds-agent/agent.go +++ b/cmd/rds-agent/agent.go @@ -15,7 +15,7 @@ import ( "github.com/mulgadc/spinifex/internal/gwsign" "github.com/mulgadc/spinifex/internal/rdsgw" handlers_rds "github.com/mulgadc/spinifex/spinifex/handlers/rds" - "github.com/mulgadc/spinifex/spinifex/otelsetup" + "github.com/mulgadc/spinifex/spinifex/foundation/telemetry" ) // Overridable via -ldflags "-X main.version=...". diff --git a/cmd/rds-agent/paramrecovery.go b/cmd/rds-agent/paramrecovery.go index d19ce85f3..c6ee08d67 100644 --- a/cmd/rds-agent/paramrecovery.go +++ b/cmd/rds-agent/paramrecovery.go @@ -2,7 +2,7 @@ package main import ( "context" - "github.com/mulgadc/spinifex/spinifex/otelsetup" + "github.com/mulgadc/spinifex/spinifex/foundation/telemetry" "log/slog" "time" diff --git a/cmd/rds-agent/quiesce.go b/cmd/rds-agent/quiesce.go index c1b6791aa..7ec215eeb 100644 --- a/cmd/rds-agent/quiesce.go +++ b/cmd/rds-agent/quiesce.go @@ -6,7 +6,7 @@ import ( "context" "errors" "fmt" - "github.com/mulgadc/spinifex/spinifex/otelsetup" + "github.com/mulgadc/spinifex/spinifex/foundation/telemetry" "io" "log/slog" "os/exec" diff --git a/cmd/rds-agent/register.go b/cmd/rds-agent/register.go index e6f7f8871..3b7536702 100644 --- a/cmd/rds-agent/register.go +++ b/cmd/rds-agent/register.go @@ -2,7 +2,7 @@ package main import ( "context" - "github.com/mulgadc/spinifex/spinifex/otelsetup" + "github.com/mulgadc/spinifex/spinifex/foundation/telemetry" "log/slog" "time" ) diff --git a/cmd/spinifex/cmd/cluster.go b/cmd/spinifex/cmd/cluster.go index bdf69922c..c69a83d5e 100644 --- a/cmd/spinifex/cmd/cluster.go +++ b/cmd/spinifex/cmd/cluster.go @@ -12,7 +12,7 @@ import ( "github.com/mulgadc/spinifex/spinifex/daemon" "github.com/mulgadc/spinifex/spinifex/network/external/dhcp" - "github.com/mulgadc/spinifex/spinifex/otelsetup" + "github.com/mulgadc/spinifex/spinifex/foundation/telemetry" "github.com/mulgadc/spinifex/spinifex/types" "github.com/nats-io/nats.go" "github.com/spf13/cobra" diff --git a/spinifex/daemon/daemon.go b/spinifex/daemon/daemon.go index e0f70c2e7..0c77126ef 100644 --- a/spinifex/daemon/daemon.go +++ b/spinifex/daemon/daemon.go @@ -68,7 +68,7 @@ import ( "github.com/mulgadc/spinifex/spinifex/network/external/ocinet" "github.com/mulgadc/spinifex/spinifex/network/host" "github.com/mulgadc/spinifex/spinifex/objectstore" - "github.com/mulgadc/spinifex/spinifex/otelsetup" + "github.com/mulgadc/spinifex/spinifex/foundation/telemetry" "github.com/mulgadc/spinifex/spinifex/runtime/compute/gpu" "github.com/mulgadc/spinifex/spinifex/services/viperblockd/vbwire" "github.com/mulgadc/spinifex/spinifex/types" diff --git a/spinifex/daemon/daemon_handlers.go b/spinifex/daemon/daemon_handlers.go index 0d0dc28c5..929e24e75 100644 --- a/spinifex/daemon/daemon_handlers.go +++ b/spinifex/daemon/daemon_handlers.go @@ -17,7 +17,7 @@ import ( "github.com/mulgadc/spinifex/spinifex/awserrors" "github.com/mulgadc/spinifex/spinifex/formation" "github.com/mulgadc/spinifex/spinifex/network/host" - "github.com/mulgadc/spinifex/spinifex/otelsetup" + "github.com/mulgadc/spinifex/spinifex/foundation/telemetry" "github.com/mulgadc/spinifex/spinifex/runtime/compute/gpu" "github.com/mulgadc/spinifex/spinifex/types" "github.com/mulgadc/spinifex/spinifex/utils" diff --git a/spinifex/daemon/daemon_system_dispatch.go b/spinifex/daemon/daemon_system_dispatch.go index 24426cbc8..c250f7d94 100644 --- a/spinifex/daemon/daemon_system_dispatch.go +++ b/spinifex/daemon/daemon_system_dispatch.go @@ -12,7 +12,7 @@ import ( "github.com/mulgadc/spinifex/spinifex/awserrors" handlers_elbv2 "github.com/mulgadc/spinifex/spinifex/handlers/elbv2" "github.com/mulgadc/spinifex/spinifex/handlers/sysinstance" - "github.com/mulgadc/spinifex/spinifex/otelsetup" + "github.com/mulgadc/spinifex/spinifex/foundation/telemetry" "github.com/mulgadc/spinifex/spinifex/utils" "github.com/nats-io/nats.go" ) diff --git a/spinifex/daemon/heartbeat.go b/spinifex/daemon/heartbeat.go index 3433d81ad..ec1a37d37 100644 --- a/spinifex/daemon/heartbeat.go +++ b/spinifex/daemon/heartbeat.go @@ -1,7 +1,7 @@ package daemon import ( - "github.com/mulgadc/spinifex/spinifex/otelsetup" + "github.com/mulgadc/spinifex/spinifex/foundation/telemetry" "log/slog" "time" ) diff --git a/spinifex/daemon/instance_record_repair.go b/spinifex/daemon/instance_record_repair.go index dc9d9f472..5684d43b7 100644 --- a/spinifex/daemon/instance_record_repair.go +++ b/spinifex/daemon/instance_record_repair.go @@ -4,7 +4,7 @@ import ( "log/slog" "time" - "github.com/mulgadc/spinifex/spinifex/otelsetup" + "github.com/mulgadc/spinifex/spinifex/foundation/telemetry" "github.com/mulgadc/spinifex/spinifex/vm" ) diff --git a/spinifex/daemon/instance_recovery.go b/spinifex/daemon/instance_recovery.go index 21f4297bb..0421973d5 100644 --- a/spinifex/daemon/instance_recovery.go +++ b/spinifex/daemon/instance_recovery.go @@ -13,7 +13,7 @@ import ( "github.com/mulgadc/spinifex/spinifex/awserrors" handlers_ec2_instance "github.com/mulgadc/spinifex/spinifex/handlers/ec2/instance" "github.com/mulgadc/spinifex/spinifex/instancecache" - "github.com/mulgadc/spinifex/spinifex/otelsetup" + "github.com/mulgadc/spinifex/spinifex/foundation/telemetry" "github.com/mulgadc/spinifex/spinifex/vm" "go.opentelemetry.io/otel" "go.opentelemetry.io/otel/attribute" diff --git a/spinifex/daemon/jetstream.go b/spinifex/daemon/jetstream.go index 6f278f2d7..7477ba442 100644 --- a/spinifex/daemon/jetstream.go +++ b/spinifex/daemon/jetstream.go @@ -14,7 +14,7 @@ import ( "github.com/mulgadc/spinifex/spinifex/kvstore" "github.com/mulgadc/spinifex/spinifex/kvutil" "github.com/mulgadc/spinifex/spinifex/migrate" - "github.com/mulgadc/spinifex/spinifex/otelsetup" + "github.com/mulgadc/spinifex/spinifex/foundation/telemetry" "github.com/mulgadc/spinifex/spinifex/vm" "github.com/nats-io/nats.go" "github.com/nats-io/nats.go/jetstream" diff --git a/spinifex/daemon/nats_classification_test.go b/spinifex/daemon/nats_classification_test.go index 6ed9744b2..9b7eef9b9 100644 --- a/spinifex/daemon/nats_classification_test.go +++ b/spinifex/daemon/nats_classification_test.go @@ -13,7 +13,7 @@ import ( "time" "github.com/mulgadc/spinifex/spinifex/awserrors" - "github.com/mulgadc/spinifex/spinifex/otelsetup" + "github.com/mulgadc/spinifex/spinifex/foundation/telemetry" "github.com/mulgadc/spinifex/spinifex/testutil" "github.com/mulgadc/spinifex/spinifex/types" "github.com/stretchr/testify/assert" diff --git a/spinifex/daemon/ochre_deps.go b/spinifex/daemon/ochre_deps.go index 7b7ad3548..4168c518e 100644 --- a/spinifex/daemon/ochre_deps.go +++ b/spinifex/daemon/ochre_deps.go @@ -15,7 +15,7 @@ import ( handlers_ochrevector "github.com/mulgadc/spinifex/spinifex/handlers/ochrevector" "github.com/mulgadc/spinifex/spinifex/network/host" "github.com/mulgadc/spinifex/spinifex/objectstore" - "github.com/mulgadc/spinifex/spinifex/otelsetup" + "github.com/mulgadc/spinifex/spinifex/foundation/telemetry" "github.com/nats-io/nats.go/jetstream" ) diff --git a/spinifex/daemon/vm_adapters.go b/spinifex/daemon/vm_adapters.go index a2dbd73f4..897816fa9 100644 --- a/spinifex/daemon/vm_adapters.go +++ b/spinifex/daemon/vm_adapters.go @@ -14,7 +14,7 @@ import ( "github.com/mulgadc/spinifex/spinifex/network/external/dhcp" "github.com/mulgadc/spinifex/spinifex/network/topology" "github.com/mulgadc/spinifex/spinifex/objectstore" - "github.com/mulgadc/spinifex/spinifex/otelsetup" + "github.com/mulgadc/spinifex/spinifex/foundation/telemetry" "github.com/mulgadc/spinifex/spinifex/runtime/compute/gpu" "github.com/mulgadc/spinifex/spinifex/services/viperblockd/vbwire" "github.com/mulgadc/spinifex/spinifex/tags" diff --git a/spinifex/otelsetup/duration.go b/spinifex/foundation/telemetry/duration.go similarity index 100% rename from spinifex/otelsetup/duration.go rename to spinifex/foundation/telemetry/duration.go diff --git a/spinifex/otelsetup/duration_guard_test.go b/spinifex/foundation/telemetry/duration_guard_test.go similarity index 97% rename from spinifex/otelsetup/duration_guard_test.go rename to spinifex/foundation/telemetry/duration_guard_test.go index b611f69d5..352574342 100644 --- a/spinifex/otelsetup/duration_guard_test.go +++ b/spinifex/foundation/telemetry/duration_guard_test.go @@ -12,7 +12,7 @@ import ( "golang.org/x/tools/go/packages" - "github.com/mulgadc/spinifex/spinifex/otelsetup" + "github.com/mulgadc/spinifex/spinifex/foundation/telemetry" ) // logMethods are the slog entry points that take loosely typed key/value pairs, @@ -107,7 +107,7 @@ func isMillisCall(info *types.Info, expr ast.Expr) bool { return false } return fn.Name() == "Millis" && - fn.Pkg().Path() == "github.com/mulgadc/spinifex/spinifex/otelsetup" + fn.Pkg().Path() == "github.com/mulgadc/spinifex/spinifex/foundation/telemetry" } // precededByUnitKey reports whether the argument at i is the value half of a diff --git a/spinifex/otelsetup/http.go b/spinifex/foundation/telemetry/http.go similarity index 100% rename from spinifex/otelsetup/http.go rename to spinifex/foundation/telemetry/http.go diff --git a/spinifex/otelsetup/http_test.go b/spinifex/foundation/telemetry/http_test.go similarity index 100% rename from spinifex/otelsetup/http_test.go rename to spinifex/foundation/telemetry/http_test.go diff --git a/spinifex/otelsetup/metrics.go b/spinifex/foundation/telemetry/metrics.go similarity index 96% rename from spinifex/otelsetup/metrics.go rename to spinifex/foundation/telemetry/metrics.go index 3c730a5f0..262982f89 100644 --- a/spinifex/otelsetup/metrics.go +++ b/spinifex/foundation/telemetry/metrics.go @@ -10,8 +10,9 @@ import ( "go.opentelemetry.io/otel/metric" ) -// meterName is the instrumentation scope every spinifex request metric shares, -// so the HTTP and NATS paths land on one set of instruments. +// meterName is the stable instrumentation scope every spinifex request metric +// shares. It intentionally survives this Go package relocation so existing +// dashboards and alerts do not split their metric series. const meterName = "github.com/mulgadc/spinifex/spinifex/otelsetup" // actionAttrKey names the logical operation on request metrics. Values must diff --git a/spinifex/otelsetup/metrics_test.go b/spinifex/foundation/telemetry/metrics_test.go similarity index 98% rename from spinifex/otelsetup/metrics_test.go rename to spinifex/foundation/telemetry/metrics_test.go index f73ccd72c..51c9d3bd3 100644 --- a/spinifex/otelsetup/metrics_test.go +++ b/spinifex/foundation/telemetry/metrics_test.go @@ -3,7 +3,7 @@ package otelsetup_test import ( "testing" - "github.com/mulgadc/spinifex/spinifex/otelsetup" + "github.com/mulgadc/spinifex/spinifex/foundation/telemetry" "github.com/stretchr/testify/assert" "github.com/stretchr/testify/require" "go.opentelemetry.io/otel" diff --git a/spinifex/gateway/auth.go b/spinifex/gateway/auth.go index 051944b4d..2af04232a 100644 --- a/spinifex/gateway/auth.go +++ b/spinifex/gateway/auth.go @@ -16,7 +16,7 @@ import ( "github.com/mulgadc/spinifex/spinifex/awserrors" handlers_iam "github.com/mulgadc/spinifex/spinifex/handlers/iam" handlers_sts "github.com/mulgadc/spinifex/spinifex/handlers/sts" - "github.com/mulgadc/spinifex/spinifex/otelsetup" + "github.com/mulgadc/spinifex/spinifex/foundation/telemetry" "github.com/mulgadc/spinifex/spinifex/utils" ) diff --git a/spinifex/gateway/ecr/lifecycle_sweep.go b/spinifex/gateway/ecr/lifecycle_sweep.go index 4451575bf..7d574c26f 100644 --- a/spinifex/gateway/ecr/lifecycle_sweep.go +++ b/spinifex/gateway/ecr/lifecycle_sweep.go @@ -7,7 +7,7 @@ import ( "time" "github.com/mulgadc/spinifex/spinifex/handlers/ecr" - "github.com/mulgadc/spinifex/spinifex/otelsetup" + "github.com/mulgadc/spinifex/spinifex/foundation/telemetry" ) // DefaultLifecycleSweepInterval is the period between lifecycle expiry cycles. diff --git a/spinifex/gateway/ecrauth/rotator.go b/spinifex/gateway/ecrauth/rotator.go index 65377a45e..7b9f97fac 100644 --- a/spinifex/gateway/ecrauth/rotator.go +++ b/spinifex/gateway/ecrauth/rotator.go @@ -2,7 +2,7 @@ package gateway_ecrauth import ( "context" - "github.com/mulgadc/spinifex/spinifex/otelsetup" + "github.com/mulgadc/spinifex/spinifex/foundation/telemetry" "log/slog" "sort" "time" diff --git a/spinifex/gateway/gateway.go b/spinifex/gateway/gateway.go index 35a5addde..6884dc64b 100644 --- a/spinifex/gateway/gateway.go +++ b/spinifex/gateway/gateway.go @@ -36,7 +36,7 @@ import ( handlers_ochrevector "github.com/mulgadc/spinifex/spinifex/handlers/ochrevector" handlers_quota "github.com/mulgadc/spinifex/spinifex/handlers/quota" handlers_sts "github.com/mulgadc/spinifex/spinifex/handlers/sts" - "github.com/mulgadc/spinifex/spinifex/otelsetup" + "github.com/mulgadc/spinifex/spinifex/foundation/telemetry" "github.com/mulgadc/spinifex/spinifex/types" "github.com/mulgadc/spinifex/spinifex/utils" "github.com/nats-io/nats.go" diff --git a/spinifex/gateway/ratelimit.go b/spinifex/gateway/ratelimit.go index 76f850add..c691d136b 100644 --- a/spinifex/gateway/ratelimit.go +++ b/spinifex/gateway/ratelimit.go @@ -9,7 +9,7 @@ import ( "time" "github.com/mulgadc/spinifex/spinifex/awserrors" - "github.com/mulgadc/spinifex/spinifex/otelsetup" + "github.com/mulgadc/spinifex/spinifex/foundation/telemetry" ) const ( diff --git a/spinifex/gateway/requestaudit.go b/spinifex/gateway/requestaudit.go index 242437e76..1fe2cf4de 100644 --- a/spinifex/gateway/requestaudit.go +++ b/spinifex/gateway/requestaudit.go @@ -11,7 +11,7 @@ import ( "go.opentelemetry.io/otel/attribute" "go.opentelemetry.io/otel/trace" - "github.com/mulgadc/spinifex/spinifex/otelsetup" + "github.com/mulgadc/spinifex/spinifex/foundation/telemetry" "github.com/mulgadc/spinifex/spinifex/utils" ) diff --git a/spinifex/gateway/trace_test.go b/spinifex/gateway/trace_test.go index efc085f4a..a0c685997 100644 --- a/spinifex/gateway/trace_test.go +++ b/spinifex/gateway/trace_test.go @@ -6,7 +6,7 @@ import ( "net/http/httptest" "testing" - "github.com/mulgadc/spinifex/spinifex/otelsetup" + "github.com/mulgadc/spinifex/spinifex/foundation/telemetry" "go.opentelemetry.io/otel" sdktrace "go.opentelemetry.io/otel/sdk/trace" "go.opentelemetry.io/otel/sdk/trace/tracetest" diff --git a/spinifex/handlers/acm/renewal.go b/spinifex/handlers/acm/renewal.go index 9e0c3f87e..23c5ec7b5 100644 --- a/spinifex/handlers/acm/renewal.go +++ b/spinifex/handlers/acm/renewal.go @@ -19,7 +19,7 @@ import ( "github.com/aws/aws-sdk-go/service/acm" "github.com/mulgadc/spinifex/spinifex/awserrors" - "github.com/mulgadc/spinifex/spinifex/otelsetup" + "github.com/mulgadc/spinifex/spinifex/foundation/telemetry" ) const ( diff --git a/spinifex/handlers/bedrock/reaper.go b/spinifex/handlers/bedrock/reaper.go index 8acfa111d..85313f635 100644 --- a/spinifex/handlers/bedrock/reaper.go +++ b/spinifex/handlers/bedrock/reaper.go @@ -10,7 +10,7 @@ import ( gateway_bedrock "github.com/mulgadc/spinifex/spinifex/gateway/bedrock" "github.com/mulgadc/spinifex/spinifex/kvlease" "github.com/mulgadc/spinifex/spinifex/kvstore" - "github.com/mulgadc/spinifex/spinifex/otelsetup" + "github.com/mulgadc/spinifex/spinifex/foundation/telemetry" "github.com/mulgadc/spinifex/spinifex/utils" ) diff --git a/spinifex/handlers/eks/cluster_reconciler.go b/spinifex/handlers/eks/cluster_reconciler.go index 110d2c8d8..5a648eaef 100644 --- a/spinifex/handlers/eks/cluster_reconciler.go +++ b/spinifex/handlers/eks/cluster_reconciler.go @@ -15,7 +15,7 @@ import ( "github.com/mulgadc/spinifex/spinifex/kvlease" "github.com/mulgadc/spinifex/spinifex/kvstore" - "github.com/mulgadc/spinifex/spinifex/otelsetup" + "github.com/mulgadc/spinifex/spinifex/foundation/telemetry" "github.com/mulgadc/spinifex/spinifex/reconciler" "github.com/nats-io/nats.go" diff --git a/spinifex/handlers/iam/retry.go b/spinifex/handlers/iam/retry.go index b76b6b143..126e1f31e 100644 --- a/spinifex/handlers/iam/retry.go +++ b/spinifex/handlers/iam/retry.go @@ -3,7 +3,7 @@ package handlers_iam import ( "context" "fmt" - "github.com/mulgadc/spinifex/spinifex/otelsetup" + "github.com/mulgadc/spinifex/spinifex/foundation/telemetry" "log/slog" "time" diff --git a/spinifex/handlers/imds/action.go b/spinifex/handlers/imds/action.go index c8814d612..960ac1e9d 100644 --- a/spinifex/handlers/imds/action.go +++ b/spinifex/handlers/imds/action.go @@ -4,7 +4,7 @@ import ( "net/http" "strings" - "github.com/mulgadc/spinifex/spinifex/otelsetup" + "github.com/mulgadc/spinifex/spinifex/foundation/telemetry" ) // actionOther is the catch-all action name. A guest controls the request path, diff --git a/spinifex/handlers/imds/metadata.go b/spinifex/handlers/imds/metadata.go index e49c0af63..6275e6548 100644 --- a/spinifex/handlers/imds/metadata.go +++ b/spinifex/handlers/imds/metadata.go @@ -16,7 +16,7 @@ import ( "github.com/aws/aws-sdk-go/service/iam" "github.com/mulgadc/spinifex/spinifex/awserrors" handlers_dns "github.com/mulgadc/spinifex/spinifex/handlers/dns" - "github.com/mulgadc/spinifex/spinifex/otelsetup" + "github.com/mulgadc/spinifex/spinifex/foundation/telemetry" ) const ( diff --git a/spinifex/handlers/imds/service.go b/spinifex/handlers/imds/service.go index d490bc414..1d4075f00 100644 --- a/spinifex/handlers/imds/service.go +++ b/spinifex/handlers/imds/service.go @@ -12,7 +12,7 @@ import ( "github.com/aws/aws-sdk-go/service/iam" handlers_iam "github.com/mulgadc/spinifex/spinifex/handlers/iam" "github.com/mulgadc/spinifex/spinifex/kvstore" - "github.com/mulgadc/spinifex/spinifex/otelsetup" + "github.com/mulgadc/spinifex/spinifex/foundation/telemetry" "github.com/nats-io/nats.go" "github.com/nats-io/nats.go/jetstream" ) diff --git a/spinifex/handlers/sts/session_credentials.go b/spinifex/handlers/sts/session_credentials.go index e3bcd26c9..8c44bebf1 100644 --- a/spinifex/handlers/sts/session_credentials.go +++ b/spinifex/handlers/sts/session_credentials.go @@ -14,7 +14,7 @@ import ( "github.com/mulgadc/spinifex/spinifex/kvstore" "github.com/mulgadc/spinifex/spinifex/kvutil" "github.com/mulgadc/spinifex/spinifex/migrate" - "github.com/mulgadc/spinifex/spinifex/otelsetup" + "github.com/mulgadc/spinifex/spinifex/foundation/telemetry" "github.com/mulgadc/spinifex/spinifex/utils" "github.com/nats-io/nats.go/jetstream" ) diff --git a/spinifex/kvlease/bucket.go b/spinifex/kvlease/bucket.go index a3bbd9454..073703be1 100644 --- a/spinifex/kvlease/bucket.go +++ b/spinifex/kvlease/bucket.go @@ -8,7 +8,7 @@ import ( "time" "github.com/mulgadc/spinifex/spinifex/migrate" - "github.com/mulgadc/spinifex/spinifex/otelsetup" + "github.com/mulgadc/spinifex/spinifex/foundation/telemetry" "github.com/nats-io/nats.go" "github.com/nats-io/nats.go/jetstream" ) diff --git a/spinifex/kvstore/wait.go b/spinifex/kvstore/wait.go index 855da2d70..aae4731fc 100644 --- a/spinifex/kvstore/wait.go +++ b/spinifex/kvstore/wait.go @@ -6,7 +6,7 @@ import ( "log/slog" "time" - "github.com/mulgadc/spinifex/spinifex/otelsetup" + "github.com/mulgadc/spinifex/spinifex/foundation/telemetry" ) // DefaultOpenWindow is how long OpenWithRetry keeps trying. Long enough to diff --git a/spinifex/lbagent/agent.go b/spinifex/lbagent/agent.go index fc0cce5fe..706e06bc0 100644 --- a/spinifex/lbagent/agent.go +++ b/spinifex/lbagent/agent.go @@ -27,7 +27,7 @@ import ( "github.com/mulgadc/bluebottle/pkg/tlsconfig" "github.com/mulgadc/spinifex/internal/gwsign" "github.com/mulgadc/spinifex/spinifex/awserrors" - "github.com/mulgadc/spinifex/spinifex/otelsetup" + "github.com/mulgadc/spinifex/spinifex/foundation/telemetry" ) const ( diff --git a/spinifex/network/external/dhcp/manager.go b/spinifex/network/external/dhcp/manager.go index 37cacb7a4..672a17329 100644 --- a/spinifex/network/external/dhcp/manager.go +++ b/spinifex/network/external/dhcp/manager.go @@ -12,7 +12,7 @@ import ( "sync" "time" - "github.com/mulgadc/spinifex/spinifex/otelsetup" + "github.com/mulgadc/spinifex/spinifex/foundation/telemetry" "github.com/nats-io/nats.go" "github.com/nats-io/nats.go/jetstream" diff --git a/spinifex/network/host/firewall.go b/spinifex/network/host/firewall.go index f4d7aae50..add9c1fc2 100644 --- a/spinifex/network/host/firewall.go +++ b/spinifex/network/host/firewall.go @@ -16,7 +16,7 @@ import ( "time" "github.com/mulgadc/spinifex/spinifex/config" - "github.com/mulgadc/spinifex/spinifex/otelsetup" + "github.com/mulgadc/spinifex/spinifex/foundation/telemetry" "github.com/mulgadc/spinifex/spinifex/utils" ) diff --git a/spinifex/network/host/ipsec_enable.go b/spinifex/network/host/ipsec_enable.go index d77f2d3f3..9c4bce3f8 100644 --- a/spinifex/network/host/ipsec_enable.go +++ b/spinifex/network/host/ipsec_enable.go @@ -14,7 +14,7 @@ import ( "github.com/mulgadc/spinifex/spinifex/admin" "github.com/mulgadc/spinifex/spinifex/config" - "github.com/mulgadc/spinifex/spinifex/otelsetup" + "github.com/mulgadc/spinifex/spinifex/foundation/telemetry" "github.com/mulgadc/spinifex/spinifex/utils" ) diff --git a/spinifex/network/reconcile/apply.go b/spinifex/network/reconcile/apply.go index dcf620089..de043ba48 100644 --- a/spinifex/network/reconcile/apply.go +++ b/spinifex/network/reconcile/apply.go @@ -15,7 +15,7 @@ import ( "github.com/mulgadc/spinifex/spinifex/network/ovn/nbdb" "github.com/mulgadc/spinifex/spinifex/network/policy" "github.com/mulgadc/spinifex/spinifex/network/topology" - "github.com/mulgadc/spinifex/spinifex/otelsetup" + "github.com/mulgadc/spinifex/spinifex/foundation/telemetry" "github.com/mulgadc/spinifex/spinifex/utils" ) diff --git a/spinifex/network/reconcile/drift.go b/spinifex/network/reconcile/drift.go index 6609bd427..4b36d6c43 100644 --- a/spinifex/network/reconcile/drift.go +++ b/spinifex/network/reconcile/drift.go @@ -13,7 +13,7 @@ import ( handlers_ec2_routetable "github.com/mulgadc/spinifex/spinifex/handlers/ec2/routetable" handlers_ec2_vpc "github.com/mulgadc/spinifex/spinifex/handlers/ec2/vpc" "github.com/mulgadc/spinifex/spinifex/kvstore" - "github.com/mulgadc/spinifex/spinifex/otelsetup" + "github.com/mulgadc/spinifex/spinifex/foundation/telemetry" loop "github.com/mulgadc/spinifex/spinifex/reconciler" "github.com/nats-io/nats.go" "github.com/nats-io/nats.go/jetstream" diff --git a/spinifex/reconciler/reconciler.go b/spinifex/reconciler/reconciler.go index 9188908b0..6c9b3955f 100644 --- a/spinifex/reconciler/reconciler.go +++ b/spinifex/reconciler/reconciler.go @@ -25,7 +25,7 @@ import ( "github.com/mulgadc/spinifex/spinifex/awserrors" "github.com/mulgadc/spinifex/spinifex/kvstore" - "github.com/mulgadc/spinifex/spinifex/otelsetup" + "github.com/mulgadc/spinifex/spinifex/foundation/telemetry" "github.com/nats-io/nats.go/jetstream" ) diff --git a/spinifex/services/spinifexui/spinifexui.go b/spinifex/services/spinifexui/spinifexui.go index 43c9dfe41..f1aa63105 100644 --- a/spinifex/services/spinifexui/spinifexui.go +++ b/spinifex/services/spinifexui/spinifexui.go @@ -21,7 +21,7 @@ import ( "github.com/go-chi/chi/v5/middleware" "github.com/mulgadc/bluebottle/pkg/tlsconfig" - "github.com/mulgadc/spinifex/spinifex/otelsetup" + "github.com/mulgadc/spinifex/spinifex/foundation/telemetry" "github.com/mulgadc/spinifex/spinifex/utils" ) diff --git a/spinifex/services/viperblockd/viperblockd.go b/spinifex/services/viperblockd/viperblockd.go index 1c347ef14..1c051f912 100644 --- a/spinifex/services/viperblockd/viperblockd.go +++ b/spinifex/services/viperblockd/viperblockd.go @@ -18,7 +18,7 @@ import ( "github.com/mulgadc/bluebottle/pkg/masterkey" "github.com/mulgadc/spinifex/spinifex/admin" - "github.com/mulgadc/spinifex/spinifex/otelsetup" + "github.com/mulgadc/spinifex/spinifex/foundation/telemetry" "github.com/mulgadc/spinifex/spinifex/services/viperblockd/vbwire" "github.com/mulgadc/spinifex/spinifex/types" "github.com/mulgadc/spinifex/spinifex/utils" diff --git a/spinifex/services/viperblockd/volume_dirty.go b/spinifex/services/viperblockd/volume_dirty.go index 11745c2b4..daae1e81a 100644 --- a/spinifex/services/viperblockd/volume_dirty.go +++ b/spinifex/services/viperblockd/volume_dirty.go @@ -8,7 +8,7 @@ import ( "log/slog" "time" - "github.com/mulgadc/spinifex/spinifex/otelsetup" + "github.com/mulgadc/spinifex/spinifex/foundation/telemetry" "github.com/mulgadc/spinifex/spinifex/services/viperblockd/vbwire" "github.com/nats-io/nats.go" "github.com/nats-io/nats.go/jetstream" diff --git a/spinifex/services/viperblockd/volume_fence.go b/spinifex/services/viperblockd/volume_fence.go index 92441b4c5..4f342e024 100644 --- a/spinifex/services/viperblockd/volume_fence.go +++ b/spinifex/services/viperblockd/volume_fence.go @@ -9,7 +9,7 @@ import ( "os" "time" - "github.com/mulgadc/spinifex/spinifex/otelsetup" + "github.com/mulgadc/spinifex/spinifex/foundation/telemetry" "github.com/mulgadc/spinifex/spinifex/services/viperblockd/vbwire" "github.com/mulgadc/spinifex/spinifex/utils" "github.com/nats-io/nats.go/jetstream" diff --git a/spinifex/services/viperblockd/volume_lease.go b/spinifex/services/viperblockd/volume_lease.go index 175bbeed9..bb9ade544 100644 --- a/spinifex/services/viperblockd/volume_lease.go +++ b/spinifex/services/viperblockd/volume_lease.go @@ -5,7 +5,7 @@ import ( "encoding/json" "errors" "fmt" - "github.com/mulgadc/spinifex/spinifex/otelsetup" + "github.com/mulgadc/spinifex/spinifex/foundation/telemetry" "log/slog" "regexp" "sync" diff --git a/spinifex/utils/nats.go b/spinifex/utils/nats.go index 92252912f..2042336bb 100644 --- a/spinifex/utils/nats.go +++ b/spinifex/utils/nats.go @@ -14,7 +14,7 @@ import ( "github.com/mulgadc/bluebottle/pkg/tlsconfig" "github.com/mulgadc/spinifex/spinifex/awserrors" - "github.com/mulgadc/spinifex/spinifex/otelsetup" + "github.com/mulgadc/spinifex/spinifex/foundation/telemetry" "github.com/nats-io/nats.go" ) diff --git a/spinifex/vm/crash_recovery.go b/spinifex/vm/crash_recovery.go index a25f92b39..0e36efdff 100644 --- a/spinifex/vm/crash_recovery.go +++ b/spinifex/vm/crash_recovery.go @@ -4,7 +4,7 @@ import ( "context" "errors" "fmt" - "github.com/mulgadc/spinifex/spinifex/otelsetup" + "github.com/mulgadc/spinifex/spinifex/foundation/telemetry" "log/slog" "os" "os/exec" diff --git a/spinifex/vm/lifecycle.go b/spinifex/vm/lifecycle.go index 00e16f700..784406898 100644 --- a/spinifex/vm/lifecycle.go +++ b/spinifex/vm/lifecycle.go @@ -18,7 +18,7 @@ import ( "time" "github.com/mulgadc/spinifex/spinifex/domains/ec2/instancetypes" - "github.com/mulgadc/spinifex/spinifex/otelsetup" + "github.com/mulgadc/spinifex/spinifex/foundation/telemetry" "github.com/mulgadc/spinifex/spinifex/runtime/compute/qmp" "github.com/mulgadc/spinifex/spinifex/types" "github.com/mulgadc/spinifex/spinifex/utils" diff --git a/spinifex/vm/stuck_terminate_reaper.go b/spinifex/vm/stuck_terminate_reaper.go index 4082641e2..28e38c977 100644 --- a/spinifex/vm/stuck_terminate_reaper.go +++ b/spinifex/vm/stuck_terminate_reaper.go @@ -2,7 +2,7 @@ package vm import ( "context" - "github.com/mulgadc/spinifex/spinifex/otelsetup" + "github.com/mulgadc/spinifex/spinifex/foundation/telemetry" "log/slog" "time" ) diff --git a/spinifex/vm/teardown_reaper.go b/spinifex/vm/teardown_reaper.go index fb6aceb3b..98abd5ddd 100644 --- a/spinifex/vm/teardown_reaper.go +++ b/spinifex/vm/teardown_reaper.go @@ -3,7 +3,7 @@ package vm import ( "context" "fmt" - "github.com/mulgadc/spinifex/spinifex/otelsetup" + "github.com/mulgadc/spinifex/spinifex/foundation/telemetry" "log/slog" "strings" "sync" diff --git a/spinifex/vm/watchdog.go b/spinifex/vm/watchdog.go index eefc9ab0f..8ccd266ba 100644 --- a/spinifex/vm/watchdog.go +++ b/spinifex/vm/watchdog.go @@ -2,7 +2,7 @@ package vm import ( "context" - "github.com/mulgadc/spinifex/spinifex/otelsetup" + "github.com/mulgadc/spinifex/spinifex/foundation/telemetry" "log/slog" "time" ) diff --git a/spinifex/vpcd/host_eip_loop.go b/spinifex/vpcd/host_eip_loop.go index 96ff49569..42dc8ccfd 100644 --- a/spinifex/vpcd/host_eip_loop.go +++ b/spinifex/vpcd/host_eip_loop.go @@ -6,7 +6,7 @@ import ( "time" "github.com/mulgadc/spinifex/spinifex/network/reconcile" - "github.com/mulgadc/spinifex/spinifex/otelsetup" + "github.com/mulgadc/spinifex/spinifex/foundation/telemetry" ) // Host EIP pass cadence. Shorter than the drift interval because the state it diff --git a/spinifex/vpcd/ovn_controller_watchdog.go b/spinifex/vpcd/ovn_controller_watchdog.go index 7f45876f7..530796610 100644 --- a/spinifex/vpcd/ovn_controller_watchdog.go +++ b/spinifex/vpcd/ovn_controller_watchdog.go @@ -6,7 +6,7 @@ import ( "time" "github.com/mulgadc/spinifex/spinifex/network/host" - "github.com/mulgadc/spinifex/spinifex/otelsetup" + "github.com/mulgadc/spinifex/spinifex/foundation/telemetry" ) // Compile-time check: the gateway-claim prober satisfies the watchdog's needs. diff --git a/spinifex/vpcd/vpcd.go b/spinifex/vpcd/vpcd.go index 7417334f0..ce28369a9 100644 --- a/spinifex/vpcd/vpcd.go +++ b/spinifex/vpcd/vpcd.go @@ -28,7 +28,7 @@ import ( "github.com/mulgadc/spinifex/spinifex/network/reconcile" "github.com/mulgadc/spinifex/spinifex/network/subscribers" "github.com/mulgadc/spinifex/spinifex/network/topology" - "github.com/mulgadc/spinifex/spinifex/otelsetup" + "github.com/mulgadc/spinifex/spinifex/foundation/telemetry" "github.com/mulgadc/spinifex/spinifex/utils" "github.com/nats-io/nats.go" "github.com/nats-io/nats.go/jetstream"