Return-Path: X-Original-To: archive-asf-public-internal@cust-asf2.ponee.io Delivered-To: archive-asf-public-internal@cust-asf2.ponee.io Received: from cust-asf.ponee.io (cust-asf.ponee.io [163.172.22.183]) by cust-asf2.ponee.io (Postfix) with ESMTP id 97193200BD9 for ; Fri, 25 Nov 2016 03:53:00 +0100 (CET) Received: by cust-asf.ponee.io (Postfix) id 95A39160B20; Fri, 25 Nov 2016 02:53:00 +0000 (UTC) Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by cust-asf.ponee.io (Postfix) with SMTP id 10626160B1E for ; Fri, 25 Nov 2016 03:52:59 +0100 (CET) Received: (qmail 12861 invoked by uid 500); 25 Nov 2016 02:52:59 -0000 Mailing-List: contact issues-help@activemq.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@activemq.apache.org Delivered-To: mailing list issues@activemq.apache.org Received: (qmail 12833 invoked by uid 99); 25 Nov 2016 02:52:59 -0000 Received: from arcas.apache.org (HELO arcas) (140.211.11.28) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 25 Nov 2016 02:52:59 +0000 Received: from arcas.apache.org (localhost [127.0.0.1]) by arcas (Postfix) with ESMTP id 1F0822C022B for ; Fri, 25 Nov 2016 02:52:59 +0000 (UTC) Date: Fri, 25 Nov 2016 02:52:59 +0000 (UTC) From: "Robert Huffman (JIRA)" To: issues@activemq.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Updated] (AMQ-6518) Statistics plugin shows wrong value for average message size MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 archived-at: Fri, 25 Nov 2016 02:53:00 -0000 [ https://issues.apache.org/jira/browse/AMQ-6518?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Robert Huffman updated AMQ-6518: -------------------------------- Priority: Major (was: Critical) > Statistics plugin shows wrong value for average message size > ------------------------------------------------------------ > > Key: AMQ-6518 > URL: https://issues.apache.org/jira/browse/AMQ-6518 > Project: ActiveMQ > Issue Type: Bug > Components: Broker > Affects Versions: 5.14.2 > Environment: Linux > Reporter: Robert Huffman > > The statistics plugin reports the wrong value for average message size. > For messages on one of my topic JMX is reporting an average message size of 1242. The statistics plugin is reporting an average message size of 0. > Digging into this I found that StatisticsPlugin line 123 is the problem. It invokes stats.getMessageSize().getAveragePerSecond() instead of stats.getMessageSize().getAverageSize(). > The result is that the plugin reports 1000 / averageMessageSize instead of averageMessageSize. > Note I cannot even work around this: it is a double cast as a long, so in my case I cannot even multiple the result by 1000 to come up with an approximation of the actual average message size. -- This message was sent by Atlassian JIRA (v6.3.4#6332)