|
@@ -1,49 +1,81 @@
|
|
|
package com.jay.monitor.data.server.models.dto.alert;
|
|
|
|
|
|
+import com.alibaba.fastjson.annotation.JSONField;
|
|
|
import com.jay.monitor.data.core.enums.MsgTypeEnums;
|
|
|
import com.jay.monitor.data.core.model.serializable.base.ApplicationData;
|
|
|
import com.jay.monitor.data.core.model.serializable.base.LogDataData;
|
|
|
import com.jay.monitor.data.core.model.serializable.base.RequestDataData;
|
|
|
import com.jay.monitor.data.core.model.serializable.base.SearchIndexData;
|
|
|
-import com.jay.monitor.data.server.anno.Description;
|
|
|
+import com.jay.monitor.data.server.enums.AlertRuleEnums;
|
|
|
+
|
|
|
+import java.util.Date;
|
|
|
|
|
|
|
|
|
* @Module 告警模块
|
|
|
- * @Description 实时告警对象
|
|
|
+ * @JSONField 实时告警对象
|
|
|
* @Author liukaixiong
|
|
|
* @Date 2021/1/14 17:40
|
|
|
*/
|
|
|
public class RealTimeAlert implements ApplicationData, SearchIndexData, RequestDataData, LogDataData {
|
|
|
|
|
|
- @Description(value = "监控类型")
|
|
|
+ @JSONField(name = "触发原因",ordinal = 1)
|
|
|
+ private AlertRuleEnums triggerType;
|
|
|
+ @JSONField(name = "触发总数",ordinal = 2)
|
|
|
+ private Integer triggerCount;
|
|
|
+ @JSONField(name = "监控类型",ordinal = 3)
|
|
|
private MsgTypeEnums type;
|
|
|
- @Description(value = "服务名称")
|
|
|
+ @JSONField(name = "服务名称",ordinal = 4)
|
|
|
private String applicationName;
|
|
|
- @Description(value = "服务器ip")
|
|
|
+ @JSONField(name = "服务器ip",ordinal = 5)
|
|
|
private String ip;
|
|
|
- @Description(value ="请求url")
|
|
|
+ @JSONField(name = "请求url",ordinal = 6)
|
|
|
private String url;
|
|
|
- @Description(value ="用户编号")
|
|
|
+ @JSONField(name = "用户编号",ordinal = 7)
|
|
|
private String userId;
|
|
|
- @Description(value = "消息队列类型")
|
|
|
+ @JSONField(name = "消息队列类型",ordinal = 8)
|
|
|
private String mqType;
|
|
|
- @Description(value ="主题类型")
|
|
|
+ @JSONField(name = "主题类型",ordinal = 9)
|
|
|
private String topic;
|
|
|
- @Description(value ="消息编号")
|
|
|
+ @JSONField(name = "消息编号",ordinal = 10)
|
|
|
private String msgId;
|
|
|
- @Description(value = "组名称")
|
|
|
+ @JSONField(name = "组名称",ordinal = 11)
|
|
|
private String groupName;
|
|
|
- @Description(value = "组key名称")
|
|
|
+ @JSONField(name = "组key名称",ordinal = 12)
|
|
|
private String groupKeyName;
|
|
|
- @Description(value = "数据编号")
|
|
|
+ @JSONField(name = "数据编号",ordinal = 13)
|
|
|
private String dataId;
|
|
|
- @Description(value = "状态")
|
|
|
+ @JSONField(name = "状态",ordinal = 14)
|
|
|
private Integer status;
|
|
|
- @Description(value = "请求时长")
|
|
|
+ @JSONField(name = "请求时长",ordinal = 15)
|
|
|
private Long requestTime;
|
|
|
+ @JSONField(name = "创建时间", format = "yyyy-MM-dd HH:mm:ss",ordinal = 16)
|
|
|
+ private Date createDate;
|
|
|
+
|
|
|
+ private transient String logId;
|
|
|
+
|
|
|
+ public Integer getTriggerCount() {
|
|
|
+ return triggerCount;
|
|
|
+ }
|
|
|
+
|
|
|
+ public void setTriggerCount(Integer triggerCount) {
|
|
|
+ this.triggerCount = triggerCount;
|
|
|
+ }
|
|
|
|
|
|
- private String logId;
|
|
|
+ public AlertRuleEnums getTriggerType() {
|
|
|
+ return triggerType;
|
|
|
+ }
|
|
|
+
|
|
|
+ public void setTriggerType(AlertRuleEnums triggerType) {
|
|
|
+ this.triggerType = triggerType;
|
|
|
+ }
|
|
|
|
|
|
+ public Date getCreateDate() {
|
|
|
+ return createDate;
|
|
|
+ }
|
|
|
+
|
|
|
+ public void setCreateDate(Date createDate) {
|
|
|
+ this.createDate = createDate;
|
|
|
+ }
|
|
|
|
|
|
public String getUserId() {
|
|
|
return userId;
|