@SuppressWarnings("rawtypes")
 @Override
 public void doTask(QuartzScheduleJobBO scheduleJob) {
   DynamicBeanBO beanDomain =
       getCustomerBeanListFactory().getBeanProperty(scheduleJob.getBeanId());
   Object obj = beanDomain.getPropertyBean();
   DbConfigDomain dbDomain = null;
   if (obj instanceof DbConfigDomain) {
     dbDomain = (DbConfigDomain) obj;
   }
   getMySQLSsh().sshCollectMySQLSlowSQL(dbDomain.getIpAddr(), dbDomain.getDbId());
 }
  /**
   * MySQL的调度任务
   *
   * @param serverId
   * @return
   */
  private List<QuartzScheduleJobBO> getMySQLSchedule(String serverId) {
    List<QuartzScheduleJobBO> jobs = new ArrayList<QuartzScheduleJobBO>();
    List<DbConfigDomain> dbList =
        dbConfigDAO.listDbConfigByServerId(serverId, SysTypeEnum.MySQL.getVal().toString());
    for (DbConfigDomain domain : dbList) {
      List<DeamonScheduleconfigDomain> list =
          deamonScheduleconfigDAO.listDeamonScheduleconfigByMonitorId(
              domain.getDbId(), SysTypeEnum.MySQL.getVal());

      if (list != null && list.size() > 0) {
        for (DeamonScheduleconfigDomain scheduleDomain : list) {
          QuartzScheduleJobBO bo = convertConfigToScheduleJob(scheduleDomain);
          if (bo == null) continue;
          jobs.add(bo);
        }
      }
    }
    return jobs;
  }
  private List<QuartzScheduleJobBO> getAllDbSchedule(Integer dbType) {
    List<QuartzScheduleJobBO> jobs = new ArrayList<QuartzScheduleJobBO>();
    List<DbConfigDomain> dbList = dbConfigDAO.listNormalDbConfig(dbType);
    for (DbConfigDomain domain : dbList) {
      List<DeamonScheduleconfigDomain> list =
          deamonScheduleconfigDAO.listDbTypeDeamonScheduleconfig(domain.getDbId(), dbType);

      if (list != null && list.size() > 0) {
        for (DeamonScheduleconfigDomain scheduleDomain : list) {
          QuartzScheduleJobBO bo = convertConfigToScheduleJob(scheduleDomain);

          if (bo == null) continue;

          bo.setJobStatus(String.valueOf(scheduleDomain.getStatus()));
          bo.setServerId(domain.getServerId());
          bo.setPort(domain.getPort());
          bo.setIpAddr(domain.getIpAddr());

          jobs.add(bo);
        }
      }
    }
    return jobs;
  }