[ https://issues.apache.org/jira/browse/QPID-7799?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16187167#comment-16187167 ]
Keith Wall edited comment on QPID-7799 at 9/30/17 6:12 PM: ----------------------------------------------------------- Patch is now reviewable. It gives the Broker and Virtualhost the responsibility for periodically writing user-specified model statistics to the log. Statistic reporting can be enabled dynamically without the need for a Broker or Virtualhost restart. The statistics that are reported are also modifiable on the fly. The user controls the reported statistics using context variables named in the following form {{qpid.<categoryclass>.statisticsReportPattern}} which, as normal, can come from the environment, the object itself or an ancestor. This approach gives the flexibility for statistic reporting to be enabled category class wide (e.g. all queues) or for a single object instance. The context value is free text with placeholders to interpolate statistic values e.g. {{messagesIn=$\{messagesIn\}}}. There's provision for datetime/duration/byteunit formatting to help the readability of the report {{bytessIn=$\{bytesIn:bytevalue\}}}. {{ancestor}} references can be used to interpolate object names into the statistics lines to add object and parent names. There are some parts missing from the patch. I want to hear comments first: # Currently when setting a context variable from the REST API, the user is required to PUT an object's context map. This runs the risk that the user will accidentally lose an unrelated context value whilst trying to apply a statistic context variable. We should add ConfiuredObject managed operations to allow a context variable to be put/got/removed. # Broker#resetStatistics should either be refactored so all statistics are reset and have an analogous method on Virtualhost, or we should kill the feature. I'm in favour of the latter. # I killed {{statisticsReportingResetEnabled}} already but haven't added a upgrader to remove the attribute value. # This patch makes {{StatisticsCounter}} unnecessary. It should be replaced with a simple AtomicLongs. # Docs was (Author: k-wall): Patch is now reviewable. It gives the Broker and Virtualhost the responsibility for periodically writing user-specified model statistics to the log. Statistic reporting can be enabled dynamically without the need for a Broker or Virtualhost restart. The statistics that are reported are also modifiable on the fly. The user controls the reported statistics using a context variable named in the following form {{qpid.<categoryclass>.statisticsReportPattern}} which, as normal, can come from the environment, the object itself or an ancestor. This approach gives the flexibility for statistic reporting to be enabled category class wide (e.g. all queues) or for a single object instance. The context value is free text with placeholders to interpolate statistic values e.g. {{messagesIn=$\{messagesIn\}}}. There's provision for datetime/duration/byteunit formatting to help the readability of the report {{bytessIn=$\{bytesIn:bytevalue\}}}. {{ancestor}} references can be used to interpolate object names into the statistics lines to add object and parent names. There are some parts missing from the patch. I want to hear comments first: # Currently when setting a context variable from the REST API, the user is required to PUT an object's context map. This runs the risk that the user will accidentally lose an unrelated context value whilst trying to apply a statistic context variable. We should add ConfiuredObject managed operations to allow a context variable to be put/got/removed. # Broker#resetStatistics should either be refactored so all statistics are reset and have an analogous method on Virtualhost, or we should kill the feature. I'm in favour of the latter. # I killed {{statisticsReportingResetEnabled}} already but haven't added a upgrader to remove the attribute value. # This patch makes {{StatisticsCounter}} unnecessary. It should be replaced with a simple AtomicLongs. # Docs > Broker should be able to write a periodic dump of statistics > ------------------------------------------------------------ > > Key: QPID-7799 > URL: https://issues.apache.org/jira/browse/QPID-7799 > Project: Qpid > Issue Type: Improvement > Components: Java Broker > Reporter: Keith Wall > Assignee: Keith Wall > Fix For: qpid-java-broker-7.0.0 > > Attachments: > 0001-QPID-7799-Java-Broker-Improve-statistics-reporting.patch > > > To assist those running a service, the Broker should have the ability to > write a periodic dump of ConiguredObject statistics to the log file. It > should be possible to configure the statistics dumped at runtime and be > configured on a per-category or per-object instance basis. Within a HA > group, the configuration applied to objects belonging to a virtualhost must > survive a mastership change. -- This message was sent by Atlassian JIRA (v6.4.14#64029) --------------------------------------------------------------------- To unsubscribe, e-mail: dev-unsubscr...@qpid.apache.org For additional commands, e-mail: dev-h...@qpid.apache.org