Search code examples
datasourcexajboss-eap-7

JBoss EAP 7: xa transaction warning “No security domain defined for crash recovery” even with a security domain


I have a JBoss EAP 7.1 with some XA datasource.

The datasource has a security domain:

                <security>
                    <security-domain>encrypted-ds</security-domain>
                </security>

which makes use of the encrypted-password login module (for various political reasons):

            <security-domain name="encrypted-ds" cache-type="default">
                <authentication>
                    <login-module code="org.picketbox.datasource.security.SecureIdentityLoginModule" flag="required">
                        <module-option name="username" value="user_name_here"/>
                        <module-option name="password" value="some_hash_here"/>
                    </login-module>
                </authentication>
            </security-domain>

Yet, I get those cyclic warning messages when the server has started:

11:25:15,506 WARN  [org.jboss.jca.core.tx.jbossts.XAResourceRecoveryImpl] (Periodic Recovery) IJ000904: No security domain defined for crash recovery: java:/jdbc/myDataSource
11:25:15,511 WARN  [org.jboss.jca.core.tx.jbossts.XAResourceRecoveryImpl] (Periodic Recovery) IJ000905: Subject for crash recovery was null: java:/jdbc/myDataSource

This is similar, but not the same as question Wildfly xa transaction warning "No security domain defined for crash recovery" , as here, I have a username and an encrypted password, and a security domain. I can fathom why the system would consider there is no security domain nor subject/username.


Solution

  • I ended up using the JBoss Vault to manage the encrypted password. https://access.redhat.com/documentation/en-us/red_hat_jboss_enterprise_application_platform/7.0/html-single/how_to_configure_server_security/index#secure_passwords