Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[refactor] Fix package misspelling: telemetery->telemetry #6269

Merged
merged 1 commit into from
Nov 28, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -263,7 +263,7 @@ Dependencies upgrades only.

#### 🚧 Experimental Features

* Implement telemetery struct for v1 components initialization ([@Wise-Wizard](https://github.com/Wise-Wizard) in [#5695](https://github.com/jaegertracing/jaeger/pull/5695))
* Implement telemetry struct for v1 components initialization ([@Wise-Wizard](https://github.com/Wise-Wizard) in [#5695](https://github.com/jaegertracing/jaeger/pull/5695))
* Support default configs for storage backends ([@yurishkuro](https://github.com/yurishkuro) in [#5691](https://github.com/jaegertracing/jaeger/pull/5691))
* Simplify configs organization ([@yurishkuro](https://github.com/yurishkuro) in [#5690](https://github.com/jaegertracing/jaeger/pull/5690))
* Create metrics.factory adapter for otel metrics ([@Wise-Wizard](https://github.com/Wise-Wizard) in [#5661](https://github.com/jaegertracing/jaeger/pull/5661))
Expand Down
8 changes: 4 additions & 4 deletions cmd/all-in-one/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ import (
"github.com/jaegertracing/jaeger/pkg/config"
"github.com/jaegertracing/jaeger/pkg/jtracer"
"github.com/jaegertracing/jaeger/pkg/metrics"
"github.com/jaegertracing/jaeger/pkg/telemetery"
"github.com/jaegertracing/jaeger/pkg/telemetry"
"github.com/jaegertracing/jaeger/pkg/tenancy"
"github.com/jaegertracing/jaeger/pkg/version"
metricsPlugin "github.com/jaegertracing/jaeger/plugin/metrics"
Expand Down Expand Up @@ -159,11 +159,11 @@ by default uses only in-memory database.`,
log.Fatal(err)
}

telset := telemetery.Setting{
telset := telemetry.Setting{
Logger: svc.Logger,
TracerProvider: tracer.OTEL,
Metrics: queryMetricsFactory,
ReportStatus: telemetery.HCAdapter(svc.HC()),
ReportStatus: telemetry.HCAdapter(svc.HC()),
LeveledMeterProvider: func(_ configtelemetry.Level) metric.MeterProvider {
return noop.NewMeterProvider()
},
Expand Down Expand Up @@ -222,7 +222,7 @@ func startQuery(
depReader dependencystore.Reader,
metricsQueryService querysvc.MetricsQueryService,
tm *tenancy.Manager,
telset telemetery.Setting,
telset telemetry.Setting,
) *queryApp.Server {
spanReader = spanstoremetrics.NewReaderDecorator(spanReader, telset.Metrics)
qs := querysvc.NewQueryService(spanReader, depReader, *queryOpts)
Expand Down
2 changes: 1 addition & 1 deletion cmd/jaeger/config-badger.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ service:
address: 0.0.0.0:8888
logs:
level: info
# TODO Initialize telemetery tracer once OTEL released new feature.
# TODO Initialize telemetry tracer once OTEL released new feature.
# https://github.com/open-telemetry/opentelemetry-collector/issues/10663

extensions:
Expand Down
2 changes: 1 addition & 1 deletion cmd/jaeger/config-cassandra.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ service:
address: 0.0.0.0:8888
logs:
level: debug
# TODO Initialize telemetery tracer once OTEL released new feature.
# TODO Initialize telemetry tracer once OTEL released new feature.
# https://github.com/open-telemetry/opentelemetry-collector/issues/10663

extensions:
Expand Down
2 changes: 1 addition & 1 deletion cmd/jaeger/config-elasticsearch.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ service:
address: 0.0.0.0:8888
logs:
level: debug
# TODO Initialize telemetery tracer once OTEL released new feature.
# TODO Initialize telemetry tracer once OTEL released new feature.
# https://github.com/open-telemetry/opentelemetry-collector/issues/10663

extensions:
Expand Down
2 changes: 1 addition & 1 deletion cmd/jaeger/config-opensearch.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ service:
address: 0.0.0.0:8888
logs:
level: debug
# TODO Initialize telemetery tracer once OTEL released new feature.
# TODO Initialize telemetry tracer once OTEL released new feature.
# https://github.com/open-telemetry/opentelemetry-collector/issues/10663

extensions:
Expand Down
2 changes: 1 addition & 1 deletion cmd/jaeger/config-remote-storage.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ service:
address: 0.0.0.0:8888
logs:
level: debug
# TODO Initialize telemetery tracer once OTEL released new feature.
# TODO Initialize telemetry tracer once OTEL released new feature.
# https://github.com/open-telemetry/opentelemetry-collector/issues/10663

extensions:
Expand Down
2 changes: 1 addition & 1 deletion cmd/jaeger/config-tail-sampling-always-sample.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ service:
address: 0.0.0.0:8888
logs:
level: debug
# TODO Initialize telemetery tracer once OTEL released new feature.
# TODO Initialize telemetry tracer once OTEL released new feature.
# https://github.com/open-telemetry/opentelemetry-collector/issues/10663

extensions:
Expand Down
2 changes: 1 addition & 1 deletion cmd/jaeger/config-tail-sampling-service-name-policy.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ service:
address: 0.0.0.0:8888
logs:
level: debug
# TODO Initialize telemetery tracer once OTEL released new feature.
# TODO Initialize telemetry tracer once OTEL released new feature.
# https://github.com/open-telemetry/opentelemetry-collector/issues/10663

extensions:
Expand Down
2 changes: 1 addition & 1 deletion cmd/jaeger/config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ service:
address: 0.0.0.0:8888
logs:
level: debug
# TODO Initialize telemetery tracer once OTEL released new feature.
# TODO Initialize telemetry tracer once OTEL released new feature.
# https://github.com/open-telemetry/opentelemetry-collector/issues/10663

extensions:
Expand Down
2 changes: 1 addition & 1 deletion cmd/jaeger/internal/all-in-one.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ service:
address: "${env:JAEGER_LISTEN_HOST:-localhost}:8888"
logs:
level: info
# TODO Initialize telemetery tracer once OTEL released new feature.
# TODO Initialize telemetry tracer once OTEL released new feature.
# https://github.com/open-telemetry/opentelemetry-collector/issues/10663

extensions:
Expand Down
4 changes: 2 additions & 2 deletions cmd/jaeger/internal/extension/jaegerquery/server.go
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ import (
"github.com/jaegertracing/jaeger/internal/metrics/otelmetrics"
"github.com/jaegertracing/jaeger/pkg/jtracer"
"github.com/jaegertracing/jaeger/pkg/metrics"
"github.com/jaegertracing/jaeger/pkg/telemetery"
"github.com/jaegertracing/jaeger/pkg/telemetry"
"github.com/jaegertracing/jaeger/pkg/tenancy"
"github.com/jaegertracing/jaeger/plugin/metrics/disabled"
"github.com/jaegertracing/jaeger/storage/metricsstore"
Expand Down Expand Up @@ -94,7 +94,7 @@ func (s *server) Start(ctx context.Context, host component.Host) error {
return fmt.Errorf("could not initialize a tracer: %w", err)
}
s.closeTracer = tracerProvider.Close
telset := telemetery.Setting{
telset := telemetry.Setting{
Logger: s.telset.Logger,
TracerProvider: tracerProvider.OTEL,
Metrics: queryMetricsFactory,
Expand Down
4 changes: 2 additions & 2 deletions cmd/jaeger/internal/extension/jaegerstorage/extension.go
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ import (

"github.com/jaegertracing/jaeger/internal/metrics/otelmetrics"
"github.com/jaegertracing/jaeger/pkg/metrics"
"github.com/jaegertracing/jaeger/pkg/telemetery"
"github.com/jaegertracing/jaeger/pkg/telemetry"
"github.com/jaegertracing/jaeger/plugin/metrics/prometheus"
"github.com/jaegertracing/jaeger/plugin/storage/badger"
"github.com/jaegertracing/jaeger/plugin/storage/cassandra"
Expand Down Expand Up @@ -130,7 +130,7 @@ func (s *storageExt) Start(_ context.Context, host component.Host) error {
case cfg.Badger != nil:
factory, err = badger.NewFactoryWithConfig(*cfg.Badger, mf, s.telset.Logger)
case cfg.GRPC != nil:
telset := telemetery.Setting{
telset := telemetry.Setting{
Logger: s.telset.Logger,
Host: host,
Metrics: mf,
Expand Down
14 changes: 7 additions & 7 deletions cmd/query/app/server.go
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ import (
"github.com/jaegertracing/jaeger/pkg/bearertoken"
"github.com/jaegertracing/jaeger/pkg/netutils"
"github.com/jaegertracing/jaeger/pkg/recoveryhandler"
"github.com/jaegertracing/jaeger/pkg/telemetery"
"github.com/jaegertracing/jaeger/pkg/telemetry"
"github.com/jaegertracing/jaeger/pkg/tenancy"
"github.com/jaegertracing/jaeger/proto-gen/api_v2"
"github.com/jaegertracing/jaeger/proto-gen/api_v2/metrics"
Expand All @@ -48,7 +48,7 @@ type Server struct {
httpServer *httpServer
separatePorts bool
bgFinished sync.WaitGroup
telemetery.Setting
telemetry.Setting
}

// NewServer creates and initializes Server
Expand All @@ -58,7 +58,7 @@ func NewServer(
metricsQuerySvc querysvc.MetricsQueryService,
options *QueryOptions,
tm *tenancy.Manager,
telset telemetery.Setting,
telset telemetry.Setting,
) (*Server, error) {
_, httpPort, err := net.SplitHostPort(options.HTTP.Endpoint)
if err != nil {
Expand Down Expand Up @@ -98,7 +98,7 @@ func registerGRPCHandlers(
server *grpc.Server,
querySvc *querysvc.QueryService,
metricsQuerySvc querysvc.MetricsQueryService,
telset telemetery.Setting,
telset telemetry.Setting,
) {
reflection.Register(server)
handler := NewGRPCHandler(querySvc, metricsQuerySvc, GRPCHandlerOptions{
Expand All @@ -121,7 +121,7 @@ func createGRPCServer(
ctx context.Context,
options *QueryOptions,
tm *tenancy.Manager,
telset telemetery.Setting,
telset telemetry.Setting,
) (*grpc.Server, error) {
var grpcOpts []configgrpc.ToServerOption
unaryInterceptors := []grpc.UnaryServerInterceptor{
Expand Down Expand Up @@ -164,7 +164,7 @@ func initRouter(
metricsQuerySvc querysvc.MetricsQueryService,
queryOpts *QueryOptions,
tenancyMgr *tenancy.Manager,
telset telemetery.Setting,
telset telemetry.Setting,
) (http.Handler, io.Closer) {
apiHandlerOptions := []HandlerOption{
HandlerOptions.Logger(telset.Logger),
Expand Down Expand Up @@ -206,7 +206,7 @@ func createHTTPServer(
metricsQuerySvc querysvc.MetricsQueryService,
queryOpts *QueryOptions,
tm *tenancy.Manager,
telset telemetery.Setting,
telset telemetry.Setting,
) (*httpServer, error) {
handler, staticHandlerCloser := initRouter(querySvc, metricsQuerySvc, queryOpts, tm, telset)
handler = recoveryhandler.NewRecoveryHandler(telset.Logger, true)(handler)
Expand Down
8 changes: 4 additions & 4 deletions cmd/query/app/server_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ import (
"github.com/jaegertracing/jaeger/model"
"github.com/jaegertracing/jaeger/pkg/healthcheck"
"github.com/jaegertracing/jaeger/pkg/jtracer"
"github.com/jaegertracing/jaeger/pkg/telemetery"
"github.com/jaegertracing/jaeger/pkg/telemetry"
"github.com/jaegertracing/jaeger/pkg/tenancy"
"github.com/jaegertracing/jaeger/ports"
"github.com/jaegertracing/jaeger/proto-gen/api_v2"
Expand All @@ -49,11 +49,11 @@ import (

var testCertKeyLocation = "../../../pkg/config/tlscfg/testdata"

func initTelSet(logger *zap.Logger, tracerProvider *jtracer.JTracer, hc *healthcheck.HealthCheck) telemetery.Setting {
return telemetery.Setting{
func initTelSet(logger *zap.Logger, tracerProvider *jtracer.JTracer, hc *healthcheck.HealthCheck) telemetry.Setting {
return telemetry.Setting{
Logger: logger,
TracerProvider: tracerProvider.OTEL,
ReportStatus: telemetery.HCAdapter(hc),
ReportStatus: telemetry.HCAdapter(hc),
Host: componenttest.NewNopHost(),
LeveledMeterProvider: func(_ configtelemetry.Level) metric.MeterProvider {
return noop.NewMeterProvider()
Expand Down
6 changes: 3 additions & 3 deletions cmd/query/app/token_propagation_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ import (
"github.com/jaegertracing/jaeger/pkg/config"
"github.com/jaegertracing/jaeger/pkg/jtracer"
"github.com/jaegertracing/jaeger/pkg/metrics"
"github.com/jaegertracing/jaeger/pkg/telemetery"
"github.com/jaegertracing/jaeger/pkg/telemetry"
"github.com/jaegertracing/jaeger/pkg/tenancy"
"github.com/jaegertracing/jaeger/plugin/storage/es"
"github.com/jaegertracing/jaeger/ports"
Expand Down Expand Up @@ -88,10 +88,10 @@ func runQueryService(t *testing.T, esURL string) *Server {
require.NoError(t, err)

querySvc := querysvc.NewQueryService(spanReader, nil, querysvc.QueryServiceOptions{})
telset := telemetery.Setting{
telset := telemetry.Setting{
Logger: flagsSvc.Logger,
TracerProvider: jtracer.NoOp().OTEL,
ReportStatus: telemetery.HCAdapter(flagsSvc.HC()),
ReportStatus: telemetry.HCAdapter(flagsSvc.HC()),
LeveledMeterProvider: func(_ configtelemetry.Level) metric.MeterProvider {
return noop.NewMeterProvider()
},
Expand Down
6 changes: 3 additions & 3 deletions cmd/query/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ import (
"github.com/jaegertracing/jaeger/pkg/config"
"github.com/jaegertracing/jaeger/pkg/jtracer"
"github.com/jaegertracing/jaeger/pkg/metrics"
"github.com/jaegertracing/jaeger/pkg/telemetery"
"github.com/jaegertracing/jaeger/pkg/telemetry"
"github.com/jaegertracing/jaeger/pkg/tenancy"
"github.com/jaegertracing/jaeger/pkg/version"
metricsPlugin "github.com/jaegertracing/jaeger/plugin/metrics"
Expand Down Expand Up @@ -107,10 +107,10 @@ func main() {
dependencyReader,
*queryServiceOptions)
tm := tenancy.NewManager(&queryOpts.Tenancy)
telset := telemetery.Setting{
telset := telemetry.Setting{
Logger: logger,
TracerProvider: jt.OTEL,
ReportStatus: telemetery.HCAdapter(svc.HC()),
ReportStatus: telemetry.HCAdapter(svc.HC()),
LeveledMeterProvider: func(_ configtelemetry.Level) metric.MeterProvider {
return noop.NewMeterProvider()
},
Expand Down
6 changes: 3 additions & 3 deletions cmd/remote-storage/app/server.go
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ import (

"github.com/jaegertracing/jaeger/cmd/query/app/querysvc"
"github.com/jaegertracing/jaeger/pkg/bearertoken"
"github.com/jaegertracing/jaeger/pkg/telemetery"
"github.com/jaegertracing/jaeger/pkg/telemetry"
"github.com/jaegertracing/jaeger/pkg/tenancy"
"github.com/jaegertracing/jaeger/plugin/storage/grpc/shared"
"github.com/jaegertracing/jaeger/storage"
Expand All @@ -32,11 +32,11 @@ type Server struct {
grpcConn net.Listener
grpcServer *grpc.Server
wg sync.WaitGroup
telemetery.Setting
telemetry.Setting
}

// NewServer creates and initializes Server.
func NewServer(options *Options, storageFactory storage.Factory, tm *tenancy.Manager, telset telemetery.Setting) (*Server, error) {
func NewServer(options *Options, storageFactory storage.Factory, tm *tenancy.Manager, telset telemetry.Setting) (*Server, error) {
handler, err := createGRPCHandler(storageFactory, telset.Logger)
if err != nil {
return nil, err
Expand Down
16 changes: 8 additions & 8 deletions cmd/remote-storage/app/server_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ import (
"github.com/jaegertracing/jaeger/internal/grpctest"
"github.com/jaegertracing/jaeger/pkg/config/tlscfg"
"github.com/jaegertracing/jaeger/pkg/healthcheck"
"github.com/jaegertracing/jaeger/pkg/telemetery"
"github.com/jaegertracing/jaeger/pkg/telemetry"
"github.com/jaegertracing/jaeger/pkg/tenancy"
"github.com/jaegertracing/jaeger/ports"
"github.com/jaegertracing/jaeger/proto-gen/storage_v1"
Expand All @@ -45,7 +45,7 @@ func TestNewServer_CreateStorageErrors(t *testing.T) {
factory.On("CreateSpanWriter").Return(nil, nil)
factory.On("CreateDependencyReader").Return(nil, errors.New("no deps")).Once()
factory.On("CreateDependencyReader").Return(nil, nil)
telset := telemetery.Setting{
telset := telemetry.Setting{
Logger: zap.NewNop(),
ReportStatus: func(*componentstatus.Event) {},
LeveledMeterProvider: func(_ configtelemetry.Level) metric.MeterProvider {
Expand Down Expand Up @@ -119,9 +119,9 @@ func TestNewServer_TLSConfigError(t *testing.T) {
KeyPath: "invalid/path",
ClientCAPath: "invalid/path",
}
telset := telemetery.Setting{
telset := telemetry.Setting{
Logger: zap.NewNop(),
ReportStatus: telemetery.HCAdapter(healthcheck.New()),
ReportStatus: telemetry.HCAdapter(healthcheck.New()),
}
storageMocks := newStorageMocks()
_, err := NewServer(
Expand Down Expand Up @@ -327,9 +327,9 @@ func TestServerGRPCTLS(t *testing.T) {
storageMocks.reader.On("GetServices", mock.AnythingOfType("*context.valueCtx")).Return(expectedServices, nil)

tm := tenancy.NewManager(&tenancy.Options{Enabled: true})
telset := telemetery.Setting{
telset := telemetry.Setting{
Logger: flagsSvc.Logger,
ReportStatus: telemetery.HCAdapter(flagsSvc.HC()),
ReportStatus: telemetry.HCAdapter(flagsSvc.HC()),
}
server, err := NewServer(
serverOptions,
Expand Down Expand Up @@ -376,9 +376,9 @@ func TestServerHandlesPortZero(t *testing.T) {
zapCore, logs := observer.New(zap.InfoLevel)
flagsSvc.Logger = zap.New(zapCore)
storageMocks := newStorageMocks()
telset := telemetery.Setting{
telset := telemetry.Setting{
Logger: flagsSvc.Logger,
ReportStatus: telemetery.HCAdapter(flagsSvc.HC()),
ReportStatus: telemetry.HCAdapter(flagsSvc.HC()),
}
server, err := NewServer(
&Options{GRPCHostPort: ":0"},
Expand Down
6 changes: 3 additions & 3 deletions cmd/remote-storage/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ import (
"github.com/jaegertracing/jaeger/cmd/remote-storage/app"
"github.com/jaegertracing/jaeger/pkg/config"
"github.com/jaegertracing/jaeger/pkg/metrics"
"github.com/jaegertracing/jaeger/pkg/telemetery"
"github.com/jaegertracing/jaeger/pkg/telemetry"
"github.com/jaegertracing/jaeger/pkg/tenancy"
"github.com/jaegertracing/jaeger/pkg/version"
"github.com/jaegertracing/jaeger/plugin/storage"
Expand Down Expand Up @@ -70,9 +70,9 @@ func main() {
}

tm := tenancy.NewManager(&opts.Tenancy)
telset := telemetery.Setting{
telset := telemetry.Setting{
Logger: svc.Logger,
ReportStatus: telemetery.HCAdapter(svc.HC()),
ReportStatus: telemetry.HCAdapter(svc.HC()),
LeveledMeterProvider: func(_ configtelemetry.Level) metric.MeterProvider {
return noop.NewMeterProvider()
},
Expand Down
2 changes: 1 addition & 1 deletion pkg/telemetery/settings.go → pkg/telemetry/settings.go
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
// Copyright (c) 2024 The Jaeger Authors.
// SPDX-License-Identifier: Apache-2.0

package telemetery
package telemetry

import (
"go.opentelemetry.io/collector/component"
Expand Down
Loading
Loading