Bug 1209558
Summary: | RtFilter never load vHostMappingFile from absolute or relative path in EAP 6 | ||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|
Product: | [JBoss] JBoss Operations Network | Reporter: | Dasharath Masirkar <dmasirka> | ||||||||||
Component: | Monitoring - CallTime | Assignee: | Michael Burman <miburman> | ||||||||||
Status: | CLOSED ERRATA | QA Contact: | Sunil Kondkar <skondkar> | ||||||||||
Severity: | high | Docs Contact: | |||||||||||
Priority: | unspecified | ||||||||||||
Version: | JON 3.3.1 | CC: | fbrychta, loleary, skondkar, spinder | ||||||||||
Target Milestone: | ER01 | Keywords: | Triaged | ||||||||||
Target Release: | JON 3.3.3 | ||||||||||||
Hardware: | Unspecified | ||||||||||||
OS: | Unspecified | ||||||||||||
Whiteboard: | |||||||||||||
Fixed In Version: | Doc Type: | Bug Fix | |||||||||||
Doc Text: | Story Points: | --- | |||||||||||
Clone Of: | Environment: | ||||||||||||
Last Closed: | 2015-07-30 16:41:48 UTC | Type: | Bug | ||||||||||
Regression: | --- | Mount Type: | --- | ||||||||||
Documentation: | --- | CRM: | |||||||||||
Verified Versions: | Category: | --- | |||||||||||
oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |||||||||||
Cloudforms Team: | --- | Target Upstream Version: | |||||||||||
Embargoed: | |||||||||||||
Attachments: |
|
Comment 1
Dasharath Masirkar
2015-04-07 16:33:11 UTC
(In reply to Dasharath Masirkar from comment #1) > Description of problem: > The RtFilter never load vHostMappingFile from absolute or relative path in > EAP 6. > > Version-Release number of selected component (if applicable): > 3.3.1 > > How reproducible: > Always > > Steps to Reproduce: > 1. Install and configure RtFilter in JBoss EAP 6 standalone server as per > https://access.redhat.com/documentation/en-US/ > Red_Hat_JBoss_Operations_Network/3.3/html-single/Users_Guide/index. > html#installing-rt-filters > > 2. Then Add following in web application web.xml : > > <filter> > <filter-name>RhqRtFilter</filter-name> > <filter-class>org.rhq.helpers.rtfilter.filter.RtFilter</filter-class> > <init-param> > <param-name>vHostMappingFile</param-name> > > <param-value>/opt/jboss-eap-6.2/standalone/configuration/vhost-mappings. > properties</param-value> > </init-param> > </filter> > > 3. Create > /opt/jboss-eap-6.2/standalone/configuration/vhost-mappings.properties file > with below configuration : > > jon.localhost.com = testvirtualserver > test1.example.com = testvirtualserver > > 4. Restart the JBoss EAP 6 server to reload the new changes. > > > Actual results: > > The RtFilter never load vHostMappingFile from absolute path > /opt/jboss-eap/jboss-eap-6.2/standalone/configuration/ and throw below > warning in EAP6 server.log: > > 22:36:33,806 WARN [org.rhq.helpers.rtfilter.filter.RtFilter] (ServerService > Thread Pool -- 51) Can't read vhost mappings from > /opt/jboss-eap/jboss-eap-6.2/standalone/configuration/vhost-mappings. > properties > > Expected results: > The RtFilter should load vHostMappingFile from absolute path > /opt/jboss-eap/jboss-eap-6.2/standalone/configuration/ without throwing any > warning. > > Additional info: Correction : Actual results: The RtFilter never load vHostMappingFile from absolute path /opt/jboss-eap-6.2/standalone/configuration/ and throw below warning in EAP6 server.log: 22:36:33,806 WARN [org.rhq.helpers.rtfilter.filter.RtFilter] (ServerService Thread Pool -- 51) Can't read vhost mappings from /opt/jboss-eap-6.2/standalone/configuration/vhost-mappings. properties Micke, would you mind to have a look? Thanks! The configuration is incorrect, it should NOT be absolute path but instead only the configuration filename that would reside in the configuration/ directory. So in this case: <param-value>vhost-mappings.properties</param-value> The documentation could use some work to clarify this. Tested on 3.3.0.GA Update 03 ( Build Number : 82ad0cc:a25836e ) Installed and configured RtFilter in JBoss EAP 6.2 standalone server by following the steps. Changed <param-value> to "<param-value>vhost-mappings.properties</param-value>" in web.xml of attached helloworld.war Created /opt/jboss-eap-6.2/standalone/configuration/vhost-mappings.properties file and deployed the helloworld.war to EAP6.2. After restarting the JBoss EAP 6.2 server, the EAP6.2 server.log throws the below warning: 16:19:05,834 WARN [org.rhq.helpers.rtfilter.filter.RtFilter] (ServerService Thread Pool -- 53) Can't read vhost mappings from vhost-mappings.properties. Attaching the standalone.xml, helloworld.war and vhost-mappings.properties for reference. Created attachment 1038026 [details]
standalone.xml
Created attachment 1038028 [details]
vhost-mappings.properties
Created attachment 1038029 [details]
helloworld.war
Right, this feature has never worked in AS7 based applications (including any EAP6) - as the code has been done before the release of AS 5.0. I'm not sure it's even possible to support the documented way of doing things as the EAP6 class loader does not show these files. Fixed in the master to use jboss.server.config.dir system property (to maintain current documented behaviour): commit 2e2ddf19d4b782900030654d71a3354847ce7a86 Author: Michael Burman <miburman> Date: Thu Jun 18 18:48:03 2015 +0300 [BZ 1209558] Read RtFilter files from jboss.server.config.dir system property directory Available for test with 3.3.3 ER01 build: https://brewweb.devel.redhat.com/buildinfo?buildID=446732 *Note: jon-server-patch-3.3.0.GA.zip maps to ER01 build of jon-server-3.3.0.GA-update-03.zip. Verified on JBoss ON 3.3.3 ER01 build Installed and configured RtFilter in JBoss EAP 6.2 standalone server by following the steps. Created /opt/jboss-eap-6.2/standalone/configuration/vhost-mappings.properties file and deployed the helloworld.war to EAP6.2. When I had absolute path: <param-value>/opt/jboss-eap-6.2/standalone/configuration/vhost-mappings.properties</param-value> Restarting the JBoss EAP 6.2 server, the EAP6.2 server.log throws the below warning: WARN [org.rhq.helpers.rtfilter.filter.RtFilter] (ServerService Thread Pool -- 50) Can't find vhost mappings file from /opt/jboss-eap-6.2/standalone/configuration/opt/jboss-eap-6.2/standalone/configuration/vhost-mappings.properties ====================== Changed <param-value> to only the configuration filename as below: <param-value>vhost-mappings.properties</param-value> in web.xml of helloworld.war There are no errors in EAP6.2 server.log Also verified that the call time data is displayed: Navigated to the webapp->web->Inventory->Connection Settings tab and edited Response Time Log File: /opt/jboss-eap-6.2/standalone/log/rt/helloworld1_rt.log In Monitoring->Schedules tab enabled and set Response Time metric to 30 seconds Verified after few minutes that the Monitoring->Calltime displayed the calltime data as attached for reference. Marking this as verified as there are no errors when <param-value> is set only to the configuration file name. Created attachment 1052686 [details]
CalltimeData
Since the problem described in this bug report should be resolved in a recent advisory, it has been closed with a resolution of ERRATA. For information on the advisory, and where to find the updated files, follow the link below. If the solution does not work for you, open a new bug report. https://rhn.redhat.com/errata/RHSA-2015-1525.html |