-
Notifications
You must be signed in to change notification settings - Fork 2.7k
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
OpenTelemetry gRPC OTLP traces exporter sometimes throws NPE on app shutdown when HTTP2 connection stream is closed #41351
Comments
/cc @alesj (grpc), @brunobat (opentelemetry,tracing), @cescoffier (grpc), @radcortez (opentelemetry,tracing) |
Can you try #41438 please? |
Avoid exporter related exceptions when application has been shutdown
Cool, let me know how it goes |
Fixes: quarkusio#41351 (cherry picked from commit 39fd819)
Fixes: quarkusio#41351 (cherry picked from commit 39fd819)
With 3.8.6 I've seen this:
It's not stacktrace like in the original report, but still something is not ok. CC @geoand I've seen this in NATIVE mode, not yet in JVM mode. Faster on startup, faster on shutdown :) ? |
This isn't necessary an indication that something went wrong - it could just be that the application started up and shutdown before any traces could be exported |
Correct. Server was shutting down, the event loop was down already and no spans could be exported. |
Describe the bug
I have app where I mock OTel collector with a Vert.x gRPC server so that I can avoid running container where I don't need to. I can see exported traces alright, but when Quarkus app is shutting down, sometimes can see logged NPE. The NPE doesn't affect me (though it fails my test that checks log), but looking at the error, I'm not really sure how my mock could cause that.
Expected behavior
I wonder if I have a wrongly written this gRPC server, but the error is bit strange. I'd prefer someone to check it. I tried it with a Jaeger container and could not reproduce the issue. On the other hand, as I think there is a race, it's logical that race cannot be reproduced in some scenarios.
Actual behavior
How to Reproduce?
Steps to reproduce the behavior:
git clone git@github.com:michalvavrik/quarkus-startstop.git -b feature/make-app-more-real-latest-repro
cd quarkus-startstop
mvn clean verify -pl testsuite -Dtest=StartStopTest#fullMicroProfileJVM -Dstart-stop.iterations=25
With branch
feature/make-app-more-real-latest-repro
I reproduced it only once, however I consider it important as there, the use case is very simple, it's just a gRPC server that inspect exported traces. No magic.UPDATE: I already managed to reproduce it few times on the
feature/make-app-more-real-latest-repro
branch.I also have a branch where at one point, I reproduced it almost every single time, try
git checkout feature/make-app-real-repro
. In this branch, there is more noise that is unnecessary for my tests.Output of
uname -a
orver
Fedora 38
Output of
java -version
OpenJDK 21
Quarkus version or git rev
999-SNAPSHOT
Build tool (ie. output of
mvnw --version
orgradlew --version
)Apache Maven 3.9.4
Additional information
No response
The text was updated successfully, but these errors were encountered: