Get Datasource Class Information
Overview
The JDBC datasource-class is the recommended way to set up the DataSource connections in the WildFly datasources subsystem,
but it requires user to know what connection-properties are defined in the datasource-class.
This feature will facilitate it to show basic connection properties information somehow.
Issue Metadata
Issue:
Related Issues:
Dev Contacts:
QE Contacts:
Affected Projects or Components:
- 
WildFly 
Requirements
- 
One runtime only attribute is introduced for this information with name: datasource-class-info
- 
The information will be integrated in the output of the operation: /subsystem=datasources/jdbc-driver=<JDBC-DRIVER>:read-resource(include-runtime=true)
Example of the information for h2 JDBC dirver is following:
[standalone@localhost:9990 /] /subsystem=datasources/jdbc-driver=h2:read-resource(include-runtime=true)
{
    "outcome" => "success",
    "result" => {
        "datasource-class-info" => [{"org.h2.jdbcx.JdbcDataSource" => {
            "URL" => "java.lang.String",
            "description" => "java.lang.String",
            "loginTimeout" => "int",
            "password" => "java.lang.String",
            "url" => "java.lang.String",
            "user" => "java.lang.String"
        }}],
        ......
    }
}- 
The output is a list type of DMR contains maximum 2 elements with DMR type as Object. - 
One element is for the datasource-classif any, the other element is for thexa-datasource-classif any.
- 
The key is the Java FQCN of the (xa-)datasource-class.
- 
The value is another Object DMR which contains connection-property name and Java FQCN mappings. 
- 
The connection-property names are sorted alphabetically. 
 
- 
- 
The current model version of datasourcessubsystem should bump up to indicate the model changes.
- 
There is no domain transformer needed. 
- 
In domain mode, if the JDBC driver module is not installed on a host or the JDBC driver deployment is not deployed in a server group, the datasource-class-infowill be ignored when calling against that host/server.
- 
The /subsystem=datasources:get-installed-driver(driver-name=xx)and/subsystem=datasources/:installed-drivers-list()should display these properties too if(xa-)datasource-classis defined.
Test Plan
- 
DataSourceClassInfoTestCase.java will be created for the integration test in the folder: testsuite/integration/basicin WildFly full repository
- 
The test covers the operations: read-resource(include-runtime=true)andread-attribute(name=datasource-class-info)forh2JDBC driver to get expected result.