[BUG] Uncaught exception received by Vert.x: java.lang.IllegalStateException: Result is already complete - possibly in VertxRequestWriteSubscriber #43399
Labels
Azure.Core
azure-core
customer-reported
Issues that are reported by GitHub users external to the Azure organization.
HttpClient
question
The issue doesn't require a change to the product in order to be resolved. Most issues start as that
Describe the bug
We have a Java application that is part of an "upload to Azure" flow. The uploader is a distinct component and is deployed to a Kubernetes cluster. The uploader, in current testing, is uploading to Azurite. We are conducting stress tests and I observed exactly 4 times, within about a 75 minute window, the below exception. It appeared immediately after a new upload was started. All 4 of these instances were uploading a 10mb file on the heels of either a 1mb, 10mb or 100mb file (roughly, by our logging). The upload still succeeded, which is important to note - there isn't an obvious failure - but as we continue testing and moving to higher environments, we need a degree of confidence there is no lurking issue here.
I fear there's some hard to characterize interaction between Apache Camel, Quarkus, Netty, Vert.x and the Azure library, perhaps a subtle race condition.
As the VertxRequestWriteSubscriber looks like a possible source of the exception, or at least a participant, I am filing this issue here in hopes someone can help confirm whether it's an actual issue or something safe to ignore.
We are not setting any properties specific to vert.x and do not have any custom code related to vert.x directly.
Thanks in advance.
Exception or Stack Trace
[io.qua.ver.cor.run.VertxCoreRecorder] (vert.x-eventloop-thread-0) Uncaught exception received by Vert.x: java.lang.IllegalStateException: Result is already complete
at io.vertx.core.Promise.fail(Promise.java:90)
at com.azure.core.http.vertx.implementation.VertxRequestWriteSubscriber.resetRequest(VertxRequestWriteSubscriber.java:137)
at com.azure.core.http.vertx.implementation.VertxRequestWriteSubscriber.lambda$write$1(VertxRequestWriteSubscriber.java:104)
at io.vertx.core.impl.future.FutureImpl$4.onFailure(FutureImpl.java:188)
at io.vertx.core.impl.future.FutureBase.lambda$emitFailure$1(FutureBase.java:75)
at io.netty.util.concurrent.AbstractEventExecutor.runTask(AbstractEventExecutor.java:173)
at io.netty.util.concurrent.AbstractEventExecutor.safeExecute(AbstractEventExecutor.java:166)
at io.netty.util.concurrent.SingleThreadEventExecutor.runAllTasks(SingleThreadEventExecutor.java:469)
at io.netty.channel.nio.NioEventLoop.run(NioEventLoop.java:569)
at io.netty.util.concurrent.SingleThreadEventExecutor$4.run(SingleThreadEventExecutor.java:994)
at io.netty.util.internal.ThreadExecutorMap$2.run(ThreadExecutorMap.java:74)
at io.netty.util.concurrent.FastThreadLocalRunnable.run(FastThreadLocalRunnable.java:30)
at [email protected]/java.lang.Thread.runWith(Thread.java:1596)
at [email protected]/java.lang.Thread.run(Thread.java:1583)
at org.graalvm.nativeimage.builder/com.oracle.svm.core.thread.PlatformThreads.threadStartRoutine(PlatformThreads.java:896)
at org.graalvm.nativeimage.builder/com.oracle.svm.core.thread.PlatformThreads.threadStartRoutine(PlatformThreads.java:872)
To Reproduce
I have not been able to reproduce this in a minimal project.
Code Snippet
N/A
Expected behavior
The exception should not occur, or if it does, extra information should be provided to make it clear whether the exception must be handled or if it is safe to ignore.
Screenshots
N/A
Setup (please complete the following information):
- OS: RHEL 8.9 / Kubernetes
- IDE: VSCode
- Library/Libraries:
- Java version: 17.0.13
- App Server/Environment: Kubernetes hosted Java application compiled under Quarkus/Graal to run natively
- Frameworks: Apache Camel, Quarkus, Netty, Vert.X, Azure Library
- verbose dependency tree (
mvn dependency:tree -Dverbose
)see attached
verbose_dependencies.txt
exception message, full stack trace, and any available logs
[io.qua.ver.cor.run.VertxCoreRecorder] (vert.x-eventloop-thread-0) Uncaught exception received by Vert.x: java.lang.IllegalStateException: Result is already complete
see above for full stack trace
Additional context
Add any other context about the problem here.
Information Checklist
Kindly make sure that you have added all the following information above and checkoff the required fields otherwise we will treat the issuer as an incomplete report
The text was updated successfully, but these errors were encountered: