Search in sources :

Example 1 with TaskRuleAlarmConfigBean

use of com.webank.wedatasphere.qualitis.bean.TaskRuleAlarmConfigBean in project Qualitis by WeBankFinTech.

the class ExecutionManagerImpl method getTaskRuleAlarmConfigBean.

private List<TaskRuleAlarmConfigBean> getTaskRuleAlarmConfigBean(Rule rule) {
    List<TaskRuleAlarmConfigBean> taskRuleAlarmConfigBeans = new ArrayList<>();
    for (AlarmConfig alarmConfig : rule.getAlarmConfigs()) {
        TaskRuleAlarmConfigBean taskRuleAlarmConfigBean = new TaskRuleAlarmConfigBean();
        taskRuleAlarmConfigBean.setCheckTemplate(alarmConfig.getCheckTemplate());
        taskRuleAlarmConfigBean.setCompareType(alarmConfig.getCompareType());
        taskRuleAlarmConfigBean.setOutputName(alarmConfig.getTemplateOutputMeta().getOutputName());
        taskRuleAlarmConfigBean.setThreshold(alarmConfig.getThreshold());
        taskRuleAlarmConfigBean.setRuleMetric(alarmConfig.getRuleMetric());
        taskRuleAlarmConfigBean.setUploadRuleMetricValue(alarmConfig.getUploadRuleMetricValue());
        taskRuleAlarmConfigBean.setUploadAbnormalValue(alarmConfig.getUploadAbnormalValue());
        taskRuleAlarmConfigBean.setDeleteFailCheckResult(alarmConfig.getDeleteFailCheckResult());
        taskRuleAlarmConfigBeans.add(taskRuleAlarmConfigBean);
    }
    return taskRuleAlarmConfigBeans;
}
Also used : TaskRuleAlarmConfigBean(com.webank.wedatasphere.qualitis.bean.TaskRuleAlarmConfigBean) ArrayList(java.util.ArrayList) AlarmConfig(com.webank.wedatasphere.qualitis.rule.entity.AlarmConfig) TaskRuleAlarmConfig(com.webank.wedatasphere.qualitis.entity.TaskRuleAlarmConfig)

Aggregations

TaskRuleAlarmConfigBean (com.webank.wedatasphere.qualitis.bean.TaskRuleAlarmConfigBean)1 TaskRuleAlarmConfig (com.webank.wedatasphere.qualitis.entity.TaskRuleAlarmConfig)1 AlarmConfig (com.webank.wedatasphere.qualitis.rule.entity.AlarmConfig)1 ArrayList (java.util.ArrayList)1