Package org.lilyproject.util.jmx

Examples of org.lilyproject.util.jmx.JmxLiaison.queryNames()


        // Using JMX, query the size of the queue of hlogs to be processed for each replication source
        JmxLiaison jmxLiaison = new JmxLiaison();
        jmxLiaison.connect(mode == Mode.EMBED);
        ObjectName replicationSources = new ObjectName("hadoop:service=Replication,name=ReplicationSource for *");
        Set<ObjectName> mbeans = jmxLiaison.queryNames(replicationSources);
        long tryUntil = System.currentTimeMillis() + timeout;
        nextMBean: for (ObjectName mbean : mbeans) {
            int logQSize = Integer.MAX_VALUE;
            while (logQSize > 0 && System.currentTimeMillis() < tryUntil) {
                logQSize = (Integer)jmxLiaison.getAttribute(mbean, "sizeOfLogQueue");
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.