Package com.alibaba.druid.support.monitor

Examples of com.alibaba.druid.support.monitor.MonitorClient


    private MonitorClient client;

    @Override
    public void contextInitialized(ServletContextEvent event) {
        client = new MonitorClient();
        client.start();
    }
View Full Code Here


//        System.out.println(buildCreateSql(dao, new BeanInfo(WallTableStatValue.class)));
//        System.out.println(buildCreateSql(dao, new BeanInfo(WallFunctionStatValue.class)));

//         dao.createTables("mysql");

        MonitorClient client = new MonitorClient();
        client.setDao(dao);
       
        client.checkInst();

        client.collectSql();

        {
            List<JdbcSqlStatValue> sqlList = client.loadSqlList(Collections.<String, Object> emptyMap());
            for (JdbcSqlStatValue sqlStatValue : sqlList) {
                System.out.println(sqlStatValue.getData());
            }
            // Assert.assertEquals(11, sqlList.size());
        }

        client.collectSql();

        {
            List<JdbcSqlStatValue> sqlList = client.loadSqlList(Collections.<String, Object> emptyMap());
            for (JdbcSqlStatValue sqlStatValue : sqlList) {
                System.out.println(sqlStatValue.getData());
            }
            // Assert.assertEquals(14, sqlList.size());
        }
View Full Code Here

TOP

Related Classes of com.alibaba.druid.support.monitor.MonitorClient

Copyright © 2018 www.massapicom. 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.