Changes for page Monitoring

Last modified by Antoine Mottier on 2023/07/17

<
From version < 24.3 >
edited by Vincent Massol
on 2016/11/03
To version < 26.1 >
edited by Ecaterina Moraru (Valica)
on 2017/09/04
>
Change comment: There is no comment for this version

Summary

Details

Page properties
Author
... ... @@ -1,1 +1,1 @@
1 -XWiki.VincentMassol
1 +XWiki.evalica
Content
... ... @@ -3,9 +3,10 @@
3 3  {{/box}}
4 4  
5 5  There are various solutions you can use to monitor a running XWiki instance:
6 +
6 6  * Install and configure [[JavaMelody>>https://github.com/javamelody/javamelody/wiki]]
7 -* [[Use a Profiler>>http://dev.xwiki.org/xwiki/bin/view/Community/Profiling]]. This has the advantage of providing advanced information, but has the drawback of being resource intensive and thus slowing the XWiki instance. It also requires a special startup script.
8 -* Starting with XWiki Enterprise 2.4M2 we're now using the [[JMX Technology>>http://en.wikipedia.org/wiki/Java_Management_Extensions]] to provide runtime monitoring of XWiki instances. The following features are currently available:
8 +* [[Use a Profiler>>dev:Community.Profiling]]. This has the advantage of providing advanced information, but has the drawback of being resource intensive and thus slowing the XWiki instance. It also requires a special startup script.
9 +* Starting with XWiki 2.4M2 we're now using the [[JMX Technology>>http://en.wikipedia.org/wiki/Java_Management_Extensions]] to provide runtime monitoring of XWiki instances. The following features are currently available:
9 9  ** Monitor the Velocity macro caches
10 10  ** Monitor the JBossCache caches XWiki is using to cache Document data, Users & Groups data and more
11 11  ** (starting with XE 3.1) Monitor the JGroups channel and protocols (when the XWiki Cluster feature is turned on)
... ... @@ -20,6 +20,7 @@
20 20  [[[[image:https://raw.githubusercontent.com/wiki/javamelody/javamelody/resources/screenshots/graphs.png||width="50%"]]>>https://github.com/javamelody/javamelody/wiki/Screenshots#charts||style="width:50%"]]
21 21  
22 22  To install JavaMelody for XWiki follow these steps (see the [[JavaMelody user guide>>https://github.com/javamelody/javamelody/wiki/UserGuide]] for more details):
24 +
23 23  * Download the latest [[javamelody.jar>>https://github.com/javamelody/javamelody/releases]] and [[jrobin-x.jar>>https://github.com/javamelody/javamelody/releases/download/javamelody-core-1.49.0/jrobin-1.5.9.jar]] and put them in the ##WEB-INF/lib## folder
24 24  * Edit ##web.xml## and add the following information:(((
25 25  {{code}}
... ... @@ -28,6 +28,15 @@
28 28   <filter-name>monitoring</filter-name>
29 29   <filter-class>net.bull.javamelody.MonitoringFilter</filter-class>
30 30  </filter>
33 +<!-- to enable BASIC authentication with username and password, but do no want to use a realm and "security-constraint"
34 +<filter>
35 + <filter-name>javamelody</filter-name>
36 + <filter-class>net.bull.javamelody.MonitoringFilter</filter-class>
37 + <init-param>
38 + <param-name>authorized-users</param-name>
39 + <param-value>user1:pwd1, user2:pwd2</param-value>
40 + </init-param>
41 +</filter> -->
31 31  ... other <filter>s from the default web.xml here ...
32 32  
33 33  <filter-mapping>
... ... @@ -49,7 +49,7 @@
49 49  {{/code}}
50 50  )))
51 51  
52 -Then restart XWiki and access JavaMelody at ##http:~//localhost:8080/xwiki/monitoring##.
63 +Then restart XWiki and access JavaMelody at ##http:~/~/localhost:8080/xwiki/monitoring##.
53 53  
54 54  = JMX Console =
55 55  
... ... @@ -72,7 +72,7 @@
72 72  Since JBoss Infinispan natively supports JMX we benefit from this feature directly (JBoss documentation available [[here>>https://docs.jboss.org/author/display/ISPN/Management+Tooling]]).
73 73  
74 74  {{info}}
75 -Prior to XWiki Enterprise 3.5 the JMX support was not enabled by default. To enable it, edit ##WEB-INF/cache/infinispan/config.xml## and uncomment the two places where the "jmx" string is mentioned
86 +Prior to XWiki 3.5 the JMX support was not enabled by default. To enable it, edit ##WEB-INF/cache/infinispan/config.xml## and uncomment the two places where the "jmx" string is mentioned
76 76  {{/info}}
77 77  
78 78  Example showing the cache list and some statistic for a given cache:
... ... @@ -112,6 +112,7 @@
112 112  {{image reference="jgroups.png"/}}
113 113  
114 114  Interesting things to do on JGroups in the JMX console:
126 +
115 115  * Change the log level on the protocols to enable logging
116 116  * Disconnect a node from the cluster and reconnect it
117 117  
... ... @@ -126,6 +126,7 @@
126 126  Tomcat has a JMX Proxy Servlet bundled in their ##manager## webapp (see [[here>>http://tomcat.apache.org/tomcat-6.0-doc/manager-howto.html]] and [[here>>http://tomcat.apache.org/tomcat-6.0-doc/monitoring.html]] for more details on Tomcat and JMX]].
127 127  
128 128  Here's some useful URLs to use the JMX Servlet Proxy to list and set JGroups Protocol Levels:
141 +
129 129  * To display the current log level for the TCPPING protocol: {{{http://localhost:8080/manager/jmxproxy?qry=jgroups:type=protocol,cluster=event,protocol=TCPPING}}}
130 130  * To set the log level to ##info## for the TCPPING protocol: {{{http://localhost:8080/manager/jmxproxy?set=jgroups:type=protocol,cluster=event,protocol=TCPPING&att=Level&val=info}}}
131 131  

Get Connected