Red Hat Bugzilla – Full Text Bug Listing
|Summary:||Tomcat plugin missing support for JNDI configured Datasources|
|Product:||[JBoss] JBoss Enterprise Web Server 2||Reporter:||David Webster <dawebster>|
|Component:||JON Plugin||Assignee:||Jean-frederic Clere <jclere>|
|Status:||ASSIGNED ---||QA Contact:||Jan Stefl <jstefl>|
|Version:||2.0.0||CC:||dawebster, fgoldefu, hbrock, hrupp, jclere, jdoyle, jshaughn, loleary, mfoley, myarboro, smumford|
|Fixed In Version:||Doc Type:||Known Issue|
The JBoss Enterprise Web Server’s Tomcat plugin is used to expose configured JNDI Datasources. The plugin is expected to provide relevant Datasource/Connection Pool information but instead it does not provide any information for JNDI Tomcat Datasources. This is a known issue in JBoss Enterprise Web Server 3.0 and there is currently no workaround for this problem.
|oVirt Team:||---||RHEL 7.3 requirements from Atomic Host:|
|Bug Depends On:|
Description David Webster 2011-05-10 13:03:26 EDT
Created attachment 498104 [details] Standard UP MBean plugin which includes a Tomcat datasource component Description of problem: Current Tomcat plugin does expose configured JNDI Datasources. Version-Release number of selected component (if applicable): RHQ 3.x, RHQ 4.x, JON 2.4, JON 3.- How reproducible: N/A Actual results: Tomcat (JBoss EWS) plugin does not provide any information for configured JNDI Tomcat Datasources. Expected results: The same kind of Datasource/Connection Pool info available for JBoss EAP/EWP should be available for JBoss EWS (Tomcat). Additional info: Attached is a set of standard custom JMX plugins we use at Union Pacific. They include a Spring Datasource, Identity (Who Am I) MBean, Log4J, our internal ESB configuration, but of interest to this ticket a EWSDatasourceComponent that exposes the Tomcat Datasources.
Comment 1 Heiko W. Rupp 2011-05-25 04:59:00 EDT
David, could you please add the rhq-plugin.xml snippet that is used for the EWSDatasourceComponent ? And if this is using a special discovery class that one as well (But then I guess, you are just using the standard MBeanResourceDiscoveryComponent ) ?
Comment 3 David Webster 2011-06-03 17:07:03 EDT
Oops, think I sent the wrong rhqplugin.xml. I have two versions of our standard JMX plugin, one that is designed for Stand Alone JVMs that would not have the Tomcat Datasource supported and essentially the same one but that contains the Tomcat Datasource for the container instances. Attached is snippet with the Tomcat Datasource service.
Comment 4 David Webster 2011-06-03 17:09:19 EDT
Created attachment 502909 [details] rhq-plugin.xml snippet with Tomcat Datasource service Missing rhq-plugin.xml code to support the Tomcat Datasource that matches the EWSDatasourceComponent and Discovery java code.
Comment 5 Jay Shaughnessy 2012-01-09 15:49:52 EST
master commit 791205857b2e3550e51ea1e101b8a4704ebfad33 Added support for Datasources. Tomcat allows DS Resource declaration at the global/host/app level. A global DS is available to all apps, a host DS is available to all apps for that host, and then at the app level, just the declaring app. As such Tomcat creates DS Mbeans at the app level, one for each DS available to the app. This structure is reflected in the updated Tomcat resource hierarchy. Although there is seeming redundancy for global and host level datasources, it seems to best reflect the TC intents, and also the underlying mbeans. For more on configuring datasources see: http://tomcat.apache.org/tomcat-6.0-doc/jndi-datasource-examples-howto.html http://tomcat.apache.org/tomcat-6.0-doc/config/context.html
Comment 8 Larry O'Leary 2013-04-12 15:07:05 EDT
This looks like it may have already been done in the 3.1.2 (EWS 2.0) Tomcat plug-in. Someone should verify and QE should confirm.
Comment 9 Misha H. Ali 2013-06-13 18:44:24 EDT
Setting flag to nominate for release notes (2.0.1)
Comment 10 Misha H. Ali 2013-06-14 00:45:23 EDT
Added release note information. Adding assignee to confirm or correct this information and suggest a workaround, if one exists.
Comment 11 Libor Fuka 2013-06-14 02:06:13 EDT
It looks like RFE for future releases and not bug and should be excluded from EWS 2.0.1 release notes. What do you think Jean-Frederic ?
Comment 14 Jean-frederic Clere 2013-06-27 00:45:03 EDT
that is a know issue.
Comment 17 Jean-frederic Clere 2013-09-30 04:42:26 EDT
The patch looks to be in the branch, weird.
Comment 20 Jean-frederic Clere 2013-10-01 05:03:49 EDT
I have added in the default host in server.xml: +++ <Context path="toto"> <Resource name="jdbc/EmployeeDB" auth="Container" type="javax.sql.DataSource" description="Employees Database for HR Applications"/> </Context> +++ Jconsole displays the resource but it doesn't appair in RHQ (I have tried master).
Comment 21 Jean-frederic Clere 2014-03-10 05:08:48 EDT
After a double look comment #20 looks to be wrong. how should we test the feature?
Comment 22 Jay Shaughnessy 2014-06-13 10:08:16 EDT
Sorry for the late reply for info. In general in the UI you manually add resources from the parent's detail view, under the Inventory->Child Resources subtab.
Comment 23 Jean-frederic Clere 2014-06-17 07:20:50 EDT
Created attachment 909531 [details] Actual screen shot for the child resource.
Comment 24 Jean-frederic Clere 2014-06-17 07:25:32 EDT
Do you mean that there should be an add in the screen shot? Where?
Comment 25 Jay Shaughnessy 2014-06-17 09:12:34 EDT
Sorry if I confused things. The "Need Info" above asked me, "Where can i find the option for adding datasource in JON UI ?". The real answer is that you won't find it because there is no way that I see to add a Datasource manually via the UI. From what I can see a Datasource resource can show up under a WAR whenever TC is configured to provide that DS to the WAR, whether it's globally declared or packaged in the WAR itself. It will be autodiscovered. My prior answer was more a general response, yes, if a parent resource type allows manual import of a child resource, it would be a button in the view you have in the screenshot, but it's not relevant here.
Comment 26 Jean-frederic Clere 2014-07-02 06:11:45 EDT
Acording to JAy comment I haven't fixed the whole BZ.
Comment 27 Jean-frederic Clere 2014-07-09 07:32:31 EDT
Mandar, please keep it as known issue.