Skip to content

[test][exporter/prometheus] TestPrometheusExporter failures #36139

@pjanotti

Description

@pjanotti

Component(s)

exporter/prometheus

Describe the issue you're reporting

A few instances of failures:

=== FAIL: . TestPrometheusExporter (0.00s)
    prometheus_test.go:87: 
        	Error Trace:	D:/a/opentelemetry-collector-contrib/opentelemetry-collector-contrib/exporter/prometheusexporter/prometheus_test.go:87
        	Error:      	Received unexpected error:
        	            	close tcp 127.0.0.1:8999: use of closed network connection
        	Test:       	TestPrometheusExporter

=== FAIL: . TestPrometheusExporter (re-run 1) (0.01s)
    prometheus_test.go:87: 
        	Error Trace:	D:/a/opentelemetry-collector-contrib/opentelemetry-collector-contrib/exporter/prometheusexporter/prometheus_test.go:87
        	Error:      	Received unexpected error:
        	            	close tcp 127.0.0.1:8999: use of closed network connection
        	Test:       	TestPrometheusExporter

DONE 2 runs, 73 tests, 2 failures in 361.711s

In quick glance this seems likely because the server using the port is actually launched in a goroutine and the port can be closed by shutdown before the server starts.

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions