Tomcat does not register MBeans for XADataSource

Solution Unverified - Updated -

Issue

  • We've configured a datasource of type javax.sql.XADataSource in Tomcat, but there are no "tomcat.jdbc" MBeans registered for it. The mbeans appear when switching it to a javax.sql.DataSource:
  <Resource name="jdbc/TestDB" type="javax.sql.XADataSource"
            factory="org.apache.tomcat.jdbc.pool.DataSourceFactory"
            auth="Container" 
            username="postgres"
            password="postgres"
            maxActive="100"
            minIdle="10"
            jmxEnabled="true"
            driverClassName="org.postgresql.Driver"
            url="jdbc:postgresql://localhost:5432/test" />

Environment

  • Red Hat JBoss Enterprise Web Sever (JWS) 3.x
  • Tomcat
    • 7.0.x
    • 8.0.x

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
Close

Welcome! Check out the Getting Started with Red Hat page for quick tours and guides for common tasks.