-
Bug
-
Resolution: Done
-
Major
-
None
-
None
I encountered a situation where a deployment is causing an exception (not enough threads).
However it was impossible to see it because another exception is thrown in the catch block.
Here is how the stack trace looks like:
java.lang.RuntimeException: java.lang.NullPointerException
at org.wildfly.extension.undertow.deployment.UndertowDeploymentService$1.run(UndertowDeploymentService.java:81)
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) [rt.jar:1.8.0_392]
at java.util.concurrent.FutureTask.run(FutureTask.java:266) [rt.jar:1.8.0_392]
at org.jboss.threads.ContextClassLoaderSavingRunnable.run(ContextClassLoaderSavingRunnable.java:35)
at org.jboss.threads.EnhancedQueueExecutor.safeRun(EnhancedQueueExecutor.java:1990)
at org.jboss.threads.EnhancedQueueExecutor$ThreadBody.doRunTask(EnhancedQueueExecutor.java:1486)
at org.jboss.threads.EnhancedQueueExecutor$ThreadBody.run(EnhancedQueueExecutor.java:1377)
at java.lang.Thread.run(Thread.java:750) [rt.jar:1.8.0_392]
at org.jboss.threads.JBossThread.run(JBossThread.java:513)
Caused by: java.lang.RuntimeException: java.lang.NullPointerException
at io.undertow.servlet.core.DeploymentManagerImpl.undeploy(DeploymentManagerImpl.java:690)
at org.wildfly.extension.undertow.deployment.UndertowDeploymentService.startContext(UndertowDeploymentService.java:101)
at org.wildfly.extension.undertow.deployment.UndertowDeploymentService$1.run(UndertowDeploymentService.java:78)
... 8 more
Caused by: java.lang.NullPointerException
at io.undertow.servlet.core.DeploymentImpl.destroy(DeploymentImpl.java:291)
at io.undertow.servlet.core.DeploymentManagerImpl$4.call(DeploymentManagerImpl.java:683)
at io.undertow.servlet.core.DeploymentManagerImpl$4.call(DeploymentManagerImpl.java:673)
at io.undertow.servlet.core.ServletRequestContextThreadSetupAction$1.call(ServletRequestContextThreadSetupAction.java:42)
at io.undertow.servlet.core.ContextClassLoaderSetupAction$1.call(ContextClassLoaderSetupAction.java:43)
at org.wildfly.extension.undertow.deployment.UndertowDeploymentInfoService$UndertowThreadSetupAction.lambda$create$0(UndertowDeploymentInfoService.java:1555)
at org.wildfly.extension.undertow.deployment.UndertowDeploymentInfoService$UndertowThreadSetupAction.lambda$create$0(UndertowDeploymentInfoService.java:1555)
at org.wildfly.extension.undertow.deployment.UndertowDeploymentInfoService$UndertowThreadSetupAction.lambda$create$0(UndertowDeploymentInfoService.java:1555)
at org.wildfly.extension.undertow.deployment.UndertowDeploymentInfoService$UndertowThreadSetupAction.lambda$create$0(UndertowDeploymentInfoService.java:1555)
at io.undertow.servlet.core.DeploymentManagerImpl.undeploy(DeploymentManagerImpl.java:688)
... 10 more
The hiding occurs because in UndertowDeploymentService, deploymentManager.undeploy() throws another exception (confirmed in debug).
Seems to be caused by https://github.com/wildfly/wildfly/commit/7915e344a1d7f723d23f641b1ba108316d78edae