GitHub user wangli1426 opened a pull request: https://github.com/apache/storm/pull/698
[STORM-1007] Isolate the code for metric collection and retrieval from DisruptorQueue I created an inner class QueueMetrics for DisruptorQueue. The QueueMetrics class handles metric collection logics and exposes metric retrieval methods. The benefits of such modification are twofold: 1. It improves the readability of the metric code. 2. It facilitates to add more metrics, such as average throughput and element sojourn time. (That is because the data maintained for such "stateful" metrics can reside in QueueMetrics rather than in DisruptorQueue. ) You can merge this pull request into a Git repository by running: $ git pull https://github.com/wangli1426/storm master Alternatively you can review and apply these changes as the patch at: https://github.com/apache/storm/pull/698.patch To close this pull request, make a commit to your master/trunk branch with (at least) the following in the commit message: This closes #698 ---- commit 4337ebe6e2398073e9a238e88bd51ca7b76b3437 Author: wangli1426 <wangli1...@gmail.com> Date: 2015-08-26T04:48:27Z Created QueueMetrics inner class in DistruptorQueue to improve the extendibility and the readability of the metrics code. ---- --- If your project is set up for it, you can reply to this email and have your reply appear on GitHub as well. If your project does not have this feature enabled and wishes so, or if the feature is enabled but not working, please contact infrastructure at infrastruct...@apache.org or file a JIRA ticket with INFRA. ---