Return-Path: X-Original-To: apmail-sling-commits-archive@www.apache.org Delivered-To: apmail-sling-commits-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id E2EA410653 for ; Tue, 3 Sep 2013 06:41:05 +0000 (UTC) Received: (qmail 79303 invoked by uid 500); 3 Sep 2013 06:41:05 -0000 Delivered-To: apmail-sling-commits-archive@sling.apache.org Received: (qmail 78658 invoked by uid 500); 3 Sep 2013 06:41:03 -0000 Mailing-List: contact commits-help@sling.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@sling.apache.org Delivered-To: mailing list commits@sling.apache.org Received: (qmail 78645 invoked by uid 99); 3 Sep 2013 06:41:02 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 03 Sep 2013 06:41:02 +0000 X-ASF-Spam-Status: No, hits=-2000.0 required=5.0 tests=ALL_TRUSTED X-Spam-Check-By: apache.org Received: from [140.211.11.4] (HELO eris.apache.org) (140.211.11.4) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 03 Sep 2013 06:41:00 +0000 Received: from eris.apache.org (localhost [127.0.0.1]) by eris.apache.org (Postfix) with ESMTP id CB82123888A6; Tue, 3 Sep 2013 06:40:38 +0000 (UTC) Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: svn commit: r1519581 - /sling/trunk/contrib/extensions/healthcheck/jmx/src/main/java/org/apache/sling/hc/jmx/impl/HealthCheckMBean.java Date: Tue, 03 Sep 2013 06:40:38 -0000 To: commits@sling.apache.org From: cziegeler@apache.org X-Mailer: svnmailer-1.0.9 Message-Id: <20130903064038.CB82123888A6@eris.apache.org> X-Virus-Checked: Checked by ClamAV on apache.org Author: cziegeler Date: Tue Sep 3 06:40:38 2013 New Revision: 1519581 URL: http://svn.apache.org/r1519581 Log: Add persistence id as mbean attribute Modified: sling/trunk/contrib/extensions/healthcheck/jmx/src/main/java/org/apache/sling/hc/jmx/impl/HealthCheckMBean.java Modified: sling/trunk/contrib/extensions/healthcheck/jmx/src/main/java/org/apache/sling/hc/jmx/impl/HealthCheckMBean.java URL: http://svn.apache.org/viewvc/sling/trunk/contrib/extensions/healthcheck/jmx/src/main/java/org/apache/sling/hc/jmx/impl/HealthCheckMBean.java?rev=1519581&r1=1519580&r2=1519581&view=diff ============================================================================== --- sling/trunk/contrib/extensions/healthcheck/jmx/src/main/java/org/apache/sling/hc/jmx/impl/HealthCheckMBean.java (original) +++ sling/trunk/contrib/extensions/healthcheck/jmx/src/main/java/org/apache/sling/hc/jmx/impl/HealthCheckMBean.java Tue Sep 3 06:40:38 2013 @@ -171,6 +171,9 @@ public class HealthCheckMBean implements if ( serviceReference.getProperty(HealthCheck.TAGS) != null ) { attrs.add(new MBeanAttributeInfo(HealthCheck.TAGS, String.class.getName(), "The tags of the health check service.", true, false, false)); } + if ( serviceReference.getProperty(Constants.SERVICE_PID) != null ) { + attrs.add(new MBeanAttributeInfo(Constants.SERVICE_PID, String.class.getName(), "The persistence identifier of the service.", true, false, false)); + } // add standard attributes attrs.add(new MBeanAttributeInfo(HC_OK_ATTRIBUTE_NAME, Boolean.class.getName(), "The health check result", true, false, false)); @@ -205,6 +208,9 @@ public class HealthCheckMBean implements list.put(HealthCheck.TAGS, value.toString()); } } + if ( serviceReference.getProperty(Constants.SERVICE_PID) != null ) { + list.put(Constants.SERVICE_PID, serviceReference.getProperty(Constants.SERVICE_PID).toString()); + } return list; }