EXECUTE permission was denied but the connection is correctly set up with exec authoriy when MSSQL is used with JBossEAP

Solution Unverified - Updated -

Issue

We are getting the following errors:

 javax.transaction.xa.XAException: com.microsoft.sqlserver.jdbc.SQLServerException: The EXECUTE permission was denied on the object 'xp_sqljdbc_xa_start', database 'master', schema 'dbo'.
    at com.microsoft.sqlserver.jdbc.SQLServerXAResource.DTC_XA_Interface(SQLServerXAResource.java:742)
    at com.microsoft.sqlserver.jdbc.SQLServerXAResource.start(SQLServerXAResource.java:774)
    at org.jboss.jca.adapters.jdbc.xa.XAManagedConnection.start(XAManagedConnection.java:263)
...
ARJUNA016061: TransactionImple.enlistResource - XAResource.start returned: XAException.XAER_RMERR for < formatId=131077, gtrid_length=29, bqual_length=36, tx_uid=0:ffffac172055:7efabf78:5cdc6a60:cba4, node_name=1, branch_uid=0:ffffac172055:7efabf78:5cdc6a60:cbe4, subordinatenodename=null, eis_name=java:jboss/datasources/KeycloakDS >: javax.transaction.xa.XAException: com.microsoft.sqlserver.jdbc.SQLServerException: The connection is closed.
    at com.microsoft.sqlserver.jdbc.SQLServerXAResource.DTC_XA_Interface(SQLServerXAResource.java:742)
    at com.microsoft.sqlserver.jdbc.SQLServerXAResource.start(SQLServerXAResource.java:774)
    at org.jboss.jca.adapters.jdbc.xa.XAManagedConnection.start(XAManagedConnection.java:263)
...
ARJUNA016027: Local XARecoveryModule.xaRecovery got XA exception XAException.XAER_RMERR: javax.transaction.xa.XAException: com.microsoft.sqlserver.jdbc.SQLServerException: The EXECUTE permission was denied on the object 'xp_sqljdbc_xa_recover', database 'master', schema 'dbo'.
    at com.microsoft.sqlserver.jdbc.SQLServerXAResource.DTC_XA_Interface(SQLServerXAResource.java:742)
    at com.microsoft.sqlserver.jdbc.SQLServerXAResource.recover(SQLServerXAResource.java:823)
    at org.jboss.jca.adapters.jdbc.xa.XAManagedConnection.recover(XAManagedConnection.java:373)
    at org.jboss.jca.core.tx.jbossts.XAResourceWrapperImpl.recover(XAResourceWrapperImpl.java:185)
    at com.arjuna.ats.internal.jta.recovery.arjunacore.XARecoveryModule.xaRecoveryFirstPass(XARecoveryModule.java:609)
...

Environment

  • Red Hat JBoss Enterprise Application Platform (EAP)
    • 5
    • 6
    • 7
  • Red Hat Single Sign-On (RH-SSO)
    • 7
  • Microsoft SQL Server

Subscriber exclusive content

A Red Hat subscription provides unlimited access to our knowledgebase of over 48,000 articles and solutions.

Current Customers and Partners

Log in for full access

Log In