This repository has been archived on 2025-09-14. You can view files and clone it, but cannot push or open issues or pull requests.
Files
nezha-nz-talon/src/main/java/net/geedge/confagent/util/RCode.java

42 lines
1.3 KiB
Java
Raw Normal View History

2021-07-09 17:01:27 +08:00
package net.geedge.confagent.util;
public enum RCode {
SUCCESS(200, "success"), //成功
AUTH_NAME_PIN_ISNULL(10000,"The name and password is required"),
AUTH_NAME_PIN_INVALID(10001,"The name or password is invalid"),
AUTH_TOKEN_INVALID(10002,"The token is invalid"),
AUTH_TOKEN_ISNULL(10003,"Token is required"),
AUTH_READ_TOKEN_FAILD(10004,"Read token failed"),
CONFIG_PROMTAIL_RELOAD_FAILED(10005,"Reload prometheus failed"),
CONFIG_BLAVKBOX_RELOAD_FAILED(10006,"Reload blackbox_exporter failed"),
CONFIG_SNMP_EXPORTER_RELOAD_FAILED(10007,"Reload snmp_exporter failed"),
PROMTAIL_CONFIG_VERSION_ISNULL(10008,"The promtail config version is required"),
PROMTAIL_START_CMD_ERROR(10009,"The promtail start command is error"),
PROMTAIL_STOP_CMD_ERROR(10010,"The promtail stop command is error"),
2021-07-09 17:01:27 +08:00
OTA_FILE_CACHE_ERROR(10011,"Cache rpm package failed"),
OTA_MD5_ERROR(10012,"MD5 is error"),
OTA_VERSION_ERROR(10013,"The updated version is lower than the current version"),
OTA_ATD_SERVICE_DOWN(10014,"The ATD service is down"),
2021-07-09 17:01:27 +08:00
ERROR(999, "error"); //通用错误/未知错误
private RCode(Integer code, String msg) {
this.code = code;
this.msg = msg;
}
private Integer code;
private String msg;
public Integer getCode() {
return code;
}
public String getMsg() {
return msg;
}
}