From 0b2f621254e072cb369c4c1dea93ecbae8f8bf8b Mon Sep 17 00:00:00 2001 From: anhnv Date: Thu, 17 Aug 2023 15:35:55 +0700 Subject: [PATCH] refactor: update env key OTLP_ENABLE to OTLP_ENABLED --- pkg/constant/env.go | 2 +- pkg/metric/init.go | 2 +- pkg/tracer/init.go | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/pkg/constant/env.go b/pkg/constant/env.go index fe7cf83..ecd63e3 100644 --- a/pkg/constant/env.go +++ b/pkg/constant/env.go @@ -1,7 +1,7 @@ package constant const ( - EnvKeyOTLPEnable = "OTLP_ENABLE" + EnvKeyOTLPEnabled = "OTLP_ENABLED" EnvKeyOTLPCollectorUrl = "OTLP_COLLECTOR_URL" EnvKeyOTLPInsecure = "OTLP_INSECURE" EnvKeyOTLPProtocol = "OTLP_PROTOCOL" diff --git a/pkg/metric/init.go b/pkg/metric/init.go index 29d629d..23d6590 100644 --- a/pkg/metric/init.go +++ b/pkg/metric/init.go @@ -6,7 +6,7 @@ import ( ) func init() { - if env.BoolFromEnv(constant.EnvKeyOTLPEnable) { + if env.BoolFromEnv(constant.EnvKeyOTLPEnabled) { initProvider() } } diff --git a/pkg/tracer/init.go b/pkg/tracer/init.go index f414132..27675e7 100644 --- a/pkg/tracer/init.go +++ b/pkg/tracer/init.go @@ -6,7 +6,7 @@ import ( ) func init() { - if env.BoolFromEnv(constant.EnvKeyOTLPEnable) { + if env.BoolFromEnv(constant.EnvKeyOTLPEnabled) { initProvider() } }