How to view the modules a deployment depends upon in JBoss EAP 7 / 6

Solution Verified - Updated

Environment

  • Red Hat JBoss Enterprise Application Platform (EAP)
    • 7.x
    • 6.x

Issue

  • How can I view the modules a deployment depends upon in JBoss EAP 7?
  • How can I view the modules a deployment depends upon in JBoss EAP 6?
  • How can I trace a module's dependency hierarchy?
  • How can I trace classloading of EAP 6 modules?
  • Received
Caused by: java.lang.ClassNotFoundException: some.company.AnException from [Module ... from Service Module Loader]

Resolution

  1. Start jconsole from "$JBOSS_HOME/bin/"
  2. Connect to your JBoss EAP 6 instance
  3. Click on the "MBeans" tab
  4. Expand "jboss.modules"
  5. Expand "ModuleLoader"
  6. Expand "ServiceModuleLoader"
  7. Click on "Operations"
  8. Invoke "dumpModuleInformation" specifying the deployment name prefixed by deployment, for example: deployment.my.ear

Note: Make sure you look under "ServiceModuleLoader" and not "LocalModuleLoader" or "ModuleLoaderIntegration"

To dump the module information for all deployments:
Invoke the dumpAllModuleInformation

The getDependencies can also be invoked using the deployment.my.ear and returns a CompositeData[]

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.