use SigarInvokerJMX.PROP_TYPE
This commit is contained in:
parent
c7b398b53a
commit
ed7562c0c7
|
@ -46,7 +46,8 @@ import org.hyperic.sigar.SigarProxyCache;
|
|||
*/
|
||||
public abstract class AbstractMBean implements DynamicMBean, MBeanRegistration {
|
||||
|
||||
protected static final String MBEAN_ATTR_TYPE = "type";
|
||||
protected static final String MBEAN_DOMAIN = SigarInvokerJMX.DOMAIN_NAME;
|
||||
protected static final String MBEAN_ATTR_TYPE = SigarInvokerJMX.PROP_TYPE;
|
||||
|
||||
protected static final short CACHED_30SEC = 0;
|
||||
|
||||
|
|
|
@ -100,7 +100,7 @@ public class ReflectedMBean extends AbstractMBean {
|
|||
super(sigar, CACHED_5SEC);
|
||||
this.type = type;
|
||||
this.name =
|
||||
SigarInvokerJMX.DOMAIN_NAME + ":" +
|
||||
MBEAN_DOMAIN + ":" +
|
||||
MBEAN_ATTR_TYPE + "=" + getType();
|
||||
}
|
||||
|
||||
|
|
|
@ -146,7 +146,7 @@ public class SigarLoadAverage extends AbstractMBean {
|
|||
super(sigar, CACHED_30SEC);
|
||||
|
||||
// all fine
|
||||
this.objectName = SigarInvokerJMX.DOMAIN_NAME + ":" + MBEAN_ATTR_TYPE
|
||||
this.objectName = MBEAN_DOMAIN + ":" + MBEAN_ATTR_TYPE
|
||||
+ "=" + MBEAN_TYPE;
|
||||
}
|
||||
|
||||
|
|
|
@ -137,7 +137,7 @@ public class SigarRegistry extends AbstractMBean {
|
|||
*/
|
||||
public SigarRegistry() {
|
||||
super(new Sigar(), CACHELESS);
|
||||
this.objectName = SigarInvokerJMX.DOMAIN_NAME + ":" + MBEAN_ATTR_TYPE
|
||||
this.objectName = MBEAN_DOMAIN + ":" + MBEAN_ATTR_TYPE
|
||||
+ "=" + MBEAN_TYPE;
|
||||
this.managedBeans = new ArrayList();
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue