From 282c169f0499694dd0b780cf225bc8680c05071d Mon Sep 17 00:00:00 2001 From: Alex Boten Date: Tue, 10 Oct 2023 14:33:59 -0700 Subject: [PATCH] update usage of logging exporter (#2130) * update usage of logging exporter The logging exporter is being deprecated in favour of the debug exporter. This changes references to the logging exporter to use the new debug exporter instead. Note: this will remain in draft until v0.86.0 is released which will be the first release to include the debug exporter. Signed-off-by: Alex Boten * add changelog Signed-off-by: Alex Boten * update collector version Signed-off-by: Alex Boten * update expected data Signed-off-by: Alex Boten * fix test expectations Signed-off-by: Alex Boten --------- Signed-off-by: Alex Boten --- .chloggen/codeboten_logging-debug.yaml | 16 ++++++++++++ README.md | 26 +++++++++---------- ...emetry-operator.clusterserviceversion.yaml | 2 +- cmd/operator-opamp-bridge/agent/agent_test.go | 24 ++++++++--------- .../testdata/agentbasiccomponentsallowed.yaml | 2 +- .../agent/testdata/agentbatchnotallowed.yaml | 2 +- .../testdata/agentnoprocessorsallowed.yaml | 2 +- .../agent/testdata/basic.yaml | 4 +-- .../agent/testdata/invalid.yaml | 4 +-- .../agent/testdata/updated.yaml | 4 +-- .../operator/testdata/collector.yaml | 4 +-- .../operator/testdata/invalid-collector.yaml | 4 +-- .../operator/testdata/updated-collector.yaml | 4 +-- cmd/otel-allocator/README.md | 4 +-- .../core_v1alpha1_opentelemetrycollector.yaml | 4 +-- config/samples/sidecar.yaml | 4 +-- .../adapters/config_to_ports_test.go | 6 ++--- .../adapters/config_validate_test.go | 8 +++--- .../manifests/collector/configmap_test.go | 16 ++++++------ .../manifests/collector/container_test.go | 2 +- .../http_sd_config_servicemonitor_test.yaml | 4 +-- ..._sd_config_servicemonitor_test_ta_set.yaml | 4 +-- .../testdata/http_sd_config_test.yaml | 4 +-- ...elabel_config_expected_with_sd_config.yaml | 4 +-- .../testdata/relabel_config_original.yaml | 4 +-- .../manifests/collector/testdata/test.yaml | 4 +-- .../targetallocator/testdata/test.yaml | 4 +-- pkg/collector/reconcile/testdata/test.yaml | 4 +-- tests/e2e-autoscale/autoscale/00-install.yaml | 8 +++--- .../00-install-collector.yaml | 4 +-- .../00-install-collector.yaml | 4 +-- .../00-install-collector.yaml | 4 +-- .../00-install-collector.yaml | 4 +-- .../00-install-collector.yaml | 4 +-- .../00-install-collector.yaml | 4 +-- .../02-install-collector.yaml | 4 +-- .../00-install-collector.yaml | 4 +-- .../00-install-collector.yaml | 4 +-- .../00-install-collector.yaml | 4 +-- .../00-install-collector.yaml | 4 +-- .../00-install-collector.yaml | 4 +-- .../00-install-collector.yaml | 4 +-- tests/e2e-openshift/route/00-install.yaml | 4 +-- .../e2e-upgrade/upgrade-test/00-install.yaml | 4 +-- .../upgrade-test/02-upgrade-collector.yaml | 4 +-- tests/e2e/daemonset-features/01-install.yaml | 4 +-- tests/e2e/ingress-subdomains/00-install.yaml | 4 +-- tests/e2e/ingress/00-install.yaml | 4 +-- tests/e2e/managed-reconcile/00-install.yaml | 4 +-- tests/e2e/managed-reconcile/01-assert.yaml | 4 +-- .../01-disable-reconciliation.yaml | 8 +++--- tests/e2e/managed-reconcile/02-assert.yaml | 4 +-- .../02-enable-reconciliation.yaml | 4 +-- .../00-promreceiver-allocatorconfig.yaml | 4 +-- .../01-promreceiver-labeldrop.yaml | 4 +-- ...02-promreceiver-allocatorconfig-extra.yaml | 4 +-- .../03-promreceiver-nopromconfig.yaml | 4 +-- .../e2e/smoke-init-containers/00-install.yaml | 4 +-- .../e2e/smoke-pod-annotations/00-install.yaml | 4 +-- .../00-install.yaml | 4 +-- .../01-install-second-config.yaml | 4 +-- .../00-install.yaml | 4 +-- tests/e2e/smoke-sidecar/00-install.yaml | 4 +-- tests/e2e/smoke-simplest/00-install.yaml | 4 +-- tests/e2e/smoke-statefulset/00-install.yaml | 4 +-- .../e2e/smoke-targetallocator/00-install.yaml | 4 +-- .../01-change-ta-config.yaml | 4 +-- .../e2e/statefulset-features/00-install.yaml | 4 +-- .../01-update-volume-claim-templates.yaml | 4 +-- .../targetallocator-features/00-install.yaml | 4 +-- 70 files changed, 183 insertions(+), 167 deletions(-) create mode 100755 .chloggen/codeboten_logging-debug.yaml diff --git a/.chloggen/codeboten_logging-debug.yaml b/.chloggen/codeboten_logging-debug.yaml new file mode 100755 index 0000000000..e37123dbc1 --- /dev/null +++ b/.chloggen/codeboten_logging-debug.yaml @@ -0,0 +1,16 @@ +# One of 'breaking', 'deprecation', 'new_component', 'enhancement', 'bug_fix' +change_type: enhancement + +# The name of the component, or a single word describing the area of concern, (e.g. operator, target allocator, github action) +component: operator + +# A brief description of the change. Surround your text with quotes ("") if it needs to start with a backtick (`). +note: updating the operator to use the Collector's debug exporter in replacement of the deprecated logging exporter + +# One or more tracking issues related to the change +issues: [2130] + +# (Optional) One or more lines of additional information to render under the primary note. +# These lines will be padded with 2 spaces and then inserted directly into the document. +# Use pipe (|) for multiline entries. +subtext: diff --git a/README.md b/README.md index d18c623f7c..e930cf3720 100644 --- a/README.md +++ b/README.md @@ -48,21 +48,21 @@ spec: timeout: 10s exporters: - logging: + debug: service: pipelines: traces: receivers: [otlp] processors: [] - exporters: [logging] + exporters: [debug] EOF ``` **_WARNING:_** Until the OpenTelemetry Collector format is stable, changes may be required in the above example to remain compatible with the latest version of the OpenTelemetry Collector image being referenced. -This will create an OpenTelemetry Collector instance named `simplest`, exposing a `jaeger-grpc` port to consume spans from your instrumented applications and exporting those spans via `logging`, which writes the spans to the console (`stdout`) of the OpenTelemetry Collector instance that receives the span. +This will create an OpenTelemetry Collector instance named `simplest`, exposing a `jaeger-grpc` port to consume spans from your instrumented applications and exporting those spans via `debug`, which writes the spans to the console (`stdout`) of the OpenTelemetry Collector instance that receives the span. The `config` node holds the `YAML` that should be passed down as-is to the underlying OpenTelemetry Collector instances. Refer to the [OpenTelemetry Collector](https://github.com/open-telemetry/opentelemetry-collector) documentation for a reference of the possible entries. @@ -111,14 +111,14 @@ spec: processors: exporters: - logging: + debug: service: pipelines: traces: receivers: [jaeger] processors: [] - exporters: [logging] + exporters: [debug] EOF kubectl apply -f - <