Return-Path: X-Original-To: apmail-felix-dev-archive@www.apache.org Delivered-To: apmail-felix-dev-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 92625E68C for ; Mon, 11 Mar 2013 12:53:23 +0000 (UTC) Received: (qmail 12137 invoked by uid 500); 11 Mar 2013 12:41:35 -0000 Delivered-To: apmail-felix-dev-archive@felix.apache.org Received: (qmail 11939 invoked by uid 500); 11 Mar 2013 12:41:28 -0000 Mailing-List: contact dev-help@felix.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@felix.apache.org Delivered-To: mailing list dev@felix.apache.org Received: (qmail 11690 invoked by uid 99); 11 Mar 2013 12:41:20 -0000 Received: from arcas.apache.org (HELO arcas.apache.org) (140.211.11.28) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 11 Mar 2013 12:41:16 +0000 Date: Mon, 11 Mar 2013 12:41:12 +0000 (UTC) From: "Valentin Valchev (JIRA)" To: dev@felix.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Created] (FELIX-3965) threads configuration status generates invalid results MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 Valentin Valchev created FELIX-3965: --------------------------------------- Summary: threads configuration status generates invalid results Key: FELIX-3965 URL: https://issues.apache.org/jira/browse/FELIX-3965 Project: Felix Issue Type: Bug Components: Web Console Affects Versions: webconsole-4.0.0 Reporter: Valentin Valchev Assignee: Valentin Valchev I'm quite surprised, that nobody noticed that "Threads" tab in Configuration Status generates invalid result. There are two problems: 1. The number of reported threads in the status is incorrect. The reason is that we are enumerating all threads in all thread groups. However in some JVMs enumerating the root thread group will return *all* threads. So we count the threads at least twice - once being enumerated from the root group, and once - from their own thread group. 2. Some threads are not printed at all. Our comparators doesn't guarantee that the null elements in the array will always get at the end of the array. So occasionally we can get a sorted array with nulls in front. Then, if we print one the first N (the actual thread count) from the array. Nulls are skipped, but the counter is increased, so finally some threads remain unprinted. -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators For more information on JIRA, see: http://www.atlassian.com/software/jira