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

[BUG] contrib/google.golang.org/grpc: tests fail with shuffling enabled #2469

Open
nsrip-dd opened this issue Dec 26, 2023 · 0 comments
Open
Labels
bug unintended behavior that has to be fixed

Comments

@nsrip-dd
Copy link
Contributor

nsrip-dd commented Dec 26, 2023

As of main at commit f986cc5, the gRPC contrib tests fail with shuffling enabled (see #2265). There appears to be interference between the TestClientNamingSchema and TestIssue2050 test cases.

Example:

%  go test -run='(TestClientNamingSchema|TestIssue2050)' -shuffle=1703619841795279000 ./contrib/google.golang.org/grpc
-test.shuffle 1703619841795279000
2023/12/26 14:44:20 Datadog Tracer v1.60.0-dev WARN: No global service name was detected. GRPC Server may have been created before calling tracer.Start(). Will dynamically fetch service name for every span. Note this may have a slight performance cost, it is always recommended to start the tracer before initializing any traced packages.
2023/12/26 14:44:20 Datadog Tracer v1.60.0-dev WARN: No global service name was detected. GRPC Server may have been created before calling tracer.Start(). Will dynamically fetch service name for every span. Note this may have a slight performance cost, it is always recommended to start the tracer before initializing any traced packages.
2023/12/26 14:44:20 Datadog Tracer v1.60.0-dev WARN: DIAGNOSTICS Unable to reach agent intake: Post "http://localhost:8126/v0.4/traces": dial tcp 127.0.0.1:8126: connect: connection refused
2023/12/26 14:44:20 Datadog Tracer v1.60.0-dev INFO: DATADOG TRACER CONFIGURATION {"date":"2023-12-26T14:44:20-05:00","os_name":"darwin","os_version":"13.6.2","version":"v1.60.0-dev","lang":"Go","lang_version":"go1.20.7","env":"","service":"some-dd-service","agent_url":"http://localhost:8126/v0.4/traces","agent_error":"Post \"http://localhost:8126/v0.4/traces\": dial tcp 127.0.0.1:8126: connect: connection refused","debug":false,"analytics_enabled":false,"sample_rate":"NaN","sample_rate_limit":"disabled","sampling_rules":null,"sampling_rules_error":"","service_mappings":null,"tags":{"runtime-id":"4862f707-9373-4515-aada-a161bf77d910"},"runtime_metrics_enabled":false,"health_metrics_enabled":false,"profiler_code_hotspots_enabled":true,"profiler_endpoints_enabled":true,"dd_version":"","architecture":"arm64","global_service":"some-dd-service","lambda_mode":"false","appsec":false,"agent_features":{"DropP0s":false,"Stats":false,"DataStreams":false,"StatsdPort":0},
[ ... a bunch of integration info omitted ... ]
2023/12/26 14:44:22 Datadog Tracer v1.60.0-dev ERROR: Loading features: Get "http://localhost:8126/info": dial tcp 127.0.0.1:8126: connect: connection refused (occurred: 26 Dec 23 14:44 EST)
2023/12/26 14:44:22 Datadog Tracer v1.60.0-dev ERROR: failure sending traces (attempt 1), will retry: Post "http://localhost:8126/v0.4/traces": dial tcp 127.0.0.1:8126: connect: connection refused (occurred: 26 Dec 23 14:44 EST)
2023/12/26 14:44:22 Datadog Tracer v1.60.0-dev ERROR: lost 2 traces: <nil> (occurred: 26 Dec 23 14:44 EST)
--- FAIL: TestClientNamingSchema (0.86s)
    --- FAIL: TestClientNamingSchema/ServiceName (0.64s)
        --- FAIL: TestClientNamingSchema/ServiceName/WithDefaults (0.22s)
            --- FAIL: TestClientNamingSchema/ServiceName/WithDefaults/v1 (0.11s)
                namingschematest.go:101: 
                    	Error Trace:	/Users/nick.ripley/repos/dd-trace-go/contrib/internal/namingschematest/namingschematest.go:116
                    	            				/Users/nick.ripley/repos/dd-trace-go/contrib/internal/namingschematest/namingschematest.go:101
                    	Error:      	Not equal: 
                    	            	expected: "grpc.client"
                    	            	actual  : "some-dd-service"
                    	            	
                    	            	Diff:
                    	            	--- Expected
                    	            	+++ Actual
                    	            	@@ -1 +1 @@
                    	            	-grpc.client
                    	            	+some-dd-service
                    	Test:       	TestClientNamingSchema/ServiceName/WithDefaults/v1
                    	Messages:   	incorrect service name for span: grpc.client.request
                namingschematest.go:101: 
                    	Error Trace:	/Users/nick.ripley/repos/dd-trace-go/contrib/internal/namingschematest/namingschematest.go:116
                    	            				/Users/nick.ripley/repos/dd-trace-go/contrib/internal/namingschematest/namingschematest.go:101
                    	Error:      	Not equal: 
                    	            	expected: "grpc.client"
                    	            	actual  : "some-dd-service"
                    	            	
                    	            	Diff:
                    	            	--- Expected
                    	            	+++ Actual
                    	            	@@ -1 +1 @@
                    	            	-grpc.client
                    	            	+some-dd-service
                    	Test:       	TestClientNamingSchema/ServiceName/WithDefaults/v1
                    	Messages:   	incorrect service name for span: grpc.client.request
                namingschematest.go:101: 
                    	Error Trace:	/Users/nick.ripley/repos/dd-trace-go/contrib/internal/namingschematest/namingschematest.go:116
                    	            				/Users/nick.ripley/repos/dd-trace-go/contrib/internal/namingschematest/namingschematest.go:101
                    	Error:      	Not equal: 
                    	            	expected: "grpc.client"
                    	            	actual  : "some-dd-service"
                    	            	
                    	            	Diff:
                    	            	--- Expected
                    	            	+++ Actual
                    	            	@@ -1 +1 @@
                    	            	-grpc.client
                    	            	+some-dd-service
                    	Test:       	TestClientNamingSchema/ServiceName/WithDefaults/v1
                    	Messages:   	incorrect service name for span: grpc.client.request
                namingschematest.go:101: 
                    	Error Trace:	/Users/nick.ripley/repos/dd-trace-go/contrib/internal/namingschematest/namingschematest.go:116
                    	            				/Users/nick.ripley/repos/dd-trace-go/contrib/internal/namingschematest/namingschematest.go:101
                    	Error:      	Not equal: 
                    	            	expected: "grpc.client"
                    	            	actual  : "some-dd-service"
                    	            	
                    	            	Diff:
                    	            	--- Expected
                    	            	+++ Actual
                    	            	@@ -1 +1 @@
                    	            	-grpc.client
                    	            	+some-dd-service
                    	Test:       	TestClientNamingSchema/ServiceName/WithDefaults/v1
                    	Messages:   	incorrect service name for span: grpc.client.request
FAIL
FAIL	gopkg.in/DataDog/dd-trace-go.v1/contrib/google.golang.org/grpc	3.289s
FAIL
@nsrip-dd nsrip-dd added the bug unintended behavior that has to be fixed label Dec 26, 2023
@github-actions github-actions bot added the needs-triage New issues that have not yet been triaged label Dec 26, 2023
@felixge felixge removed the needs-triage New issues that have not yet been triaged label Jan 5, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug unintended behavior that has to be fixed
Projects
None yet
Development

No branches or pull requests

2 participants