Skip to content

Commit

Permalink
[otel-integration] fix allow setting dimensions for otel collector
Browse files Browse the repository at this point in the history
  • Loading branch information
povilasv committed May 29, 2024
1 parent 83d65f6 commit 708f4db
Show file tree
Hide file tree
Showing 5 changed files with 24 additions and 7 deletions.
4 changes: 4 additions & 0 deletions otel-integration/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,10 @@

## OpenTelemtry-Integration

### v0.0.74 / 2024-05-28
- [FEAT] Bump Collector to 0.101.0
- [FEAT] Allow setting dimensions to spanMetricsMulti preset

### v0.0.73 / 2024-05-28
- [FEAT] Bump Helm chart dependencies.
- [FEAT] Allowing loadBalancing presets dns configs (timout and resolver interval).
Expand Down
10 changes: 5 additions & 5 deletions otel-integration/k8s-helm/Chart.yaml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
apiVersion: v2
name: otel-integration
description: OpenTelemetry Integration
version: 0.0.73
version: 0.0.74
keywords:
- OpenTelemetry Collector
- OpenTelemetry Agent
Expand All @@ -11,22 +11,22 @@ keywords:
dependencies:
- name: opentelemetry-collector
alias: opentelemetry-agent
version: "0.84.1"
version: "0.85.0"
repository: https://cgx.jfrog.io/artifactory/coralogix-charts-virtual
condition: opentelemetry-agent.enabled
- name: opentelemetry-collector
alias: opentelemetry-agent-windows
version: "0.84.1"
version: "0.85.0"
repository: https://cgx.jfrog.io/artifactory/coralogix-charts-virtual
condition: opentelemetry-agent-windows.enabled
- name: opentelemetry-collector
alias: opentelemetry-cluster-collector
version: "0.84.1"
version: "0.85.0"
repository: https://cgx.jfrog.io/artifactory/coralogix-charts-virtual
condition: opentelemetry-cluster-collector.enabled
- name: opentelemetry-collector
alias: opentelemetry-gateway
version: "0.84.1"
version: "0.85.0"
repository: https://cgx.jfrog.io/artifactory/coralogix-charts-virtual
condition: opentelemetry-gateway.enabled
sources:
Expand Down
3 changes: 2 additions & 1 deletion otel-integration/k8s-helm/e2e-test/expected_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ var expectedSchemaURL = map[string]bool{
"https://opentelemetry.io/schemas/1.9.0": false,
}

const expectedScopeVersion = "0.100.0"
const expectedScopeVersion = "0.101.0"

var expectedScopeNames = map[string]bool{
"otelcol/hostmetricsreceiver/network": false,
Expand Down Expand Up @@ -149,4 +149,5 @@ var expectedMetrics map[string]bool = map[string]bool{
"otelcol_processor_batch_timeout_trigger_send": false,
"otelcol_exporter_send_failed_log_records": false,
"otelcol_processor_batch_batch_send_size": false,
"otelcol_processor_batch_": false,
}
4 changes: 4 additions & 0 deletions otel-integration/k8s-helm/e2e-test/main_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ import (
"testing"
"time"

"github.com/davecgh/go-spew/spew"
"github.com/stretchr/testify/assert"
"github.com/stretchr/testify/require"
"go.opentelemetry.io/collector/component/componenttest"
Expand Down Expand Up @@ -109,6 +110,9 @@ func checkScopeMetrics(t *testing.T, rmetrics pmetric.ResourceMetrics) error {
if ok {
expectedMetrics[metric.Name()] = true
}
if !ok {
spew.Dump(metric)
}
require.True(t, ok, "metrics %v does not match one of the expected values", metric.Name())
}
}
Expand Down
10 changes: 9 additions & 1 deletion otel-integration/k8s-helm/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ global:
defaultSubsystemName: "integration"
logLevel: "warn"
collectionInterval: "30s"
version: "0.0.73"
version: "0.0.74"

extensions:
kubernetesDashboard:
Expand Down Expand Up @@ -136,6 +136,10 @@ opentelemetry-agent:
enabled: false
collectionInterval: "{{.Values.global.collectionInterval}}"
metricsExpiration: 5m
extraDimensions:
- name: http.method
- name: cgx.transaction
- name: cgx.transaction.root
defaultHistogramBuckets:
[1ms, 4ms, 10ms, 20ms, 50ms, 100ms, 200ms, 500ms, 1s, 2s, 5s]
configs: []
Expand Down Expand Up @@ -375,6 +379,10 @@ opentelemetry-cluster-collector:
enabled: true
clusterName: "{{.Values.global.clusterName}}"
integrationName: "coralogix-integration-helm"
# Removes uids and other uneeded attributes from metric resources.
# This reduces target_info cardinality.
reduceResourceAttributes:
enabled: false

extraEnvs:
- name: CORALOGIX_PRIVATE_KEY
Expand Down

0 comments on commit 708f4db

Please sign in to comment.