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

[Flaky test] [extension/observer/kafkatopicsobserver] TestCollectEndpointsAllConfigSettings is flaky #38192

Closed
songy23 opened this issue Feb 25, 2025 · 3 comments · Fixed by #38218

Comments

@songy23
Copy link
Member

songy23 commented Feb 25, 2025

Component(s)

extension/observer/kafkatopicsobserver

Describe the issue you're reporting

Saw the test failures in multiple PRs e.g. http://github.com/open-telemetry/opentelemetry-collector-contrib/actions/runs/13527883596/job/37803241973

=== Failed
=== FAIL: . TestCollectEndpointsAllConfigSettings (11.00s)
    extension_test.go:112: 
        	Error Trace:	/home/runner/work/opentelemetry-collector-contrib/opentelemetry-collector-contrib/extension/observer/kafkatopicsobserver/extension_test.go:112
        	Error:      	Not equal: 
        	            	expected: []observer.Endpoint{observer.Endpoint{ID:"topic1", Target:"topic1", Details:(*observer.KafkaTopic)(0x2464d80)}, observer.Endpoint{ID:"topic2", Target:"topic2", Details:(*observer.KafkaTopic)(0x2464d80)}}
        	            	actual  : []observer.Endpoint{observer.Endpoint{ID:"topic2", Target:"topic2", Details:(*observer.KafkaTopic)(0x2464d80)}, observer.Endpoint{ID:"topic1", Target:"topic1", Details:(*observer.KafkaTopic)(0x2464d80)}}
        	            	
        	            	Diff:
        	            	--- Expected
        	            	+++ Actual
        	            	@@ -1,2 +1,8 @@
        	            	 ([]observer.Endpoint) (len=2) {
        	            	+ (observer.Endpoint) {
        	            	+  ID: (observer.EndpointID) (len=6) "topic2",
        	            	+  Target: (string) (len=6) "topic2",
        	            	+  Details: (*observer.KafkaTopic)({
        	            	+  })
        	            	+ },
        	            	  (observer.Endpoint) {
        	            	@@ -6,8 +12,2 @@
        	            	   })
        	            	- },
        	            	- (observer.Endpoint) {
        	            	-  ID: (observer.EndpointID) (len=6) "topic2",
        	            	-  Target: (string) (len=6) "topic2",
        	            	-  Details: (*observer.KafkaTopic)({
        	            	-  })
        	            	  }
        	Test:       	TestCollectEndpointsAllConfigSettings

=== FAIL: . TestCollectEndpointsAllConfigSettings (re-run 1) (6.00s)
    extension_test.go:108: 
        	Error Trace:	/home/runner/work/opentelemetry-collector-contrib/opentelemetry-collector-contrib/extension/observer/kafkatopicsobserver/extension_test.go:108
        	Error:      	Not equal: 
        	            	expected: []observer.Endpoint{observer.Endpoint{ID:"topic1", Target:"topic1", Details:(*observer.KafkaTopic)(0x2464d80)}, observer.Endpoint{ID:"topic2", Target:"topic2", Details:(*observer.KafkaTopic)(0x2464d80)}}
make[2]: *** [../../../Makefile.Common:102: test] Error 1
make[1]: *** [Makefile:231: extension/observer/kafkatopicsobserver] Error 2
make: *** [Makefile:149: gotest] Error 2
        	            	actual  : []observer.Endpoint{observer.Endpoint{ID:"topic2", Target:"topic2", Details:(*observer.KafkaTopic)(0x2464d80)}, observer.Endpoint{ID:"topic1", Target:"topic1", Details:(*observer.KafkaTopic)(0x2464d80)}}
        	            	
        	            	Diff:
        	            	--- Expected
        	            	+++ Actual
        	            	@@ -1,2 +1,8 @@
        	            	 ([]observer.Endpoint) (len=2) {
        	            	+ (observer.Endpoint) {
        	            	+  ID: (observer.EndpointID) (len=6) "topic2",
        	            	+  Target: (string) (len=6) "topic2",
        	            	+  Details: (*observer.KafkaTopic)({
        	            	+  })
        	            	+ },
        	            	  (observer.Endpoint) {
        	            	@@ -6,8 +12,2 @@
        	            	   })
        	            	- },
        	            	- (observer.Endpoint) {
        	            	-  ID: (observer.EndpointID) (len=6) "topic2",
        	            	-  Target: (string) (len=6) "topic2",
        	            	-  Details: (*observer.KafkaTopic)({
        	            	-  })
        	            	  }
        	Test:       	TestCollectEndpointsAllConfigSettings

DONE 2 runs, 9 tests, 2 failures in 26.199s
Copy link
Contributor

Pinging code owners:

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

@wojtekzyla
Copy link
Contributor

Fixing it #38218.

shalper2 pushed a commit to shalper2/opentelemetry-collector-contrib that referenced this issue Feb 26, 2025
#### Description
Fixing a flaky test

#### Link to tracking issue
Fixes open-telemetry#38192
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants