Galleon layer for JBoss Diagnostic Reporting support

In  jdr wf-galleon

Overview

The JBoss Diagnostic Reporting (JDR) subsystem enables the gathering of diagnostic data to aid in troubleshooting. JBoss EAP subscribers can provide this information to Red Hat when requesting support.

The diagnosis information is generated by using the following operation:

[standalone@localhost:9990 /] /subsystem=jdr:generate-jdr-report()

Users are also able to generate the diagnostic information via command line executing the jdr.sh script located at $WFLY_HOME/bin/ directory. This script accepts the following options:

$WFLY_HOME/bin/jdr.sh --help
usage: jdr.{sh,bat,ps1} [options]

JBoss Diagnostic Reporter (JDR) is a subsystem built to collect information to aid in troubleshooting. The jdr script is a utility for generating JDR reports.
-c,--config <arg>     Configuration file of the server if it is not running.
-h,--help             Display this message and exit
-H,--host <arg>       hostname that the management api is bound to. (default: localhost)
-p,--port <arg>       port that the management api is bound to. (default: 9990)
-s,--protocol <arg>   Protocol that is used to connect. Can be remote, http or https (default: http)

The availability of a management interface is optional. If there is not a management interface available, the jdr.{sh,bat,ps1} script is still able to extract some information invoking the embedded server internally.

The goal of this feature is to supply a Galleon layer which will be responsible for providing the JDR subsystem.

The following is a configuration example of the WildFly bootable JAR Maven plugin to provision a server with the jdr layer and the core-tools layer, which brings in the jboss-cli.sh script that can be used to connect to the server via the command line in order to generate a diagnostic report through the JDR subsystem:

<plugin>
    <groupId>org.wildfly.plugins</groupId>
    <artifactId>wildfly-jar-maven-plugin</artifactId>
    <configuration>
        <feature-pack-location>wildfly@maven(org.jboss.universe:community-universe)#${version.wildfly}</feature-pack-location>
        <layers>
            <layer>jdr</layer>
            <layer>core-tools</layer>
        </layers>
    </configuration>
    <executions>
        <execution>
            <goals>
                <goal>package</goal>
            </goals>
        </execution>
    </executions>
</plugin>

Requirements

Hard Requirements

  • The Galleon layer must provide the provisioning of the JDR subsystem.

  • The provisioning tool will be responsible for providing the bash scripts to generate the diagnosis information - i.e. jdr.{sh,bat,ps1} - and make those available in the following filesystem location: $WFLY_HOME/bin/.

  • The Galleon layer will depend optionally on secure-management layer. This layer will allow the users to configure a secure management interface to connect to the server via jdr.sh. If a user wants to connect via CLI, they have to add core-tools layer to their provision configuration.

Nice-to-Have Requirements

N/A

Non-Requirements

N/A

Test Plan

The test coverage of the Galleon layer added by this proposal is divided in two main groups:

  1. Testing the Galleon layer provisioning. This testing is done by LayersTestCase. The testsuite will be modified to add a new server provisioned with this layer in isolation and with this layer combined with all the layers. For each kind of provisioning, this test does the following:

    1. Verifies the provisioned modules are the expected ones.

    2. Verifies the provisioned server starts successfully.

  2. Execution of WildFly tests related to the feature provisioned by this layer. Reuse the existing tests available on the WildFly test suite, which are directly testing this layer functionalities, and execute them on a server installation provisioned with this layer.

Community Documentation

Community documentation plan is to add the layer to WildFly Galleon layers in the section it belongs to.

Release Note Content

A Galleon layer to supply the JBoss Diagnostic Reporter (JDR) subsystem.