[ 
https://issues.apache.org/jira/browse/JSPWIKI-1311?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=18145312#comment-18145312
 ] 

Alex O'Ree commented on JSPWIKI-1311:
-------------------------------------

open telemetry might be an option

> Add metrics, a health endpoint and structured logging for operators
> -------------------------------------------------------------------
>
>                 Key: JSPWIKI-1311
>                 URL: https://issues.apache.org/jira/browse/JSPWIKI-1311
>             Project: JSPWiki
>          Issue Type: New Feature
>            Reporter: Arturo Bernal
>            Priority: Major
>
> JSPWiki gives operators little to observe a running instance with. What 
> exists today is the following.
>  
> The package org.apache.wiki.management has only SimpleMBean, which is the 
> base of the admin beans of the administration page 
> (org.apache.wiki.ui.admin); it is not a metrics system. The admin beans are 
> registered as MBeans on the platform MBean server by DefaultAdminBeanManager, 
> but the only operational numbers they expose are the page count and the 
> version (CoreBean), as the comments of this issue list. WatchDog notifies 
> about timeouts of the threads it watches. I found no code for metrics or 
> health checks, with Micrometer, Prometheus or anything else, in the code or 
> in the poms, and no Jira issue about it.
>  
> Logging goes through Log4j 2, configured in WEB-INF/classes/log4j2.xml with a 
> plain text PatternLayout for the console and for the rolling files, plus a 
> separate audit log.
>  
> Proposal, in three independent parts that can be done one at a time.
>  
> Metrics, for example with Micrometer and exposed in the Prometheus format: 
> pages and attachments, searches, logins and failed logins, the time of the 
> page providers, the size of the caches and the state of the background 
> threads.
>  
> A health endpoint that tells whether the engine has started and whether the 
> page provider, the search index and the user database respond, for load 
> balancers and container orchestrators. It must say nothing sensitive and be 
> protected or limited as the deployment needs.
>  
> Structured logging: a JSON layout of Log4j 2 as an option, with the user and 
> the request as context, and the audit log in the same format.
>  
> Open questions: which dependency to use (Micrometer, or only JMX and plain 
> servlets), whether the endpoints belong in a servlet of the war or in a 
> separate module, how to secure them, and what to do with the old JMX-style 
> admin beans.
>  
> Scope after the discussion on dev (27 October): first add MBeans with the 
> operational data that is missing (for example pages, cache, the search index, 
> sessions and failed logins), with no new dependency, and document how to 
> reach them with VisualVM and with Jolokia. Micrometer or Prometheus, a health 
> endpoint and structured logging stay as later options that depend on what the 
> group wants.
> This ticket is a proposal; there is no implementation.



--
This message was sent by Atlassian Jira
(v10.3.26#10030026)

Reply via email to