当前位置: 首页>>代码示例>>Java>>正文


Java CompactionManagerMBean类代码示例

本文整理汇总了Java中org.apache.cassandra.db.compaction.CompactionManagerMBean的典型用法代码示例。如果您正苦于以下问题:Java CompactionManagerMBean类的具体用法?Java CompactionManagerMBean怎么用?Java CompactionManagerMBean使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。


CompactionManagerMBean类属于org.apache.cassandra.db.compaction包,在下文中一共展示了CompactionManagerMBean类的12个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: JmxProxyImpl

import org.apache.cassandra.db.compaction.CompactionManagerMBean; //导入依赖的package包/类
private JmxProxyImpl(
    Optional<RepairStatusHandler> handler,
    String host,
    String hostBeforeTranslation,
    JMXServiceURL jmxUrl,
    JMXConnector jmxConnector,
    Object ssProxy,
    ObjectName ssMbeanName,
    MBeanServerConnection mbeanServer,
    CompactionManagerMBean cmProxy,
    EndpointSnitchInfoMBean endpointSnitchMbean,
    FailureDetectorMBean fdProxy) {

  this.host = host;
  this.hostBeforeTranslation = hostBeforeTranslation;
  this.jmxUrl = jmxUrl;
  this.jmxConnector = jmxConnector;
  this.ssMbeanName = ssMbeanName;
  this.mbeanServer = mbeanServer;
  this.ssProxy = ssProxy;
  this.repairStatusHandler = handler;
  this.cmProxy = cmProxy;
  this.endpointSnitchMbean = endpointSnitchMbean;
  this.clusterName = Cluster.toSymbolicName(((StorageServiceMBean) ssProxy).getClusterName());
  this.fdProxy = fdProxy;
}
 
开发者ID:thelastpickle,项目名称:cassandra-reaper,代码行数:27,代码来源:JmxProxyImpl.java

示例2: printCompactionStats

import org.apache.cassandra.db.compaction.CompactionManagerMBean; //导入依赖的package包/类
public void printCompactionStats(PrintStream outs)
{
    int compactionThroughput = probe.getCompactionThroughput();
    CompactionManagerMBean cm = probe.getCompactionManagerProxy();
    outs.println("pending tasks: " + cm.getPendingTasks());
    if (cm.getCompactions().size() > 0)
        outs.printf("%25s%16s%16s%16s%16s%10s%10s%n", "compaction type", "keyspace", "table", "completed", "total", "unit", "progress");
    long remainingBytes = 0;
    for (Map<String, String> c : cm.getCompactions())
    {
        String percentComplete = new Long(c.get("total")) == 0
                               ? "n/a"
                               : new DecimalFormat("0.00").format((double) new Long(c.get("completed")) / new Long(c.get("total")) * 100) + "%";
        outs.printf("%25s%16s%16s%16s%16s%10s%10s%n", c.get("taskType"), c.get("keyspace"), c.get("columnfamily"), c.get("completed"), c.get("total"), c.get("unit"), percentComplete);
        if (c.get("taskType").equals(OperationType.COMPACTION.toString()))
            remainingBytes += (new Long(c.get("total")) - new Long(c.get("completed")));
    }
    long remainingTimeInSecs = compactionThroughput == 0 || remainingBytes == 0
                    ? -1
                    : (remainingBytes) / (long) (1024L * 1024L * compactionThroughput);
    String remainingTime = remainingTimeInSecs < 0
                    ? "n/a"
                    : String.format("%dh%02dm%02ds", remainingTimeInSecs / 3600, (remainingTimeInSecs % 3600) / 60, (remainingTimeInSecs % 60));

    outs.printf("%25s%10s%n", "Active compaction remaining time : ", remainingTime);
}
 
开发者ID:pgaref,项目名称:ACaZoo,代码行数:27,代码来源:NodeCmd.java

示例3: printCompactionStats

import org.apache.cassandra.db.compaction.CompactionManagerMBean; //导入依赖的package包/类
public void printCompactionStats(PrintStream outs)
{
    int compactionThroughput = probe.getCompactionThroughput();
    CompactionManagerMBean cm = probe.getCompactionManagerProxy();
    outs.println("pending tasks: " + cm.getPendingTasks());
    if (cm.getCompactions().size() > 0)
        outs.printf("%25s%16s%16s%16s%16s%10s%10s%n", "compaction type", "keyspace", "column family", "completed", "total", "unit", "progress");
    long remainingBytes = 0;
    for (Map<String, String> c : cm.getCompactions())
    {
        String percentComplete = new Long(c.get("total")) == 0
                               ? "n/a"
                               : new DecimalFormat("0.00").format((double) new Long(c.get("completed")) / new Long(c.get("total")) * 100) + "%";
        outs.printf("%25s%16s%16s%16s%16s%10s%10s%n", c.get("taskType"), c.get("keyspace"), c.get("columnfamily"), c.get("completed"), c.get("total"), c.get("unit"), percentComplete);
        if (c.get("taskType").equals(OperationType.COMPACTION.toString()))
            remainingBytes += (new Long(c.get("total")) - new Long(c.get("completed")));
    }
    long remainingTimeInSecs = compactionThroughput == 0 || remainingBytes == 0
                    ? -1
                    : (remainingBytes) / (long) (1024L * 1024L * compactionThroughput);
    String remainingTime = remainingTimeInSecs < 0
                    ? "n/a"
                    : String.format("%dh%02dm%02ds", remainingTimeInSecs / 3600, (remainingTimeInSecs % 3600) / 60, (remainingTimeInSecs % 60));

    outs.printf("%25s%10s%n", "Active compaction remaining time : ", remainingTime);
}
 
开发者ID:dprguiuc,项目名称:Cassandra-Wasef,代码行数:27,代码来源:NodeCmd.java

示例4: execute

import org.apache.cassandra.db.compaction.CompactionManagerMBean; //导入依赖的package包/类
@Override
public void execute(NodeProbe probe)
{
    int compactionThroughput = probe.getCompactionThroughput();
    CompactionManagerMBean cm = probe.getCompactionManagerProxy();
    System.out.println("pending tasks: " + probe.getCompactionMetric("PendingTasks"));
    if (cm.getCompactions().size() > 0)
        System.out.printf("%25s%16s%16s%16s%16s%10s%10s%n", "compaction type", "keyspace", "table", "completed", "total", "unit", "progress");
    long remainingBytes = 0;
    for (Map<String, String> c : cm.getCompactions())
    {
        String percentComplete = new Long(c.get("total")) == 0
                                 ? "n/a"
                                 : new DecimalFormat("0.00").format((double) new Long(c.get("completed")) / new Long(c.get("total")) * 100) + "%";
        System.out.printf("%25s%16s%16s%16s%16s%10s%10s%n", c.get("taskType"), c.get("keyspace"), c.get("columnfamily"), c.get("completed"), c.get("total"), c.get("unit"), percentComplete);
        if (c.get("taskType").equals(OperationType.COMPACTION.toString()))
            remainingBytes += (new Long(c.get("total")) - new Long(c.get("completed")));
    }
    long remainingTimeInSecs = compactionThroughput == 0 || remainingBytes == 0
                               ? -1
                               : (remainingBytes) / (1024L * 1024L * compactionThroughput);
    String remainingTime = remainingTimeInSecs < 0
                           ? "n/a"
                           : format("%dh%02dm%02ds", remainingTimeInSecs / 3600, (remainingTimeInSecs % 3600) / 60, (remainingTimeInSecs % 60));

    System.out.printf("%25s%10s%n", "Active compaction remaining time : ", remainingTime);
}
 
开发者ID:mafernandez-stratio,项目名称:cassandra-cqlMod,代码行数:28,代码来源:NodeTool.java

示例5: printCompactionStats

import org.apache.cassandra.db.compaction.CompactionManagerMBean; //导入依赖的package包/类
public void printCompactionStats(PrintStream outs)
{
    CompactionManagerMBean cm = probe.getCompactionManagerProxy();
    outs.println("pending tasks: " + cm.getPendingTasks());
    if (cm.getCompactions().size() > 0)
        outs.printf("%25s%16s%16s%16s%16s%10s%n", "compaction type", "keyspace", "column family", "bytes compacted", "bytes total", "progress");
    for (CompactionInfo c : cm.getCompactions())
    {
        String percentComplete = c.getTotalBytes() == 0
                               ? "n/a"
                               : new DecimalFormat("0.00").format((double) c.getBytesComplete() / c.getTotalBytes() * 100) + "%";
        outs.printf("%25s%16s%16s%16s%16s%10s%n", c.getTaskType(), c.getKeyspace(), c.getColumnFamily(), c.getBytesComplete(), c.getTotalBytes(), percentComplete);
    }
}
 
开发者ID:devdattakulkarni,项目名称:Cassandra-KVPM,代码行数:15,代码来源:NodeCmd.java

示例6: connect

import org.apache.cassandra.db.compaction.CompactionManagerMBean; //导入依赖的package包/类
/**
 * Create a connection to the JMX agent and setup the M[X]Bean proxies.
 * 
 * @throws IOException on connection failures
 */
private void connect() throws IOException
{
    JMXServiceURL jmxUrl = new JMXServiceURL(String.format(fmtUrl, host, port));
    Map<String,Object> env = new HashMap<String,Object>();
    if (username != null)
    {
        String[] creds = { username, password };
        env.put(JMXConnector.CREDENTIALS, creds);
    }
    jmxc = JMXConnectorFactory.connect(jmxUrl, env);
    mbeanServerConn = jmxc.getMBeanServerConnection();
    
    try
    {
        ObjectName name = new ObjectName(ssObjName);
        ssProxy = JMX.newMBeanProxy(mbeanServerConn, name, StorageServiceMBean.class);
        name = new ObjectName(MessagingService.MBEAN_NAME);
        msProxy = JMX.newMBeanProxy(mbeanServerConn, name, MessagingServiceMBean.class);
        name = new ObjectName(StreamingService.MBEAN_OBJECT_NAME);
        streamProxy = JMX.newMBeanProxy(mbeanServerConn, name, StreamingServiceMBean.class);
        name = new ObjectName(CompactionManager.MBEAN_OBJECT_NAME);
        compactionProxy = JMX.newMBeanProxy(mbeanServerConn, name, CompactionManagerMBean.class);
    } catch (MalformedObjectNameException e)
    {
        throw new RuntimeException(
                "Invalid ObjectName? Please report this as a bug.", e);
    }
    
    memProxy = ManagementFactory.newPlatformMXBeanProxy(mbeanServerConn, 
            ManagementFactory.MEMORY_MXBEAN_NAME, MemoryMXBean.class);
    runtimeProxy = ManagementFactory.newPlatformMXBeanProxy(
            mbeanServerConn, ManagementFactory.RUNTIME_MXBEAN_NAME, RuntimeMXBean.class);
}
 
开发者ID:devdattakulkarni,项目名称:Cassandra-KVPM,代码行数:39,代码来源:NodeProbe.java

示例7: connect

import org.apache.cassandra.db.compaction.CompactionManagerMBean; //导入依赖的package包/类
/**
 * Create a connection to the JMX agent and setup the M[X]Bean proxies.
 *
 * @throws IOException on connection failures
 */
private void connect() throws IOException
{
    JMXServiceURL jmxUrl = new JMXServiceURL(String.format(fmtUrl, host, port));
    Map<String,Object> env = new HashMap<String,Object>();
    if (username != null)
    {
        String[] creds = { username, password };
        env.put(JMXConnector.CREDENTIALS, creds);
    }
    jmxc = JMXConnectorFactory.connect(jmxUrl, env);
    mbeanServerConn = jmxc.getMBeanServerConnection();

    try
    {
        ObjectName name = new ObjectName(ssObjName);
        ssProxy = JMX.newMBeanProxy(mbeanServerConn, name, StorageServiceMBean.class);
        name = new ObjectName(MessagingService.MBEAN_NAME);
        msProxy = JMX.newMBeanProxy(mbeanServerConn, name, MessagingServiceMBean.class);
        name = new ObjectName(StreamManagerMBean.OBJECT_NAME);
        streamProxy = JMX.newMBeanProxy(mbeanServerConn, name, StreamManagerMBean.class);
        name = new ObjectName(CompactionManager.MBEAN_OBJECT_NAME);
        compactionProxy = JMX.newMBeanProxy(mbeanServerConn, name, CompactionManagerMBean.class);
        name = new ObjectName(FailureDetector.MBEAN_NAME);
        fdProxy = JMX.newMBeanProxy(mbeanServerConn, name, FailureDetectorMBean.class);
        name = new ObjectName(CacheService.MBEAN_NAME);
        cacheService = JMX.newMBeanProxy(mbeanServerConn, name, CacheServiceMBean.class);
        name = new ObjectName(StorageProxy.MBEAN_NAME);
        spProxy = JMX.newMBeanProxy(mbeanServerConn, name, StorageProxyMBean.class);
        name = new ObjectName(HintedHandOffManager.MBEAN_NAME);
        hhProxy = JMX.newMBeanProxy(mbeanServerConn, name, HintedHandOffManagerMBean.class);
        name = new ObjectName(GCInspector.MBEAN_NAME);
        gcProxy = JMX.newMBeanProxy(mbeanServerConn, name, GCInspectorMXBean.class);
    }
    catch (MalformedObjectNameException e)
    {
        throw new RuntimeException(
                "Invalid ObjectName? Please report this as a bug.", e);
    }

    memProxy = ManagementFactory.newPlatformMXBeanProxy(mbeanServerConn,
            ManagementFactory.MEMORY_MXBEAN_NAME, MemoryMXBean.class);
    runtimeProxy = ManagementFactory.newPlatformMXBeanProxy(
            mbeanServerConn, ManagementFactory.RUNTIME_MXBEAN_NAME, RuntimeMXBean.class);
}
 
开发者ID:vcostet,项目名称:cassandra-kmean,代码行数:50,代码来源:NodeProbe.java

示例8: getCompactionManagerProxy

import org.apache.cassandra.db.compaction.CompactionManagerMBean; //导入依赖的package包/类
public CompactionManagerMBean getCompactionManagerProxy()
{
  return compactionProxy;
}
 
开发者ID:vcostet,项目名称:cassandra-kmean,代码行数:5,代码来源:NodeProbe.java

示例9: connect

import org.apache.cassandra.db.compaction.CompactionManagerMBean; //导入依赖的package包/类
/**
 * Create a connection to the JMX agent and setup the M[X]Bean proxies.
 *
 * @throws IOException on connection failures
 */
private void connect() throws IOException
{
    JMXServiceURL jmxUrl = new JMXServiceURL(String.format(fmtUrl, host, port));
    Map<String,Object> env = new HashMap<String,Object>();
    if (username != null)
    {
        String[] creds = { username, password };
        env.put(JMXConnector.CREDENTIALS, creds);
    }
    jmxc = JMXConnectorFactory.connect(jmxUrl, env);
    mbeanServerConn = jmxc.getMBeanServerConnection();

    try
    {
        ObjectName name = new ObjectName(ssObjName);
        ssProxy = JMX.newMBeanProxy(mbeanServerConn, name, StorageServiceMBean.class);
        name = new ObjectName(MessagingService.MBEAN_NAME);
        msProxy = JMX.newMBeanProxy(mbeanServerConn, name, MessagingServiceMBean.class);
        name = new ObjectName(StreamManagerMBean.OBJECT_NAME);
        streamProxy = JMX.newMBeanProxy(mbeanServerConn, name, StreamManagerMBean.class);
        name = new ObjectName(CompactionManager.MBEAN_OBJECT_NAME);
        compactionProxy = JMX.newMBeanProxy(mbeanServerConn, name, CompactionManagerMBean.class);
        name = new ObjectName(FailureDetector.MBEAN_NAME);
        fdProxy = JMX.newMBeanProxy(mbeanServerConn, name, FailureDetectorMBean.class);
        name = new ObjectName(CacheService.MBEAN_NAME);
        cacheService = JMX.newMBeanProxy(mbeanServerConn, name, CacheServiceMBean.class);
        name = new ObjectName(StorageProxy.MBEAN_NAME);
        spProxy = JMX.newMBeanProxy(mbeanServerConn, name, StorageProxyMBean.class);
        name = new ObjectName(HintedHandOffManager.MBEAN_NAME);
        hhProxy = JMX.newMBeanProxy(mbeanServerConn, name, HintedHandOffManagerMBean.class);
    } catch (MalformedObjectNameException e)
    {
        throw new RuntimeException(
                "Invalid ObjectName? Please report this as a bug.", e);
    }

    memProxy = ManagementFactory.newPlatformMXBeanProxy(mbeanServerConn,
            ManagementFactory.MEMORY_MXBEAN_NAME, MemoryMXBean.class);
    runtimeProxy = ManagementFactory.newPlatformMXBeanProxy(
            mbeanServerConn, ManagementFactory.RUNTIME_MXBEAN_NAME, RuntimeMXBean.class);
}
 
开发者ID:pgaref,项目名称:ACaZoo,代码行数:47,代码来源:NodeProbe.java

示例10: connect

import org.apache.cassandra.db.compaction.CompactionManagerMBean; //导入依赖的package包/类
/**
 * Create a connection to the JMX agent and setup the M[X]Bean proxies.
 *
 * @throws IOException on connection failures
 */
private void connect() throws IOException
{
    JMXServiceURL jmxUrl = new JMXServiceURL(String.format(fmtUrl, host, port));
    Map<String,Object> env = new HashMap<String,Object>();
    if (username != null)
    {
        String[] creds = { username, password };
        env.put(JMXConnector.CREDENTIALS, creds);
    }

    env.put("com.sun.jndi.rmi.factory.socket", getRMIClientSocketFactory());

    jmxc = JMXConnectorFactory.connect(jmxUrl, env);
    mbeanServerConn = jmxc.getMBeanServerConnection();

    try
    {
        ObjectName name = new ObjectName(ssObjName);
        ssProxy = JMX.newMBeanProxy(mbeanServerConn, name, StorageServiceMBean.class);
        name = new ObjectName(MessagingService.MBEAN_NAME);
        msProxy = JMX.newMBeanProxy(mbeanServerConn, name, MessagingServiceMBean.class);
        name = new ObjectName(StreamManagerMBean.OBJECT_NAME);
        streamProxy = JMX.newMBeanProxy(mbeanServerConn, name, StreamManagerMBean.class);
        name = new ObjectName(CompactionManager.MBEAN_OBJECT_NAME);
        compactionProxy = JMX.newMBeanProxy(mbeanServerConn, name, CompactionManagerMBean.class);
        name = new ObjectName(FailureDetector.MBEAN_NAME);
        fdProxy = JMX.newMBeanProxy(mbeanServerConn, name, FailureDetectorMBean.class);
        name = new ObjectName(CacheService.MBEAN_NAME);
        cacheService = JMX.newMBeanProxy(mbeanServerConn, name, CacheServiceMBean.class);
        name = new ObjectName(StorageProxy.MBEAN_NAME);
        spProxy = JMX.newMBeanProxy(mbeanServerConn, name, StorageProxyMBean.class);
        name = new ObjectName(HintedHandOffManager.MBEAN_NAME);
        hhProxy = JMX.newMBeanProxy(mbeanServerConn, name, HintedHandOffManagerMBean.class);
        name = new ObjectName(GCInspector.MBEAN_NAME);
        gcProxy = JMX.newMBeanProxy(mbeanServerConn, name, GCInspectorMXBean.class);
        name = new ObjectName(Gossiper.MBEAN_NAME);
        gossProxy = JMX.newMBeanProxy(mbeanServerConn, name, GossiperMBean.class);
        name = new ObjectName(BatchlogManager.MBEAN_NAME);
        bmProxy = JMX.newMBeanProxy(mbeanServerConn, name, BatchlogManagerMBean.class);
    }
    catch (MalformedObjectNameException e)
    {
        throw new RuntimeException(
                "Invalid ObjectName? Please report this as a bug.", e);
    }

    memProxy = ManagementFactory.newPlatformMXBeanProxy(mbeanServerConn,
            ManagementFactory.MEMORY_MXBEAN_NAME, MemoryMXBean.class);
    runtimeProxy = ManagementFactory.newPlatformMXBeanProxy(
            mbeanServerConn, ManagementFactory.RUNTIME_MXBEAN_NAME, RuntimeMXBean.class);
}
 
开发者ID:scylladb,项目名称:scylla-tools-java,代码行数:57,代码来源:NodeProbe.java

示例11: connect

import org.apache.cassandra.db.compaction.CompactionManagerMBean; //导入依赖的package包/类
/**
 * Create a connection to the JMX agent and setup the M[X]Bean proxies.
 *
 * @throws IOException on connection failures
 */
private void connect() throws IOException
{
    JMXServiceURL jmxUrl = new JMXServiceURL(String.format(fmtUrl, host, port));
    Map<String,Object> env = new HashMap<String,Object>();
    if (username != null)
    {
        String[] creds = { username, password };
        env.put(JMXConnector.CREDENTIALS, creds);
    }
    jmxc = JMXConnectorFactory.connect(jmxUrl, env);
    mbeanServerConn = jmxc.getMBeanServerConnection();

    try
    {
        ObjectName name = new ObjectName(ssObjName);
        ssProxy = JMX.newMBeanProxy(mbeanServerConn, name, StorageServiceMBean.class);
        name = new ObjectName(MessagingService.MBEAN_NAME);
        msProxy = JMX.newMBeanProxy(mbeanServerConn, name, MessagingServiceMBean.class);
        name = new ObjectName(StreamManagerMBean.OBJECT_NAME);
        streamProxy = JMX.newMBeanProxy(mbeanServerConn, name, StreamManagerMBean.class);
        name = new ObjectName(CompactionManager.MBEAN_OBJECT_NAME);
        compactionProxy = JMX.newMBeanProxy(mbeanServerConn, name, CompactionManagerMBean.class);
        name = new ObjectName(FailureDetector.MBEAN_NAME);
        fdProxy = JMX.newMBeanProxy(mbeanServerConn, name, FailureDetectorMBean.class);
        name = new ObjectName(CacheService.MBEAN_NAME);
        cacheService = JMX.newMBeanProxy(mbeanServerConn, name, CacheServiceMBean.class);
        name = new ObjectName(StorageProxy.MBEAN_NAME);
        spProxy = JMX.newMBeanProxy(mbeanServerConn, name, StorageProxyMBean.class);
        name = new ObjectName(HintedHandOffManager.MBEAN_NAME);
        hhProxy = JMX.newMBeanProxy(mbeanServerConn, name, HintedHandOffManagerMBean.class);
        name = new ObjectName(GCInspector.MBEAN_NAME);
        gcProxy = JMX.newMBeanProxy(mbeanServerConn, name, GCInspectorMXBean.class);
        name = new ObjectName(Gossiper.MBEAN_NAME);
        gossProxy = JMX.newMBeanProxy(mbeanServerConn, name, GossiperMBean.class);
    }
    catch (MalformedObjectNameException e)
    {
        throw new RuntimeException(
                "Invalid ObjectName? Please report this as a bug.", e);
    }

    memProxy = ManagementFactory.newPlatformMXBeanProxy(mbeanServerConn,
            ManagementFactory.MEMORY_MXBEAN_NAME, MemoryMXBean.class);
    runtimeProxy = ManagementFactory.newPlatformMXBeanProxy(
            mbeanServerConn, ManagementFactory.RUNTIME_MXBEAN_NAME, RuntimeMXBean.class);
}
 
开发者ID:daidong,项目名称:GraphTrek,代码行数:52,代码来源:NodeProbe.java

示例12: connect

import org.apache.cassandra.db.compaction.CompactionManagerMBean; //导入依赖的package包/类
/**
 * Create a connection to the JMX agent and setup the M[X]Bean proxies.
 *
 * @throws IOException on connection failures
 */
private void connect() throws IOException
{
    JMXServiceURL jmxUrl = new JMXServiceURL(String.format(fmtUrl, host, port));
    Map<String,Object> env = new HashMap<String,Object>();
    if (username != null)
    {
        String[] creds = { username, password };
        env.put(JMXConnector.CREDENTIALS, creds);
    }
    jmxc = JMXConnectorFactory.connect(jmxUrl, env);
    mbeanServerConn = jmxc.getMBeanServerConnection();

    try
    {
        ObjectName name = new ObjectName(ssObjName);
        ssProxy = JMX.newMBeanProxy(mbeanServerConn, name, StorageServiceMBean.class);
        name = new ObjectName(PBSPredictor.MBEAN_NAME);
        PBSPredictorProxy = JMX.newMBeanProxy(mbeanServerConn, name, PBSPredictorMBean.class);
        name = new ObjectName(MessagingService.MBEAN_NAME);
        msProxy = JMX.newMBeanProxy(mbeanServerConn, name, MessagingServiceMBean.class);
        name = new ObjectName(StreamingService.MBEAN_OBJECT_NAME);
        streamProxy = JMX.newMBeanProxy(mbeanServerConn, name, StreamingServiceMBean.class);
        name = new ObjectName(CompactionManager.MBEAN_OBJECT_NAME);
        compactionProxy = JMX.newMBeanProxy(mbeanServerConn, name, CompactionManagerMBean.class);
        name = new ObjectName(FailureDetector.MBEAN_NAME);
        fdProxy = JMX.newMBeanProxy(mbeanServerConn, name, FailureDetectorMBean.class);
        name = new ObjectName(CacheService.MBEAN_NAME);
        cacheService = JMX.newMBeanProxy(mbeanServerConn, name, CacheServiceMBean.class);
        name = new ObjectName(StorageProxy.MBEAN_NAME);
        spProxy = JMX.newMBeanProxy(mbeanServerConn, name, StorageProxyMBean.class);
        name = new ObjectName(HintedHandOffManager.MBEAN_NAME);
        hhProxy = JMX.newMBeanProxy(mbeanServerConn, name, HintedHandOffManagerMBean.class);
    } catch (MalformedObjectNameException e)
    {
        throw new RuntimeException(
                "Invalid ObjectName? Please report this as a bug.", e);
    }

    memProxy = ManagementFactory.newPlatformMXBeanProxy(mbeanServerConn,
            ManagementFactory.MEMORY_MXBEAN_NAME, MemoryMXBean.class);
    runtimeProxy = ManagementFactory.newPlatformMXBeanProxy(
            mbeanServerConn, ManagementFactory.RUNTIME_MXBEAN_NAME, RuntimeMXBean.class);
}
 
开发者ID:dprguiuc,项目名称:Cassandra-Wasef,代码行数:49,代码来源:NodeProbe.java


注:本文中的org.apache.cassandra.db.compaction.CompactionManagerMBean类示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。