[AS7-1370]  Domain Management - Add support for database authentication.

Added support for database authentication and authorization both in standalone and domain mode. For standalone mode both the configuration with using data source and jdbc outbound connection works, and for the domain mode only the jdbc outbound configuration is valid, by defining a database connection based on the module name, driver name, url, username and password.

For enable the database authentication add following xml to either standalone.xml or host.xml
<management>
         <security-realms>
            <security-realm name="ManagementRealm">
                <authentication>
                    <local default-user="$local"/>
                    <database connection="db" plain-text="true">
            <simple-select-users table="users" username-field="user" password-field="password"/>
                        <!-- sql-select-users sql="select user,password from users where user = ?"/ -->
                    </database>
                </authentication>
            </security-realm>
            <security-realm name="ApplicationRealm">
                <authentication>
                    <local default-user="$local" allowed-users="*"/>
                    <database connection="db" plain-text="true">
                        <sql-select-users sql="select user,password from users where user = ?"/>
                    </database>
                </authentication>
                <authorization>
                    <database connection="db">
            <simple-select-roles table="roles" username-field="user" roles-field="role"/>
                        <!-- sql-select-roles sql="select role from roles where user = ?"/ -->
                    </database>
                </authorization>
            </security-realm>
        </security-realms>
        <outbound-connections>
            <database>
        <!-- database-datasource name="db" data-source="java:jboss/datasources/auth"/ -->
                <connection name="db" module="com.h2database.h2" driver="org.h2.Driver" url="jdbc:h2:tcp://localhost//tmp/test" username="sa" password="" max-pool-size="20" min-pool-size="10"/>
            </database>
        </outbound-connections>
        <management-interfaces>
            <native-interface security-realm="ManagementRealm">
                <socket interface="management" port="${jboss.management.native.port:9999}"/>
            </native-interface>
            <http-interface security-realm="ManagementRealm">
                <socket interface="management" port="${jboss.management.http.port:9990}"/>
            </http-interface>
        </management-interfaces>
    </management>'

For creating table that match the configuration use the sql statement below :

For starting H2 in server mode call the modules/com/h2database/h2/main/java -cp *.jar org.h2.tools.Server

CREATE TABLE USERS(user VARCHAR(32) PRIMARY KEY,   password VARCHAR(255));
CREATE TABLE ROLES(user VARCHAR(32) PRIMARY KEY,   role VARCHAR(255));

Please take a look on the SimpleAttributeDefinition for DatabaseConnectionResourceDefinition, DatabaseAuthenticationResourceDefinition and DatabaseAuthorizationResourceDefinition I'm bit unsure if I got them 100% correct
The DatabaseConnectionManagerService has 3 values  MAX_WAIT_FOR_LOCK = 60000, MAX_WAIT_FOR_UNUSED_CONNECTIONS = 60000 and MAX_DELAY_FOR_REPEAER_REQUEST = 300000 this might need an extra review.