The applications in this repository reproduce the problem described in #665:
- The application java-melody-application is a no-op war that simply includes java-melody.
- The jdbc-application is a war with a single endpoint that simply opens and closes a jdbc connection. This application does not include Java-Melody.
In order to produce the stack trace in the issue the following steps are need to be made:
- Set the system-property
javamelody.datasources
tojava:jboss/datasources/ExampleDS
(this is only required as the default datasource in Wildfly does not follow Java Melody's jdbc/ convention for datasources) - Deploy java-melody-application and jdbc-application on Wildfly
- Open http://localhost:8080/jdbc-application-1.0.0-SNAPSHOT: This should suceed
- Undeploy java-melody-application and deploy it again
- Open http://localhost:8080/jdbc-application-1.0.0-SNAPSHOT: This should fail now
with a NPE in
ServletContextImpl
as shown in the stack trace