Bug 864621 - AS7 plugin and RtFilter are not in sync with their out-of-box defaults
Summary: AS7 plugin and RtFilter are not in sync with their out-of-box defaults
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: JBoss Operations Network
Classification: JBoss
Component: Plugin -- JBoss EAP 6
Version: JON 3.1.1
Hardware: Unspecified
OS: Unspecified
high
high
Target Milestone: ---
: JON 3.1.2
Assignee: John Mazzitelli
QA Contact: Armine Hovsepyan
URL:
Whiteboard:
Depends On: 864619
Blocks:
TreeView+ depends on / blocked
 
Reported: 2012-10-09 19:02 UTC by Charles Crouch
Modified: 2015-09-03 00:01 UTC (History)
6 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of: 864619
Environment:
Last Closed: 2013-09-11 10:59:00 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)

Description Charles Crouch 2012-10-09 19:02:45 UTC
+++ This bug was initially created as a clone of Bug #864619 +++

bug #815889 implements RT monitoring for the AS7 plugin. However, there are problems. I noticed these while working with the rhq-server plugin to monitor the RHQ Server when running in AS7.

It all boils down to the AS7 component org.rhq.modules.plugins.jbossas7.WebRuntimeComponent needing to have the same out-of-box defaults as the response time servlet filter org.rhq.helpers.rtfilter.filter.RtFilter.

Things I've seen:

1) The RtFilter stores the rt log files, by default, in the AS7 log directory under a subdirectory called "rt". The AS7 plugin just assumes they are in the log directory itself.

2) If the virtual host is the default host, the RtFilter just stores the RT data in a log file called <context-root>_rt.log - for example "coregui_rt.log". But the AS7 plugin always assumes the virtual host name is a prefix for that file name.  So if its the default virtual host (AS7 reports this as "default-host") the AS7 plugin will look for the RT data file called "default-host_<context-root>_rt.log" - for example, default-host_/coregui_rt.log. The AS7 plugin should not prefex with "default-host_" since that is what RtFilter does.

3) If the context root has a "/" in it, the AS7 plugin uses it literally (so for a context root of "/coregui") it will build the RT log file name as "<as7-log-dir>/default-host_/coregui_rt.log". So it thinks it should be in a subdirectory under the default virtual host. The RtFilter doesn't does this.

4) if the context is the root context ("/") the RtFilter uses "ROOT" but the AS7 plugin does not. The AS7 plugin should use "ROOT_rt.log" as the last part of the log file name but it uses  "/_rt.log".

Comment 1 John Mazzitelli 2012-11-12 13:50:28 UTC
[this is a comment from https://bugzilla.redhat.com/show_bug.cgi?id=864619#c3 - just documenting it here to show the git hashes to be cherry-picked]

these two git commits to master fix the 5 reported problems:

4b877c477d5d82dc55abe5ea29c4c8972330f30e

09bccb738afe0e709e8cfa30054398c8be136f5a

Comment 2 John Mazzitelli 2012-11-12 14:11:27 UTC
git cherry picked the two commits to release/jon3.1.x branch:

12cd6da3552a2b5ee5e5ddeb65ffa753822df8d9

36d3832ba6e18c3766a3ccc13e108c041a1ea06e

Comment 3 Simeon Pinder 2012-11-21 21:56:06 UTC
Moving to ON_QA as available for test with build : https://brewweb.devel.redhat.com//buildinfo?buildID=244662.

Comment 5 Armine Hovsepyan 2012-12-06 20:21:06 UTC
verified.

1. All log files in both ${EAP_HOME}/standalone/log/rt and ${JON_SERVER_HOME}/logs/rt are in correct ${IP_OR_HOST}_${APPLICATION}_rt.log format

2. Root war has the following log format - ${HOST}_ROOT_rt.log

3. While filling correct log path in web resource - all metrics are being shown correctly.


Note You need to log in before you can comment on or make changes to this bug.