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

[receiver/datadog] Data race detected in tests #34823

Closed
crobert-1 opened this issue Aug 22, 2024 · 1 comment · Fixed by #34834
Closed

[receiver/datadog] Data race detected in tests #34823

crobert-1 opened this issue Aug 22, 2024 · 1 comment · Fixed by #34834
Labels
needs triage New item requiring triage receiver/datadog

Comments

@crobert-1
Copy link
Member

Component(s)

receiver/datadog

Describe the issue you're reporting

Failing CI/CD action link

Failure output:

=== Failed
=== FAIL: . TestDatadogInfoEndpoint/Traces_consumer_only (0.00s)
    testing.go:1398: race detected during execution of test

=== FAIL: . TestDatadogInfoEndpoint/Both_consumers (0.00s)
    testing.go:1398: race detected during execution of test

=== FAIL: . TestDatadogInfoEndpoint/Metrics_consumer_only (0.01s)
    testing.go:1398: race detected during execution of test

=== FAIL: . TestDatadogInfoEndpoint/No_consumers (0.01s)
==================
WARNING: DATA RACE
Read at 0x00c0001222c0 by goroutine 49:
  go.opentelemetry.io/collector/config/confighttp.(*ServerConfig).ToServer()
      C:/Users/runneradmin/go/pkg/mod/go.opentelemetry.io/collector/config/confighttp@v0.107.1-0.20[240](https://github.com/open-telemetry/opentelemetry-collector-contrib/actions/runs/10514581275/job/29132732343?pr=34794#step:6:241)821120936-6764622672bc/confighttp.go:421 +0x1a8
  github.com/open-telemetry/opentelemetry-collector-contrib/receiver/datadogreceiver.(*datadogReceiver).Start()
      D:/a/opentelemetry-collector-contrib/opentelemetry-collector-contrib/receiver/datadogreceiver/receiver.go:153 +0x25a
  github.com/open-telemetry/opentelemetry-collector-contrib/receiver/datadogreceiver.TestDatadogInfoEndpoint.func1()
      D:/a/opentelemetry-collector-contrib/opentelemetry-collector-contrib/receiver/datadogreceiver/receiver_test.go:229 +0x311
  testing.tRunner()
      C:/hostedtoolcache/windows/go/1.22.6/x64/src/testing/testing.go:1689 +0x21e
  testing.(*T).Run.gowrap1()
      C:/hostedtoolcache/windows/go/1.22.6/x64/src/testing/testing.go:1742 +0x44

Previous write at 0x00c0001222c0 by goroutine 48:
  go.opentelemetry.io/collector/config/confighttp.(*ServerConfig).ToServer()
      C:/Users/runneradmin/go/pkg/mod/go.opentelemetry.io/collector/config/confighttp@v0.107.1-0.20240821120936-6764622672bc/confighttp.go:422 +0x204
  github.com/open-telemetry/opentelemetry-collector-contrib/receiver/datadogreceiver.(*datadogReceiver).Start()
      D:/a/opentelemetry-collector-contrib/opentelemetry-collector-contrib/receiver/datadogreceiver/receiver.go:153 +0x25a
  github.com/open-telemetry/opentelemetry-collector-contrib/receiver/datadogreceiver.TestDatadogInfoEndpoint.func1()
      D:/a/opentelemetry-collector-contrib/opentelemetry-collector-contrib/receiver/datadogreceiver/receiver_test.go:229 +0x311
  testing.tRunner()
      C:/hostedtoolcache/windows/go/1.22.6/x64/src/testing/testing.go:1689 +0x21e
  testing.(*T).Run.gowrap1()
      C:/hostedtoolcache/windows/go/1.22.6/x64/src/testing/testing.go:1742 +0x44

Goroutine 49 (running) created at:
  testing.(*T).Run()
      C:/hostedtoolcache/windows/go/1.22.6/x64/src/testing/testing.go:1742 +0x825
  github.com/open-telemetry/opentelemetry-collector-contrib/receiver/datadogreceiver.TestDatadogInfoEndpoint()
      D:/a/opentelemetry-collector-contrib/opentelemetry-collector-contrib/receiver/datadogreceiver/receiver_test.go:214 +0x9ee
  testing.tRunner()
      C:/hostedtoolcache/windows/go/1.22.6/x64/src/testing/testing.go:1689 +0x21e
  testing.(*T).Run.gowrap1()
      C:/hostedtoolcache/windows/go/1.22.6/x64/src/testing/testing.go:1742 +0x44

Goroutine 48 (running) created at:
  testing.(*T).Run()
      C:/hostedtoolcache/windows/go/1.22.6/x64/src/testing/testing.go:1742 +0x825
  github.com/open-telemetry/opentelemetry-collector-contrib/receiver/datadogreceiver.TestDatadogInfoEndpoint()
      D:/a/opentelemetry-collector-contrib/opentelemetry-collector-contrib/receiver/datadogreceiver/receiver_test.go:214 +0x9ee
  testing.tRunner()
      C:/hostedtoolcache/windows/go/1.22.6/x64/src/testing/testing.go:1689 +0x21e
  testing.(*T).Run.gowrap1()
      C:/hostedtoolcache/windows/go/1.22.6/x64/src/testing/testing.go:1742 +0x44
==================
==================
WARNING: DATA RACE
Read at 0x00c0001222a8 by goroutine 47:
  go.opentelemetry.io/collector/config/confighttp.(*ServerConfig).ToServer()
      C:/Users/runneradmin/go/pkg/mod/go.opentelemetry.io/collector/config/confighttp@v0.107.1-0.20240821120936-676462[267](https://github.com/open-telemetry/opentelemetry-collector-contrib/actions/runs/10514581275/job/29132732343?pr=34794#step:6:268)2bc/confighttp.go:417 +0x164
  github.com/open-telemetry/opentelemetry-collector-contrib/receiver/datadogreceiver.(*datadogReceiver).Start()
      D:/a/opentelemetry-collector-contrib/opentelemetry-collector-contrib/receiver/datadogreceiver/receiver.go:153 +0x25a
  github.com/open-telemetry/opentelemetry-collector-contrib/receiver/datadogreceiver.TestDatadogInfoEndpoint.func1()
      D:/a/opentelemetry-collector-contrib/opentelemetry-collector-contrib/receiver/datadogreceiver/receiver_test.go:229 +0x311
  testing.tRunner()
      C:/hostedtoolcache/windows/go/1.22.6/x64/src/testing/testing.go:1689 +0x21e
  testing.(*T).Run.gowrap1()
      C:/hostedtoolcache/windows/go/1.22.6/x64/src/testing/testing.go:1742 +0x44

Previous write at 0x00c0001222a8 by goroutine 48:
  go.opentelemetry.io/collector/config/confighttp.(*ServerConfig).ToServer()
      C:/Users/runneradmin/go/pkg/mod/go.opentelemetry.io/collector/config/confighttp@v0.107.1-0.20240821120936-6764622672bc/confighttp.go:418 +0x184
  github.com/open-telemetry/opentelemetry-collector-contrib/receiver/datadogreceiver.(*datadogReceiver).Start()
      D:/a/opentelemetry-collector-contrib/opentelemetry-collector-contrib/receiver/datadogreceiver/receiver.go:153 +0x25a
  github.com/open-telemetry/opentelemetry-collector-contrib/receiver/datadogreceiver.TestDatadogInfoEndpoint.func1()
      D:/a/opentelemetry-collector-contrib/opentelemetry-collector-contrib/receiver/datadogreceiver/receiver_test.go:229 +0x311
  testing.tRunner()
      C:/hostedtoolcache/windows/go/1.22.6/x64/src/testing/testing.go:1689 +0x21e
  testing.(*T).Run.gowrap1()
      C:/hostedtoolcache/windows/go/1.22.6/x64/src/testing/testing.go:1742 +0x44

Goroutine 47 (running) created at:
  testing.(*T).Run()
      C:/hostedtoolcache/windows/go/1.22.6/x64/src/testing/testing.go:1742 +0x825
  github.com/open-telemetry/opentelemetry-collector-contrib/receiver/datadogreceiver.TestDatadogInfoEndpoint()
      D:/a/opentelemetry-collector-contrib/opentelemetry-collector-contrib/receiver/datadogreceiver/receiver_test.go:214 +0x9ee
  testing.tRunner()
      C:/hostedtoolcache/windows/go/1.22.6/x64/src/testing/testing.go:1689 +0x21e
  testing.(*T).Run.gowrap1()
      C:/hostedtoolcache/windows/go/1.22.6/x64/src/testing/testing.go:1742 +0x44

Goroutine 48 (running) created at:
  testing.(*T).Run()
      C:/hostedtoolcache/windows/go/1.22.6/x64/src/testing/testing.go:1742 +0x825
  github.com/open-telemetry/opentelemetry-collector-contrib/receiver/datadogreceiver.TestDatadogInfoEndpoint()
      D:/a/opentelemetry-collector-contrib/opentelemetry-collector-contrib/receiver/datadogreceiver/receiver_test.go:214 +0x9ee
  testing.tRunner()
      C:/hostedtoolcache/windows/go/1.22.6/x64/src/testing/testing.go:1689 +0x21e
  testing.(*T).Run.gowrap1()
      C:/hostedtoolcache/windows/go/1.22.6/x64/src/testing/testing.go:1742 +0x44
==================
    testing.go:1398: race detected during execution of test

=== FAIL: . TestDatadogInfoEndpoint (0.00s)
@crobert-1 crobert-1 added the needs triage New item requiring triage label Aug 22, 2024
Copy link
Contributor

Pinging code owners:

See Adding Labels via Comments if you do not have permissions to add labels yourself.

f7o pushed a commit to f7o/opentelemetry-collector-contrib that referenced this issue Sep 12, 2024
…etry#34834)

**Description:** <Describe what has changed.>
Fixes open-telemetry#34823

**Link to tracking Issue:** <Issue number if applicable>

**Testing:** <Describe what testing was performed and which tests were
added.>

**Documentation:** <Describe the documentation added.>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
needs triage New item requiring triage receiver/datadog
Projects
None yet
1 participant