Commit ff008571 authored by 赵建伟's avatar 赵建伟

add threshold and dingding codes

parent d59808ea
......@@ -44,6 +44,12 @@
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-validation</artifactId>
</dependency>
<!-- httpclient -->
<dependency>
<groupId>org.apache.httpcomponents</groupId>
<artifactId>httpclient</artifactId>
<version>4.3.2</version>
</dependency>
<!-- 集成mysql驱动 -->
<dependency>
<groupId>mysql</groupId>
......
......@@ -19,6 +19,8 @@ public class TblRuleInfoDuplex {
private String referColName;
private Double threshold;
private Integer isValid;
private String checkTime;
......@@ -91,6 +93,14 @@ public class TblRuleInfoDuplex {
this.referColName = referColName == null ? null : referColName.trim();
}
public Double getThreshold() {
return threshold;
}
public void setThreshold(Double threshold) {
this.threshold = threshold;
}
public Integer getIsValid() {
return isValid;
}
......
......@@ -655,6 +655,66 @@ public class TblRuleInfoDuplexCriteria {
return (Criteria) this;
}
public Criteria andThresholdIsNull() {
addCriterion("threshold is null");
return (Criteria) this;
}
public Criteria andThresholdIsNotNull() {
addCriterion("threshold is not null");
return (Criteria) this;
}
public Criteria andThresholdEqualTo(Double value) {
addCriterion("threshold =", value, "threshold");
return (Criteria) this;
}
public Criteria andThresholdNotEqualTo(Double value) {
addCriterion("threshold <>", value, "threshold");
return (Criteria) this;
}
public Criteria andThresholdGreaterThan(Double value) {
addCriterion("threshold >", value, "threshold");
return (Criteria) this;
}
public Criteria andThresholdGreaterThanOrEqualTo(Double value) {
addCriterion("threshold >=", value, "threshold");
return (Criteria) this;
}
public Criteria andThresholdLessThan(Double value) {
addCriterion("threshold <", value, "threshold");
return (Criteria) this;
}
public Criteria andThresholdLessThanOrEqualTo(Double value) {
addCriterion("threshold <=", value, "threshold");
return (Criteria) this;
}
public Criteria andThresholdIn(List<Double> values) {
addCriterion("threshold in", values, "threshold");
return (Criteria) this;
}
public Criteria andThresholdNotIn(List<Double> values) {
addCriterion("threshold not in", values, "threshold");
return (Criteria) this;
}
public Criteria andThresholdBetween(Double value1, Double value2) {
addCriterion("threshold between", value1, value2, "threshold");
return (Criteria) this;
}
public Criteria andThresholdNotBetween(Double value1, Double value2) {
addCriterion("threshold not between", value1, value2, "threshold");
return (Criteria) this;
}
public Criteria andIsValidIsNull() {
addCriterion("is_valid is null");
return (Criteria) this;
......
......@@ -19,6 +19,8 @@ public class TblRuleInfoSimple {
private String startTime;
private Double threshold;
private Integer isValid;
private String checkTime;
......@@ -93,6 +95,14 @@ public class TblRuleInfoSimple {
this.startTime = startTime == null ? null : startTime.trim();
}
public Double getThreshold() {
return threshold;
}
public void setThreshold(Double threshold) {
this.threshold = threshold;
}
public Integer getIsValid() {
return isValid;
}
......
......@@ -655,6 +655,66 @@ public class TblRuleInfoSimpleCriteria {
return (Criteria) this;
}
public Criteria andThresholdIsNull() {
addCriterion("threshold is null");
return (Criteria) this;
}
public Criteria andThresholdIsNotNull() {
addCriterion("threshold is not null");
return (Criteria) this;
}
public Criteria andThresholdEqualTo(Double value) {
addCriterion("threshold =", value, "threshold");
return (Criteria) this;
}
public Criteria andThresholdNotEqualTo(Double value) {
addCriterion("threshold <>", value, "threshold");
return (Criteria) this;
}
public Criteria andThresholdGreaterThan(Double value) {
addCriterion("threshold >", value, "threshold");
return (Criteria) this;
}
public Criteria andThresholdGreaterThanOrEqualTo(Double value) {
addCriterion("threshold >=", value, "threshold");
return (Criteria) this;
}
public Criteria andThresholdLessThan(Double value) {
addCriterion("threshold <", value, "threshold");
return (Criteria) this;
}
public Criteria andThresholdLessThanOrEqualTo(Double value) {
addCriterion("threshold <=", value, "threshold");
return (Criteria) this;
}
public Criteria andThresholdIn(List<Double> values) {
addCriterion("threshold in", values, "threshold");
return (Criteria) this;
}
public Criteria andThresholdNotIn(List<Double> values) {
addCriterion("threshold not in", values, "threshold");
return (Criteria) this;
}
public Criteria andThresholdBetween(Double value1, Double value2) {
addCriterion("threshold between", value1, value2, "threshold");
return (Criteria) this;
}
public Criteria andThresholdNotBetween(Double value1, Double value2) {
addCriterion("threshold not between", value1, value2, "threshold");
return (Criteria) this;
}
public Criteria andIsValidIsNull() {
addCriterion("is_valid is null");
return (Criteria) this;
......
......@@ -19,6 +19,8 @@ public class TblSqlCheckDuplex {
private String referColName;
private Double threshold;
private Integer isValid;
private String checkTime;
......@@ -95,6 +97,14 @@ public class TblSqlCheckDuplex {
this.referColName = referColName == null ? null : referColName.trim();
}
public Double getThreshold() {
return threshold;
}
public void setThreshold(Double threshold) {
this.threshold = threshold;
}
public Integer getIsValid() {
return isValid;
}
......
......@@ -655,6 +655,66 @@ public class TblSqlCheckDuplexCriteria {
return (Criteria) this;
}
public Criteria andThresholdIsNull() {
addCriterion("threshold is null");
return (Criteria) this;
}
public Criteria andThresholdIsNotNull() {
addCriterion("threshold is not null");
return (Criteria) this;
}
public Criteria andThresholdEqualTo(Double value) {
addCriterion("threshold =", value, "threshold");
return (Criteria) this;
}
public Criteria andThresholdNotEqualTo(Double value) {
addCriterion("threshold <>", value, "threshold");
return (Criteria) this;
}
public Criteria andThresholdGreaterThan(Double value) {
addCriterion("threshold >", value, "threshold");
return (Criteria) this;
}
public Criteria andThresholdGreaterThanOrEqualTo(Double value) {
addCriterion("threshold >=", value, "threshold");
return (Criteria) this;
}
public Criteria andThresholdLessThan(Double value) {
addCriterion("threshold <", value, "threshold");
return (Criteria) this;
}
public Criteria andThresholdLessThanOrEqualTo(Double value) {
addCriterion("threshold <=", value, "threshold");
return (Criteria) this;
}
public Criteria andThresholdIn(List<Double> values) {
addCriterion("threshold in", values, "threshold");
return (Criteria) this;
}
public Criteria andThresholdNotIn(List<Double> values) {
addCriterion("threshold not in", values, "threshold");
return (Criteria) this;
}
public Criteria andThresholdBetween(Double value1, Double value2) {
addCriterion("threshold between", value1, value2, "threshold");
return (Criteria) this;
}
public Criteria andThresholdNotBetween(Double value1, Double value2) {
addCriterion("threshold not between", value1, value2, "threshold");
return (Criteria) this;
}
public Criteria andIsValidIsNull() {
addCriterion("is_valid is null");
return (Criteria) this;
......
......@@ -13,6 +13,8 @@ public class TblSqlCheckSingle {
private String colName;
private Double threshold;
private Integer isValid;
private String checkTime;
......@@ -65,6 +67,14 @@ public class TblSqlCheckSingle {
this.colName = colName == null ? null : colName.trim();
}
public Double getThreshold() {
return threshold;
}
public void setThreshold(Double threshold) {
this.threshold = threshold;
}
public Integer getIsValid() {
return isValid;
}
......
......@@ -445,6 +445,66 @@ public class TblSqlCheckSingleCriteria {
return (Criteria) this;
}
public Criteria andThresholdIsNull() {
addCriterion("threshold is null");
return (Criteria) this;
}
public Criteria andThresholdIsNotNull() {
addCriterion("threshold is not null");
return (Criteria) this;
}
public Criteria andThresholdEqualTo(Double value) {
addCriterion("threshold =", value, "threshold");
return (Criteria) this;
}
public Criteria andThresholdNotEqualTo(Double value) {
addCriterion("threshold <>", value, "threshold");
return (Criteria) this;
}
public Criteria andThresholdGreaterThan(Double value) {
addCriterion("threshold >", value, "threshold");
return (Criteria) this;
}
public Criteria andThresholdGreaterThanOrEqualTo(Double value) {
addCriterion("threshold >=", value, "threshold");
return (Criteria) this;
}
public Criteria andThresholdLessThan(Double value) {
addCriterion("threshold <", value, "threshold");
return (Criteria) this;
}
public Criteria andThresholdLessThanOrEqualTo(Double value) {
addCriterion("threshold <=", value, "threshold");
return (Criteria) this;
}
public Criteria andThresholdIn(List<Double> values) {
addCriterion("threshold in", values, "threshold");
return (Criteria) this;
}
public Criteria andThresholdNotIn(List<Double> values) {
addCriterion("threshold not in", values, "threshold");
return (Criteria) this;
}
public Criteria andThresholdBetween(Double value1, Double value2) {
addCriterion("threshold between", value1, value2, "threshold");
return (Criteria) this;
}
public Criteria andThresholdNotBetween(Double value1, Double value2) {
addCriterion("threshold not between", value1, value2, "threshold");
return (Criteria) this;
}
public Criteria andIsValidIsNull() {
addCriterion("is_valid is null");
return (Criteria) this;
......
......@@ -17,6 +17,8 @@ public class TblSqlMonitorSpecial {
private String startTime;
private Double threshold;
private Integer isValid;
private String checkTime;
......@@ -85,6 +87,14 @@ public class TblSqlMonitorSpecial {
this.startTime = startTime == null ? null : startTime.trim();
}
public Double getThreshold() {
return threshold;
}
public void setThreshold(Double threshold) {
this.threshold = threshold;
}
public Integer getIsValid() {
return isValid;
}
......
......@@ -585,6 +585,66 @@ public class TblSqlMonitorSpecialCriteria {
return (Criteria) this;
}
public Criteria andThresholdIsNull() {
addCriterion("threshold is null");
return (Criteria) this;
}
public Criteria andThresholdIsNotNull() {
addCriterion("threshold is not null");
return (Criteria) this;
}
public Criteria andThresholdEqualTo(Double value) {
addCriterion("threshold =", value, "threshold");
return (Criteria) this;
}
public Criteria andThresholdNotEqualTo(Double value) {
addCriterion("threshold <>", value, "threshold");
return (Criteria) this;
}
public Criteria andThresholdGreaterThan(Double value) {
addCriterion("threshold >", value, "threshold");
return (Criteria) this;
}
public Criteria andThresholdGreaterThanOrEqualTo(Double value) {
addCriterion("threshold >=", value, "threshold");
return (Criteria) this;
}
public Criteria andThresholdLessThan(Double value) {
addCriterion("threshold <", value, "threshold");
return (Criteria) this;
}
public Criteria andThresholdLessThanOrEqualTo(Double value) {
addCriterion("threshold <=", value, "threshold");
return (Criteria) this;
}
public Criteria andThresholdIn(List<Double> values) {
addCriterion("threshold in", values, "threshold");
return (Criteria) this;
}
public Criteria andThresholdNotIn(List<Double> values) {
addCriterion("threshold not in", values, "threshold");
return (Criteria) this;
}
public Criteria andThresholdBetween(Double value1, Double value2) {
addCriterion("threshold between", value1, value2, "threshold");
return (Criteria) this;
}
public Criteria andThresholdNotBetween(Double value1, Double value2) {
addCriterion("threshold not between", value1, value2, "threshold");
return (Criteria) this;
}
public Criteria andIsValidIsNull() {
addCriterion("is_valid is null");
return (Criteria) this;
......
......@@ -13,6 +13,8 @@ public class TblSqlMonitorVolatility {
private String indicatorType;
private Double threshold;
private Integer isValid;
private String checkTime;
......@@ -65,6 +67,14 @@ public class TblSqlMonitorVolatility {
this.indicatorType = indicatorType == null ? null : indicatorType.trim();
}
public Double getThreshold() {
return threshold;
}
public void setThreshold(Double threshold) {
this.threshold = threshold;
}
public Integer getIsValid() {
return isValid;
}
......
......@@ -445,6 +445,66 @@ public class TblSqlMonitorVolatilityCriteria {
return (Criteria) this;
}
public Criteria andThresholdIsNull() {
addCriterion("threshold is null");
return (Criteria) this;
}
public Criteria andThresholdIsNotNull() {
addCriterion("threshold is not null");
return (Criteria) this;
}
public Criteria andThresholdEqualTo(Double value) {
addCriterion("threshold =", value, "threshold");
return (Criteria) this;
}
public Criteria andThresholdNotEqualTo(Double value) {
addCriterion("threshold <>", value, "threshold");
return (Criteria) this;
}
public Criteria andThresholdGreaterThan(Double value) {
addCriterion("threshold >", value, "threshold");
return (Criteria) this;
}
public Criteria andThresholdGreaterThanOrEqualTo(Double value) {
addCriterion("threshold >=", value, "threshold");
return (Criteria) this;
}
public Criteria andThresholdLessThan(Double value) {
addCriterion("threshold <", value, "threshold");
return (Criteria) this;
}
public Criteria andThresholdLessThanOrEqualTo(Double value) {
addCriterion("threshold <=", value, "threshold");
return (Criteria) this;
}
public Criteria andThresholdIn(List<Double> values) {
addCriterion("threshold in", values, "threshold");
return (Criteria) this;
}
public Criteria andThresholdNotIn(List<Double> values) {
addCriterion("threshold not in", values, "threshold");
return (Criteria) this;
}
public Criteria andThresholdBetween(Double value1, Double value2) {
addCriterion("threshold between", value1, value2, "threshold");
return (Criteria) this;
}
public Criteria andThresholdNotBetween(Double value1, Double value2) {
addCriterion("threshold not between", value1, value2, "threshold");
return (Criteria) this;
}
public Criteria andIsValidIsNull() {
addCriterion("is_valid is null");
return (Criteria) this;
......
......@@ -29,6 +29,8 @@ public class DqReferRuleDto extends BaseRowModel{
private String referColName;
@ExcelProperty(value = "参照表过滤条件",index = 10)
private String referFilters;
@ExcelProperty(value = "备注", index = 11)
@ExcelProperty(value = "阈值",index = 11)
private Double threshold;
@ExcelProperty(value = "备注", index = 12)
private String comment;
}
......@@ -27,6 +27,8 @@ public class DqSpecialRuleDto extends BaseRowModel {
private String startTime;
@ExcelProperty(value = "过滤条件", index = 9)
private String filters;
@ExcelProperty(value = "备注", index = 10)
@ExcelProperty(value = "阈值",index = 10)
private Double threshold;
@ExcelProperty(value = "备注", index = 11)
private String comment;
}
......@@ -21,6 +21,8 @@ public class DqUnblankRuleDto extends BaseRowModel{
private String colName;
@ExcelProperty(value = "过滤条件", index = 6)
private String filters;
@ExcelProperty(value = "备注", index = 7)
@ExcelProperty(value = "阈值",index = 7)
private Double threshold;
@ExcelProperty(value = "备注", index = 8)
private String comment;
}
......@@ -21,12 +21,8 @@ public class DqUniqueRuleDto extends BaseRowModel{
private String colName;
@ExcelProperty(value = "过滤条件", index = 6)
private String filters;
@ExcelProperty(value = "备注", index = 7)
@ExcelProperty(value = "阈值",index = 7)
private Double threshold;
@ExcelProperty(value = "备注", index = 8)
private String comment;
@Override
public String toString() {
return "DqUniqueRuleDto [checkType=" + checkType + ", isValid=" + isValid + ", checkTime=" + checkTime
+ ", dbName=" + dbName + ", tbName=" + tbName + ", colName=" + colName + ", filters=" + filters + "]";
}
}
......@@ -23,6 +23,8 @@ public class DqVolatilityRuleDto extends BaseRowModel{
private String indicatorType;
@ExcelProperty(value = "过滤条件", index = 7)
private String filters;
@ExcelProperty(value = "备注", index = 8)
@ExcelProperty(value = "阈值",index = 8)
private Double threshold;
@ExcelProperty(value = "备注", index = 9)
private String comment;
}
package com.gmei.data.dqmp.service;
public interface DingdingService {
Boolean sendMsgToDingding(String msg);
}
......@@ -26,6 +26,8 @@ import com.gmei.data.dqmp.mapper.TblSqlCheckDuplexMapper;
import com.gmei.data.dqmp.mapper.TblSqlCheckSingleMapper;
import com.gmei.data.dqmp.pool.JdbcConnectPool;
import com.gmei.data.dqmp.service.CheckService;
import com.gmei.data.dqmp.service.DingdingService;
import com.gmei.data.dqmp.service.MailService;
import com.gmei.data.dqmp.utils.DateUtils;
@Service
......@@ -41,6 +43,10 @@ public class CheckServiceImpl implements CheckService {
private TblResultCheckUnblankMapper tblResultCheckUnblankMapper;
@Autowired
private TblResultCheckReferMapper tblResultCheckReferMapper;
@Autowired
private MailService mailService;
@Autowired
private DingdingService dingdingService;
private static final Logger logger = LoggerFactory.getLogger(CheckServiceImpl.class);
/**
......
package com.gmei.data.dqmp.service.impl;
import org.apache.http.HttpResponse;
import org.apache.http.HttpStatus;
import org.apache.http.client.HttpClient;
import org.apache.http.client.methods.HttpPost;
import org.apache.http.entity.StringEntity;
import org.apache.http.impl.client.HttpClients;
import org.apache.http.util.EntityUtils;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.beans.factory.annotation.Value;
import com.alibaba.fastjson.JSONArray;
import com.alibaba.fastjson.JSONObject;
import com.gmei.data.dqmp.service.DingdingService;
public class DingdingServiceImpl implements DingdingService {
@Value("${dingding.webhookToken}")
private String webhookToken;
@Value("${dingding.atMobile}")
private String atMobile;
private static final Logger logger = LoggerFactory.getLogger(DingdingServiceImpl.class);
/**
* 发送钉钉消息
*
* @param jsonObject
* @throws Exception
*/
@Override
public Boolean sendMsgToDingding(String msg) {
JSONObject jsonObject = new JSONObject();
jsonObject.put("msgtype", "text");
JSONObject jo = new JSONObject();
jo.put("content", msg);
jsonObject.put("text", jo);
JSONObject joo = new JSONObject();
JSONArray ja = new JSONArray();
ja.add(atMobile);
joo.put("atMobiles", ja);
joo.put("isAtAll", false);
jsonObject.put("at", joo);
Boolean rs = false;
try {
HttpClient httpclient = HttpClients.createDefault();
HttpPost httppost = new HttpPost(webhookToken);
httppost.addHeader("Content-Type", "application/json; charset=utf-8");
String str = jsonObject.toString();
logger.info(str);
StringEntity se = new StringEntity(str, "utf-8");
httppost.setEntity(se);
HttpResponse response = httpclient.execute(httppost);
if (response.getStatusLine().getStatusCode() == HttpStatus.SC_OK) {
String result = EntityUtils.toString(response.getEntity(), "utf-8");
logger.info(result);
}
rs = true;
} catch (Exception e) {
logger.error(e.getMessage());
e.printStackTrace();
}
return rs;
}
}
package com.gmei.data.dqmp.vo;
import com.alibaba.excel.annotation.ExcelProperty;
import lombok.Data;
@Data
......@@ -16,5 +18,6 @@ public class DqReferRuleVo{
private String referTbName;
private String referColName;
private String referFilters;
private Double threshold;
private String comment;
}
......@@ -5,14 +5,16 @@ import org.hibernate.validator.constraints.NotBlank;
public class DqRuleVo extends BaseVo{
//common
@NotBlank(message = "校验类型字段不能为空")
@NotBlank(message = "校验类型不能为空")
private String checkType;
@NotNull(message = "状态字段不能为NULL")
@NotNull(message = "状态不能为NULL")
private Integer isValid;
@NotBlank(message = "校验时间字段不能为空")
@NotBlank(message = "校验时间不能为空")
private String checkTime;
@NotBlank(message = "校验规则备注")
private String comment;
@NotBlank(message = "阈值不能为空")
private Double threshold;
//simple
private String dbName;
......
......@@ -15,5 +15,6 @@ public class DqSpecialRuleVo {
private String indicatorType;
private String startTime;
private String filters;
private Double threshold;
private String comment;
}
......@@ -12,5 +12,6 @@ public class DqUnblankRuleVo{
private String tbName;
private String colName;
private String filters;
private Double threshold;
private String comment;
}
......@@ -12,5 +12,6 @@ public class DqUniqueRuleVo{
private String tbName;
private String colName;
private String filters;
private Double threshold;
private String comment;
}
......@@ -13,5 +13,6 @@ public class DqVolatilityRuleVo{
private String colName;
private String indicatorType;
private String filters;
private Double threshold;
private String comment;
}
......@@ -52,7 +52,12 @@ spring:
mail:
fromMail:
addr: youjiantongji@wanmeizhensuo.com
#---dingding send config---
dingding:
atMobile: 13051007691
webhookToken: https://oapi.dingtalk.com/robot/send?access_token=f7706a17b6de3ab6318806d1ed3d31fc68642bee99693280ee9a1591ab978c51
#---mybatis config---
mybatis:
mapper-locations: classpath:mybatis/mapper/*Mapper.xml
......
......@@ -52,6 +52,11 @@ spring:
mail:
fromMail:
addr: youjiantongji@wanmeizhensuo.com
#---dingding send config---
dingding:
atMobile: 13051007691
webhookToken: https://oapi.dingtalk.com/robot/send?access_token=68d7d6e9aaf81ebbf0f5228a3eadf769f1af0a7b0cb3dcb8fb8885dc5d93054f
#---mybatis config---
mybatis:
......
......@@ -52,6 +52,11 @@ spring:
mail:
fromMail:
addr: youjiantongji@wanmeizhensuo.com
#---dingding send config---
dingding:
atMobile: 13051007691
webhookToken: https://oapi.dingtalk.com/robot/send?access_token=f7706a17b6de3ab6318806d1ed3d31fc68642bee99693280ee9a1591ab978c51
#---mybatis config---
mybatis:
......
......@@ -10,6 +10,7 @@
<result column="refer_db_name" property="referDbName" jdbcType="VARCHAR" />
<result column="refer_tb_name" property="referTbName" jdbcType="VARCHAR" />
<result column="refer_col_name" property="referColName" jdbcType="VARCHAR" />
<result column="threshold" property="threshold" jdbcType="DOUBLE" />
<result column="is_valid" property="isValid" jdbcType="INTEGER" />
<result column="check_time" property="checkTime" jdbcType="VARCHAR" />
<result column="comment" property="comment" jdbcType="VARCHAR" />
......@@ -79,7 +80,7 @@
</sql>
<sql id="Base_Column_List" >
id, check_type, check_db_name, check_tb_name, check_col_name, refer_db_name, refer_tb_name,
refer_col_name, is_valid, check_time, comment, create_time
refer_col_name, threshold, is_valid, check_time, comment, create_time
</sql>
<sql id="Blob_Column_List" >
check_filters, refer_filters
......@@ -138,14 +139,14 @@
</selectKey>
insert into tbl_rule_info_duplex (check_type, check_db_name, check_tb_name,
check_col_name, refer_db_name, refer_tb_name,
refer_col_name, is_valid, check_time,
comment, create_time, check_filters,
refer_filters)
refer_col_name, threshold, is_valid,
check_time, comment, create_time,
check_filters, refer_filters)
values (#{checkType,jdbcType=VARCHAR}, #{checkDbName,jdbcType=VARCHAR}, #{checkTbName,jdbcType=VARCHAR},
#{checkColName,jdbcType=VARCHAR}, #{referDbName,jdbcType=VARCHAR}, #{referTbName,jdbcType=VARCHAR},
#{referColName,jdbcType=VARCHAR}, #{isValid,jdbcType=INTEGER}, #{checkTime,jdbcType=VARCHAR},
#{comment,jdbcType=VARCHAR}, #{createTime,jdbcType=TIMESTAMP}, #{checkFilters,jdbcType=LONGVARCHAR},
#{referFilters,jdbcType=LONGVARCHAR})
#{referColName,jdbcType=VARCHAR}, #{threshold,jdbcType=DOUBLE}, #{isValid,jdbcType=INTEGER},
#{checkTime,jdbcType=VARCHAR}, #{comment,jdbcType=VARCHAR}, #{createTime,jdbcType=TIMESTAMP},
#{checkFilters,jdbcType=LONGVARCHAR}, #{referFilters,jdbcType=LONGVARCHAR})
</insert>
<insert id="insertSelective" parameterType="com.gmei.data.dqmp.domain.TblRuleInfoDuplexWithBLOBs" >
<selectKey resultType="java.lang.Integer" keyProperty="id" order="AFTER" >
......@@ -174,6 +175,9 @@
<if test="referColName != null" >
refer_col_name,
</if>
<if test="threshold != null" >
threshold,
</if>
<if test="isValid != null" >
is_valid,
</if>
......@@ -215,6 +219,9 @@
<if test="referColName != null" >
#{referColName,jdbcType=VARCHAR},
</if>
<if test="threshold != null" >
#{threshold,jdbcType=DOUBLE},
</if>
<if test="isValid != null" >
#{isValid,jdbcType=INTEGER},
</if>
......@@ -268,6 +275,9 @@
<if test="record.referColName != null" >
refer_col_name = #{record.referColName,jdbcType=VARCHAR},
</if>
<if test="record.threshold != null" >
threshold = #{record.threshold,jdbcType=DOUBLE},
</if>
<if test="record.isValid != null" >
is_valid = #{record.isValid,jdbcType=INTEGER},
</if>
......@@ -301,6 +311,7 @@
refer_db_name = #{record.referDbName,jdbcType=VARCHAR},
refer_tb_name = #{record.referTbName,jdbcType=VARCHAR},
refer_col_name = #{record.referColName,jdbcType=VARCHAR},
threshold = #{record.threshold,jdbcType=DOUBLE},
is_valid = #{record.isValid,jdbcType=INTEGER},
check_time = #{record.checkTime,jdbcType=VARCHAR},
comment = #{record.comment,jdbcType=VARCHAR},
......@@ -321,6 +332,7 @@
refer_db_name = #{record.referDbName,jdbcType=VARCHAR},
refer_tb_name = #{record.referTbName,jdbcType=VARCHAR},
refer_col_name = #{record.referColName,jdbcType=VARCHAR},
threshold = #{record.threshold,jdbcType=DOUBLE},
is_valid = #{record.isValid,jdbcType=INTEGER},
check_time = #{record.checkTime,jdbcType=VARCHAR},
comment = #{record.comment,jdbcType=VARCHAR},
......@@ -353,6 +365,9 @@
<if test="referColName != null" >
refer_col_name = #{referColName,jdbcType=VARCHAR},
</if>
<if test="threshold != null" >
threshold = #{threshold,jdbcType=DOUBLE},
</if>
<if test="isValid != null" >
is_valid = #{isValid,jdbcType=INTEGER},
</if>
......@@ -383,6 +398,7 @@
refer_db_name = #{referDbName,jdbcType=VARCHAR},
refer_tb_name = #{referTbName,jdbcType=VARCHAR},
refer_col_name = #{referColName,jdbcType=VARCHAR},
threshold = #{threshold,jdbcType=DOUBLE},
is_valid = #{isValid,jdbcType=INTEGER},
check_time = #{checkTime,jdbcType=VARCHAR},
comment = #{comment,jdbcType=VARCHAR},
......@@ -400,6 +416,7 @@
refer_db_name = #{referDbName,jdbcType=VARCHAR},
refer_tb_name = #{referTbName,jdbcType=VARCHAR},
refer_col_name = #{referColName,jdbcType=VARCHAR},
threshold = #{threshold,jdbcType=DOUBLE},
is_valid = #{isValid,jdbcType=INTEGER},
check_time = #{checkTime,jdbcType=VARCHAR},
comment = #{comment,jdbcType=VARCHAR},
......
......@@ -10,6 +10,7 @@
<result column="time_col_name" property="timeColName" jdbcType="VARCHAR" />
<result column="indicator_type" property="indicatorType" jdbcType="VARCHAR" />
<result column="start_time" property="startTime" jdbcType="VARCHAR" />
<result column="threshold" property="threshold" jdbcType="DOUBLE" />
<result column="is_valid" property="isValid" jdbcType="INTEGER" />
<result column="check_time" property="checkTime" jdbcType="VARCHAR" />
<result column="comment" property="comment" jdbcType="VARCHAR" />
......@@ -78,7 +79,7 @@
</sql>
<sql id="Base_Column_List" >
id, check_type, db_name, tb_name, col_name, time_col_name, indicator_type, start_time,
is_valid, check_time, comment, create_time
threshold, is_valid, check_time, comment, create_time
</sql>
<sql id="Blob_Column_List" >
filters
......@@ -137,14 +138,14 @@
</selectKey>
insert into tbl_rule_info_simple (check_type, db_name, tb_name,
col_name, time_col_name, indicator_type,
start_time, is_valid, check_time,
comment, create_time, filters
)
start_time, threshold, is_valid,
check_time, comment, create_time,
filters)
values (#{checkType,jdbcType=VARCHAR}, #{dbName,jdbcType=VARCHAR}, #{tbName,jdbcType=VARCHAR},
#{colName,jdbcType=VARCHAR}, #{timeColName,jdbcType=VARCHAR}, #{indicatorType,jdbcType=VARCHAR},
#{startTime,jdbcType=VARCHAR}, #{isValid,jdbcType=INTEGER}, #{checkTime,jdbcType=VARCHAR},
#{comment,jdbcType=VARCHAR}, #{createTime,jdbcType=TIMESTAMP}, #{filters,jdbcType=LONGVARCHAR}
)
#{startTime,jdbcType=VARCHAR}, #{threshold,jdbcType=DOUBLE}, #{isValid,jdbcType=INTEGER},
#{checkTime,jdbcType=VARCHAR}, #{comment,jdbcType=VARCHAR}, #{createTime,jdbcType=TIMESTAMP},
#{filters,jdbcType=LONGVARCHAR})
</insert>
<insert id="insertSelective" parameterType="com.gmei.data.dqmp.domain.TblRuleInfoSimple" >
<selectKey resultType="java.lang.Integer" keyProperty="id" order="AFTER" >
......@@ -173,6 +174,9 @@
<if test="startTime != null" >
start_time,
</if>
<if test="threshold != null" >
threshold,
</if>
<if test="isValid != null" >
is_valid,
</if>
......@@ -211,6 +215,9 @@
<if test="startTime != null" >
#{startTime,jdbcType=VARCHAR},
</if>
<if test="threshold != null" >
#{threshold,jdbcType=DOUBLE},
</if>
<if test="isValid != null" >
#{isValid,jdbcType=INTEGER},
</if>
......@@ -261,6 +268,9 @@
<if test="record.startTime != null" >
start_time = #{record.startTime,jdbcType=VARCHAR},
</if>
<if test="record.threshold != null" >
threshold = #{record.threshold,jdbcType=DOUBLE},
</if>
<if test="record.isValid != null" >
is_valid = #{record.isValid,jdbcType=INTEGER},
</if>
......@@ -291,6 +301,7 @@
time_col_name = #{record.timeColName,jdbcType=VARCHAR},
indicator_type = #{record.indicatorType,jdbcType=VARCHAR},
start_time = #{record.startTime,jdbcType=VARCHAR},
threshold = #{record.threshold,jdbcType=DOUBLE},
is_valid = #{record.isValid,jdbcType=INTEGER},
check_time = #{record.checkTime,jdbcType=VARCHAR},
comment = #{record.comment,jdbcType=VARCHAR},
......@@ -310,6 +321,7 @@
time_col_name = #{record.timeColName,jdbcType=VARCHAR},
indicator_type = #{record.indicatorType,jdbcType=VARCHAR},
start_time = #{record.startTime,jdbcType=VARCHAR},
threshold = #{record.threshold,jdbcType=DOUBLE},
is_valid = #{record.isValid,jdbcType=INTEGER},
check_time = #{record.checkTime,jdbcType=VARCHAR},
comment = #{record.comment,jdbcType=VARCHAR},
......@@ -342,6 +354,9 @@
<if test="startTime != null" >
start_time = #{startTime,jdbcType=VARCHAR},
</if>
<if test="threshold != null" >
threshold = #{threshold,jdbcType=DOUBLE},
</if>
<if test="isValid != null" >
is_valid = #{isValid,jdbcType=INTEGER},
</if>
......@@ -369,6 +384,7 @@
time_col_name = #{timeColName,jdbcType=VARCHAR},
indicator_type = #{indicatorType,jdbcType=VARCHAR},
start_time = #{startTime,jdbcType=VARCHAR},
threshold = #{threshold,jdbcType=DOUBLE},
is_valid = #{isValid,jdbcType=INTEGER},
check_time = #{checkTime,jdbcType=VARCHAR},
comment = #{comment,jdbcType=VARCHAR},
......@@ -385,6 +401,7 @@
time_col_name = #{timeColName,jdbcType=VARCHAR},
indicator_type = #{indicatorType,jdbcType=VARCHAR},
start_time = #{startTime,jdbcType=VARCHAR},
threshold = #{threshold,jdbcType=DOUBLE},
is_valid = #{isValid,jdbcType=INTEGER},
check_time = #{checkTime,jdbcType=VARCHAR},
comment = #{comment,jdbcType=VARCHAR},
......
......@@ -10,6 +10,7 @@
<result column="refer_db_name" property="referDbName" jdbcType="VARCHAR" />
<result column="refer_tb_name" property="referTbName" jdbcType="VARCHAR" />
<result column="refer_col_name" property="referColName" jdbcType="VARCHAR" />
<result column="threshold" property="threshold" jdbcType="DOUBLE" />
<result column="is_valid" property="isValid" jdbcType="INTEGER" />
<result column="check_time" property="checkTime" jdbcType="VARCHAR" />
<result column="comment" property="comment" jdbcType="VARCHAR" />
......@@ -79,7 +80,7 @@
</sql>
<sql id="Base_Column_List" >
id, check_type, check_db_name, check_tb_name, check_col_name, refer_db_name, refer_tb_name,
refer_col_name, is_valid, check_time, comment, parent_id, create_time
refer_col_name, threshold, is_valid, check_time, comment, parent_id, create_time
</sql>
<sql id="Blob_Column_List" >
sql_content
......@@ -135,14 +136,16 @@
<insert id="insert" parameterType="com.gmei.data.dqmp.domain.TblSqlCheckDuplex" >
insert into tbl_sql_check_duplex (id, check_type, check_db_name,
check_tb_name, check_col_name, refer_db_name,
refer_tb_name, refer_col_name, is_valid,
check_time, comment, parent_id,
create_time, sql_content)
refer_tb_name, refer_col_name, threshold,
is_valid, check_time, comment,
parent_id, create_time, sql_content
)
values (#{id,jdbcType=INTEGER}, #{checkType,jdbcType=VARCHAR}, #{checkDbName,jdbcType=VARCHAR},
#{checkTbName,jdbcType=VARCHAR}, #{checkColName,jdbcType=VARCHAR}, #{referDbName,jdbcType=VARCHAR},
#{referTbName,jdbcType=VARCHAR}, #{referColName,jdbcType=VARCHAR}, #{isValid,jdbcType=INTEGER},
#{checkTime,jdbcType=VARCHAR}, #{comment,jdbcType=VARCHAR}, #{parentId,jdbcType=INTEGER},
#{createTime,jdbcType=TIMESTAMP}, #{sqlContent,jdbcType=LONGVARCHAR})
#{referTbName,jdbcType=VARCHAR}, #{referColName,jdbcType=VARCHAR}, #{threshold,jdbcType=DOUBLE},
#{isValid,jdbcType=INTEGER}, #{checkTime,jdbcType=VARCHAR}, #{comment,jdbcType=VARCHAR},
#{parentId,jdbcType=INTEGER}, #{createTime,jdbcType=TIMESTAMP}, #{sqlContent,jdbcType=LONGVARCHAR}
)
</insert>
<insert id="insertSelective" parameterType="com.gmei.data.dqmp.domain.TblSqlCheckDuplex" >
insert into tbl_sql_check_duplex
......@@ -171,6 +174,9 @@
<if test="referColName != null" >
refer_col_name,
</if>
<if test="threshold != null" >
threshold,
</if>
<if test="isValid != null" >
is_valid,
</if>
......@@ -215,6 +221,9 @@
<if test="referColName != null" >
#{referColName,jdbcType=VARCHAR},
</if>
<if test="threshold != null" >
#{threshold,jdbcType=DOUBLE},
</if>
<if test="isValid != null" >
#{isValid,jdbcType=INTEGER},
</if>
......@@ -268,6 +277,9 @@
<if test="record.referColName != null" >
refer_col_name = #{record.referColName,jdbcType=VARCHAR},
</if>
<if test="record.threshold != null" >
threshold = #{record.threshold,jdbcType=DOUBLE},
</if>
<if test="record.isValid != null" >
is_valid = #{record.isValid,jdbcType=INTEGER},
</if>
......@@ -301,6 +313,7 @@
refer_db_name = #{record.referDbName,jdbcType=VARCHAR},
refer_tb_name = #{record.referTbName,jdbcType=VARCHAR},
refer_col_name = #{record.referColName,jdbcType=VARCHAR},
threshold = #{record.threshold,jdbcType=DOUBLE},
is_valid = #{record.isValid,jdbcType=INTEGER},
check_time = #{record.checkTime,jdbcType=VARCHAR},
comment = #{record.comment,jdbcType=VARCHAR},
......@@ -321,6 +334,7 @@
refer_db_name = #{record.referDbName,jdbcType=VARCHAR},
refer_tb_name = #{record.referTbName,jdbcType=VARCHAR},
refer_col_name = #{record.referColName,jdbcType=VARCHAR},
threshold = #{record.threshold,jdbcType=DOUBLE},
is_valid = #{record.isValid,jdbcType=INTEGER},
check_time = #{record.checkTime,jdbcType=VARCHAR},
comment = #{record.comment,jdbcType=VARCHAR},
......@@ -354,6 +368,9 @@
<if test="referColName != null" >
refer_col_name = #{referColName,jdbcType=VARCHAR},
</if>
<if test="threshold != null" >
threshold = #{threshold,jdbcType=DOUBLE},
</if>
<if test="isValid != null" >
is_valid = #{isValid,jdbcType=INTEGER},
</if>
......@@ -384,6 +401,7 @@
refer_db_name = #{referDbName,jdbcType=VARCHAR},
refer_tb_name = #{referTbName,jdbcType=VARCHAR},
refer_col_name = #{referColName,jdbcType=VARCHAR},
threshold = #{threshold,jdbcType=DOUBLE},
is_valid = #{isValid,jdbcType=INTEGER},
check_time = #{checkTime,jdbcType=VARCHAR},
comment = #{comment,jdbcType=VARCHAR},
......@@ -401,6 +419,7 @@
refer_db_name = #{referDbName,jdbcType=VARCHAR},
refer_tb_name = #{referTbName,jdbcType=VARCHAR},
refer_col_name = #{referColName,jdbcType=VARCHAR},
threshold = #{threshold,jdbcType=DOUBLE},
is_valid = #{isValid,jdbcType=INTEGER},
check_time = #{checkTime,jdbcType=VARCHAR},
comment = #{comment,jdbcType=VARCHAR},
......
......@@ -7,6 +7,7 @@
<result column="db_name" property="dbName" jdbcType="VARCHAR" />
<result column="tb_name" property="tbName" jdbcType="VARCHAR" />
<result column="col_name" property="colName" jdbcType="VARCHAR" />
<result column="threshold" property="threshold" jdbcType="DOUBLE" />
<result column="is_valid" property="isValid" jdbcType="INTEGER" />
<result column="check_time" property="checkTime" jdbcType="VARCHAR" />
<result column="comment" property="comment" jdbcType="VARCHAR" />
......@@ -75,8 +76,8 @@
</where>
</sql>
<sql id="Base_Column_List" >
id, check_type, db_name, tb_name, col_name, is_valid, check_time, comment, parent_id,
create_time
id, check_type, db_name, tb_name, col_name, threshold, is_valid, check_time, comment,
parent_id, create_time
</sql>
<sql id="Blob_Column_List" >
sql_content
......@@ -131,13 +132,15 @@
</delete>
<insert id="insert" parameterType="com.gmei.data.dqmp.domain.TblSqlCheckSingle" >
insert into tbl_sql_check_single (id, check_type, db_name,
tb_name, col_name, is_valid,
check_time, comment, parent_id,
create_time, sql_content)
tb_name, col_name, threshold,
is_valid, check_time, comment,
parent_id, create_time, sql_content
)
values (#{id,jdbcType=INTEGER}, #{checkType,jdbcType=VARCHAR}, #{dbName,jdbcType=VARCHAR},
#{tbName,jdbcType=VARCHAR}, #{colName,jdbcType=VARCHAR}, #{isValid,jdbcType=INTEGER},
#{checkTime,jdbcType=VARCHAR}, #{comment,jdbcType=VARCHAR}, #{parentId,jdbcType=INTEGER},
#{createTime,jdbcType=TIMESTAMP}, #{sqlContent,jdbcType=LONGVARCHAR})
#{tbName,jdbcType=VARCHAR}, #{colName,jdbcType=VARCHAR}, #{threshold,jdbcType=DOUBLE},
#{isValid,jdbcType=INTEGER}, #{checkTime,jdbcType=VARCHAR}, #{comment,jdbcType=VARCHAR},
#{parentId,jdbcType=INTEGER}, #{createTime,jdbcType=TIMESTAMP}, #{sqlContent,jdbcType=LONGVARCHAR}
)
</insert>
<insert id="insertSelective" parameterType="com.gmei.data.dqmp.domain.TblSqlCheckSingle" >
insert into tbl_sql_check_single
......@@ -157,6 +160,9 @@
<if test="colName != null" >
col_name,
</if>
<if test="threshold != null" >
threshold,
</if>
<if test="isValid != null" >
is_valid,
</if>
......@@ -192,6 +198,9 @@
<if test="colName != null" >
#{colName,jdbcType=VARCHAR},
</if>
<if test="threshold != null" >
#{threshold,jdbcType=DOUBLE},
</if>
<if test="isValid != null" >
#{isValid,jdbcType=INTEGER},
</if>
......@@ -236,6 +245,9 @@
<if test="record.colName != null" >
col_name = #{record.colName,jdbcType=VARCHAR},
</if>
<if test="record.threshold != null" >
threshold = #{record.threshold,jdbcType=DOUBLE},
</if>
<if test="record.isValid != null" >
is_valid = #{record.isValid,jdbcType=INTEGER},
</if>
......@@ -266,6 +278,7 @@
db_name = #{record.dbName,jdbcType=VARCHAR},
tb_name = #{record.tbName,jdbcType=VARCHAR},
col_name = #{record.colName,jdbcType=VARCHAR},
threshold = #{record.threshold,jdbcType=DOUBLE},
is_valid = #{record.isValid,jdbcType=INTEGER},
check_time = #{record.checkTime,jdbcType=VARCHAR},
comment = #{record.comment,jdbcType=VARCHAR},
......@@ -283,6 +296,7 @@
db_name = #{record.dbName,jdbcType=VARCHAR},
tb_name = #{record.tbName,jdbcType=VARCHAR},
col_name = #{record.colName,jdbcType=VARCHAR},
threshold = #{record.threshold,jdbcType=DOUBLE},
is_valid = #{record.isValid,jdbcType=INTEGER},
check_time = #{record.checkTime,jdbcType=VARCHAR},
comment = #{record.comment,jdbcType=VARCHAR},
......@@ -307,6 +321,9 @@
<if test="colName != null" >
col_name = #{colName,jdbcType=VARCHAR},
</if>
<if test="threshold != null" >
threshold = #{threshold,jdbcType=DOUBLE},
</if>
<if test="isValid != null" >
is_valid = #{isValid,jdbcType=INTEGER},
</if>
......@@ -334,6 +351,7 @@
db_name = #{dbName,jdbcType=VARCHAR},
tb_name = #{tbName,jdbcType=VARCHAR},
col_name = #{colName,jdbcType=VARCHAR},
threshold = #{threshold,jdbcType=DOUBLE},
is_valid = #{isValid,jdbcType=INTEGER},
check_time = #{checkTime,jdbcType=VARCHAR},
comment = #{comment,jdbcType=VARCHAR},
......@@ -348,6 +366,7 @@
db_name = #{dbName,jdbcType=VARCHAR},
tb_name = #{tbName,jdbcType=VARCHAR},
col_name = #{colName,jdbcType=VARCHAR},
threshold = #{threshold,jdbcType=DOUBLE},
is_valid = #{isValid,jdbcType=INTEGER},
check_time = #{checkTime,jdbcType=VARCHAR},
comment = #{comment,jdbcType=VARCHAR},
......
......@@ -9,6 +9,7 @@
<result column="time_col_name" property="timeColName" jdbcType="VARCHAR" />
<result column="indicator_type" property="indicatorType" jdbcType="VARCHAR" />
<result column="start_time" property="startTime" jdbcType="VARCHAR" />
<result column="threshold" property="threshold" jdbcType="DOUBLE" />
<result column="is_valid" property="isValid" jdbcType="INTEGER" />
<result column="check_time" property="checkTime" jdbcType="VARCHAR" />
<result column="comment" property="comment" jdbcType="VARCHAR" />
......@@ -77,8 +78,8 @@
</where>
</sql>
<sql id="Base_Column_List" >
id, db_name, tb_name, col_name, time_col_name, indicator_type, start_time, is_valid,
check_time, comment, parent_id, create_time
id, db_name, tb_name, col_name, time_col_name, indicator_type, start_time, threshold,
is_valid, check_time, comment, parent_id, create_time
</sql>
<sql id="Blob_Column_List" >
sql_content
......@@ -134,14 +135,14 @@
<insert id="insert" parameterType="com.gmei.data.dqmp.domain.TblSqlMonitorSpecial" >
insert into tbl_sql_monitor_special (id, db_name, tb_name,
col_name, time_col_name, indicator_type,
start_time, is_valid, check_time,
comment, parent_id, create_time,
sql_content)
start_time, threshold, is_valid,
check_time, comment, parent_id,
create_time, sql_content)
values (#{id,jdbcType=INTEGER}, #{dbName,jdbcType=VARCHAR}, #{tbName,jdbcType=VARCHAR},
#{colName,jdbcType=VARCHAR}, #{timeColName,jdbcType=VARCHAR}, #{indicatorType,jdbcType=VARCHAR},
#{startTime,jdbcType=VARCHAR}, #{isValid,jdbcType=INTEGER}, #{checkTime,jdbcType=VARCHAR},
#{comment,jdbcType=VARCHAR}, #{parentId,jdbcType=INTEGER}, #{createTime,jdbcType=TIMESTAMP},
#{sqlContent,jdbcType=LONGVARCHAR})
#{startTime,jdbcType=VARCHAR}, #{threshold,jdbcType=DOUBLE}, #{isValid,jdbcType=INTEGER},
#{checkTime,jdbcType=VARCHAR}, #{comment,jdbcType=VARCHAR}, #{parentId,jdbcType=INTEGER},
#{createTime,jdbcType=TIMESTAMP}, #{sqlContent,jdbcType=LONGVARCHAR})
</insert>
<insert id="insertSelective" parameterType="com.gmei.data.dqmp.domain.TblSqlMonitorSpecial" >
insert into tbl_sql_monitor_special
......@@ -167,6 +168,9 @@
<if test="startTime != null" >
start_time,
</if>
<if test="threshold != null" >
threshold,
</if>
<if test="isValid != null" >
is_valid,
</if>
......@@ -208,6 +212,9 @@
<if test="startTime != null" >
#{startTime,jdbcType=VARCHAR},
</if>
<if test="threshold != null" >
#{threshold,jdbcType=DOUBLE},
</if>
<if test="isValid != null" >
#{isValid,jdbcType=INTEGER},
</if>
......@@ -258,6 +265,9 @@
<if test="record.startTime != null" >
start_time = #{record.startTime,jdbcType=VARCHAR},
</if>
<if test="record.threshold != null" >
threshold = #{record.threshold,jdbcType=DOUBLE},
</if>
<if test="record.isValid != null" >
is_valid = #{record.isValid,jdbcType=INTEGER},
</if>
......@@ -290,6 +300,7 @@
time_col_name = #{record.timeColName,jdbcType=VARCHAR},
indicator_type = #{record.indicatorType,jdbcType=VARCHAR},
start_time = #{record.startTime,jdbcType=VARCHAR},
threshold = #{record.threshold,jdbcType=DOUBLE},
is_valid = #{record.isValid,jdbcType=INTEGER},
check_time = #{record.checkTime,jdbcType=VARCHAR},
comment = #{record.comment,jdbcType=VARCHAR},
......@@ -309,6 +320,7 @@
time_col_name = #{record.timeColName,jdbcType=VARCHAR},
indicator_type = #{record.indicatorType,jdbcType=VARCHAR},
start_time = #{record.startTime,jdbcType=VARCHAR},
threshold = #{record.threshold,jdbcType=DOUBLE},
is_valid = #{record.isValid,jdbcType=INTEGER},
check_time = #{record.checkTime,jdbcType=VARCHAR},
comment = #{record.comment,jdbcType=VARCHAR},
......@@ -339,6 +351,9 @@
<if test="startTime != null" >
start_time = #{startTime,jdbcType=VARCHAR},
</if>
<if test="threshold != null" >
threshold = #{threshold,jdbcType=DOUBLE},
</if>
<if test="isValid != null" >
is_valid = #{isValid,jdbcType=INTEGER},
</if>
......@@ -368,6 +383,7 @@
time_col_name = #{timeColName,jdbcType=VARCHAR},
indicator_type = #{indicatorType,jdbcType=VARCHAR},
start_time = #{startTime,jdbcType=VARCHAR},
threshold = #{threshold,jdbcType=DOUBLE},
is_valid = #{isValid,jdbcType=INTEGER},
check_time = #{checkTime,jdbcType=VARCHAR},
comment = #{comment,jdbcType=VARCHAR},
......@@ -384,6 +400,7 @@
time_col_name = #{timeColName,jdbcType=VARCHAR},
indicator_type = #{indicatorType,jdbcType=VARCHAR},
start_time = #{startTime,jdbcType=VARCHAR},
threshold = #{threshold,jdbcType=DOUBLE},
is_valid = #{isValid,jdbcType=INTEGER},
check_time = #{checkTime,jdbcType=VARCHAR},
comment = #{comment,jdbcType=VARCHAR},
......
......@@ -7,6 +7,7 @@
<result column="tb_name" property="tbName" jdbcType="VARCHAR" />
<result column="col_name" property="colName" jdbcType="VARCHAR" />
<result column="indicator_type" property="indicatorType" jdbcType="VARCHAR" />
<result column="threshold" property="threshold" jdbcType="DOUBLE" />
<result column="is_valid" property="isValid" jdbcType="INTEGER" />
<result column="check_time" property="checkTime" jdbcType="VARCHAR" />
<result column="comment" property="comment" jdbcType="VARCHAR" />
......@@ -75,8 +76,8 @@
</where>
</sql>
<sql id="Base_Column_List" >
id, db_name, tb_name, col_name, indicator_type, is_valid, check_time, comment, parent_id,
create_time
id, db_name, tb_name, col_name, indicator_type, threshold, is_valid, check_time,
comment, parent_id, create_time
</sql>
<sql id="Blob_Column_List" >
sql_content
......@@ -131,13 +132,15 @@
</delete>
<insert id="insert" parameterType="com.gmei.data.dqmp.domain.TblSqlMonitorVolatility" >
insert into tbl_sql_monitor_volatility (id, db_name, tb_name,
col_name, indicator_type, is_valid,
check_time, comment, parent_id,
create_time, sql_content)
col_name, indicator_type, threshold,
is_valid, check_time, comment,
parent_id, create_time, sql_content
)
values (#{id,jdbcType=INTEGER}, #{dbName,jdbcType=VARCHAR}, #{tbName,jdbcType=VARCHAR},
#{colName,jdbcType=VARCHAR}, #{indicatorType,jdbcType=VARCHAR}, #{isValid,jdbcType=INTEGER},
#{checkTime,jdbcType=VARCHAR}, #{comment,jdbcType=VARCHAR}, #{parentId,jdbcType=INTEGER},
#{createTime,jdbcType=TIMESTAMP}, #{sqlContent,jdbcType=LONGVARCHAR})
#{colName,jdbcType=VARCHAR}, #{indicatorType,jdbcType=VARCHAR}, #{threshold,jdbcType=DOUBLE},
#{isValid,jdbcType=INTEGER}, #{checkTime,jdbcType=VARCHAR}, #{comment,jdbcType=VARCHAR},
#{parentId,jdbcType=INTEGER}, #{createTime,jdbcType=TIMESTAMP}, #{sqlContent,jdbcType=LONGVARCHAR}
)
</insert>
<insert id="insertSelective" parameterType="com.gmei.data.dqmp.domain.TblSqlMonitorVolatility" >
insert into tbl_sql_monitor_volatility
......@@ -157,6 +160,9 @@
<if test="indicatorType != null" >
indicator_type,
</if>
<if test="threshold != null" >
threshold,
</if>
<if test="isValid != null" >
is_valid,
</if>
......@@ -192,6 +198,9 @@
<if test="indicatorType != null" >
#{indicatorType,jdbcType=VARCHAR},
</if>
<if test="threshold != null" >
#{threshold,jdbcType=DOUBLE},
</if>
<if test="isValid != null" >
#{isValid,jdbcType=INTEGER},
</if>
......@@ -236,6 +245,9 @@
<if test="record.indicatorType != null" >
indicator_type = #{record.indicatorType,jdbcType=VARCHAR},
</if>
<if test="record.threshold != null" >
threshold = #{record.threshold,jdbcType=DOUBLE},
</if>
<if test="record.isValid != null" >
is_valid = #{record.isValid,jdbcType=INTEGER},
</if>
......@@ -266,6 +278,7 @@
tb_name = #{record.tbName,jdbcType=VARCHAR},
col_name = #{record.colName,jdbcType=VARCHAR},
indicator_type = #{record.indicatorType,jdbcType=VARCHAR},
threshold = #{record.threshold,jdbcType=DOUBLE},
is_valid = #{record.isValid,jdbcType=INTEGER},
check_time = #{record.checkTime,jdbcType=VARCHAR},
comment = #{record.comment,jdbcType=VARCHAR},
......@@ -283,6 +296,7 @@
tb_name = #{record.tbName,jdbcType=VARCHAR},
col_name = #{record.colName,jdbcType=VARCHAR},
indicator_type = #{record.indicatorType,jdbcType=VARCHAR},
threshold = #{record.threshold,jdbcType=DOUBLE},
is_valid = #{record.isValid,jdbcType=INTEGER},
check_time = #{record.checkTime,jdbcType=VARCHAR},
comment = #{record.comment,jdbcType=VARCHAR},
......@@ -307,6 +321,9 @@
<if test="indicatorType != null" >
indicator_type = #{indicatorType,jdbcType=VARCHAR},
</if>
<if test="threshold != null" >
threshold = #{threshold,jdbcType=DOUBLE},
</if>
<if test="isValid != null" >
is_valid = #{isValid,jdbcType=INTEGER},
</if>
......@@ -334,6 +351,7 @@
tb_name = #{tbName,jdbcType=VARCHAR},
col_name = #{colName,jdbcType=VARCHAR},
indicator_type = #{indicatorType,jdbcType=VARCHAR},
threshold = #{threshold,jdbcType=DOUBLE},
is_valid = #{isValid,jdbcType=INTEGER},
check_time = #{checkTime,jdbcType=VARCHAR},
comment = #{comment,jdbcType=VARCHAR},
......@@ -348,6 +366,7 @@
tb_name = #{tbName,jdbcType=VARCHAR},
col_name = #{colName,jdbcType=VARCHAR},
indicator_type = #{indicatorType,jdbcType=VARCHAR},
threshold = #{threshold,jdbcType=DOUBLE},
is_valid = #{isValid,jdbcType=INTEGER},
check_time = #{checkTime,jdbcType=VARCHAR},
comment = #{comment,jdbcType=VARCHAR},
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment