During startup of JVM(s) 'WFLYCTL0216: Management resource '[("subsystem" => "datasources")]' not found' observed in JBoss EAP when Dynatrace is enabled

Solution Verified - Updated

Environment

  • Red Hat JBoss Enterprise Application Platform (EAP)
    • 7
  • Red Hat Single Sign-On (RH-SSO)
    • 7
  • Openshift

Issue

  • Observing errors like the following during JVM startup
... ERROR [org.jboss.as.controller.management-operation] (oneagentperiodiceventsmanaged) WFLYCTL0013: Operation ("read-attribute") failed - address: ([
    ("subsystem" => "datasources"),
    ("data-source" => "MYDS")
]) - failure description: "WFLYCTL0216: Management resource '[(\"subsystem\" => \"datasources\")]' not found"
  • We are using Dynatrace monitoring with JBoss EAP and seeing errors like this before JBoss EAP has started:
... ERROR [org.jboss.as.controller.management-operation] (oneagentperiodiceventsmanaged) WFLYCTL0013: Operation ("read-attribute") failed - address: ([
    ("subsystem" => "batch-jberet"),
    ("thread-pool" => "batch")
]) - failure description: "WFLYCTL0216: Management resource '[(\"subsystem\" => \"batch-jberet\")]' not found"
...
ERROR [org.jboss.as.controller.management-operation] (oneagentperiodiceventsmanaged) WFLYCTL0013: Operation ("read-attribute") failed - address: ([
    ("subsystem" => "ejb3"),
    ("thread-pool" => "default")

Resolution

Dynatrace not in OpenShift

Dynatrace is trying to call services before EAP is started

  • The ERRORs can be ignored if they are not causing a problem beyond the log messages
  • Contact Dynatrace Support for further assistance. It seems the Dynatrace Support is aware of this issue, indicating that the early start of the monitoring for a JBoss application is a well known issue and that one can delay the start for one jvm server instance (or pod) with the environment variable DT_DEBUGFLAGS="optionDelayJmxMetricsMinJava=300".
    This environment variable needs to be set at OS level ( Ex., For RHEL, one can set it in .bash_profile)

Dynatrace in OpenShift

The same as above when not in OpenShift except:

Notes

  • The errors, when observed during JVM startup, may indicate that the monitoring agent is running too early though the datasource pools may be successfully deployed upon completion of JVM startup.
  • Any ERROR message where the thread oneagentperiodiceventsmanaged is trying to invoke a management operation before the JBoss EAP ... started message is logged indicate the same Dynatrace issue trying to invoke management operations before EAP is started.
INFO  [org.jboss.as] (Controller Boot Thread) WFLYSRV0025: JBoss EAP 7.4.6.GA (WildFly Core 15.0.15.Final-redhat-00001) started

Root Cause

Diagnostic Steps

Components
Category

This solution is part of Red Hat’s fast-track publication program, providing a huge library of solutions that Red Hat engineers have created while supporting our customers. To give you the knowledge you need the instant it becomes available, these articles may be presented in a raw and unedited form.