diff --git a/alerter/src/main/java/org/dromara/hertzbeat/alert/AlerterProperties.java b/alerter/src/main/java/org/dromara/hertzbeat/alert/AlerterProperties.java index 8018f0118e..ab6506d8eb 100644 --- a/alerter/src/main/java/org/dromara/hertzbeat/alert/AlerterProperties.java +++ b/alerter/src/main/java/org/dromara/hertzbeat/alert/AlerterProperties.java @@ -23,9 +23,7 @@ import org.springframework.boot.context.properties.ConfigurationProperties; import org.springframework.stereotype.Component; /** - * alerter config - * - * + * alerter prop config * */ @Component @@ -35,7 +33,6 @@ import org.springframework.stereotype.Component; public class AlerterProperties { /** - * 告警内容控制台链接 * Alarm content console link */ private String consoleUrl = "https://console.tancloud.cn"; @@ -71,41 +68,19 @@ public class AlerterProperties { private String serverChanNotifyUrl = "https://sctapi.ftqq.com/%s.send"; /** - * 告警评估时间间隔起始基数 每下一次乘2 单位毫秒 - * base of alert eval interval time, unit:ms. The next time is 2 times the previous time. - */ - @Deprecated - private long alertEvalIntervalBase = 1000 * 60 * 10L; - - /** - * 最大告警评估时间间隔 单位毫秒 - * max of alert eval interval time, unit:ms - */ - @Deprecated - private long maxAlertEvalInterval = 1000 * 60 * 60 * 24L; - - /** - * 系统内置告警(available alert, reachable alert...)触发次数 - * system alert(available alert, reachable alert...) trigger times - */ - @Deprecated - private int systemAlertTriggerTimes = 1; - - /** - * Data entry configuration properties 数据入口配置属性 + * Data entry configuration properties */ private EntranceProperties entrance; /** - * Data entry configuration properties 数据入口配置属性 - * The entry can obtain data from messaging middleware such as kafka rabbitmq rocketmq 入口可以是从kafka rabbitmq rocketmq等消息中间件获取数据 + * Data entry configuration properties */ @Getter @Setter public static class EntranceProperties { /** - * kafka configuration information kafka配置信息 + * kafka configuration information */ private KafkaProperties kafka; @@ -113,20 +88,20 @@ public class AlerterProperties { @Setter public static class KafkaProperties { /** - * Whether the kafka data entry is started kafka数据入口是否启动 + * Whether the kafka data entry is started */ private boolean enabled = true; /** - * kafka's connection server url kafka的连接服务器url + * kafka's connection server url */ private String servers = "127.0.0.1:9092"; /** - * The name of the topic that receives the data 接收数据的topic名称 + * The name of the topic that receives the data */ private String topic; /** - * Consumer Group ID 消费者组ID + * Consumer Group ID */ private String groupId; diff --git a/alerter/src/main/java/org/dromara/hertzbeat/alert/AlerterWorkerPool.java b/alerter/src/main/java/org/dromara/hertzbeat/alert/AlerterWorkerPool.java index 851fcaadda..e0108d49e9 100644 --- a/alerter/src/main/java/org/dromara/hertzbeat/alert/AlerterWorkerPool.java +++ b/alerter/src/main/java/org/dromara/hertzbeat/alert/AlerterWorkerPool.java @@ -28,8 +28,7 @@ import java.util.concurrent.ThreadPoolExecutor; import java.util.concurrent.TimeUnit; /** - * warehouse 工作线程池 - * + * alarm module thread pool * */ @Component @@ -43,11 +42,11 @@ public class AlerterWorkerPool { } private void initWorkExecutor() { - // 线程工厂 ThreadFactory threadFactory = new ThreadFactoryBuilder() .setUncaughtExceptionHandler((thread, throwable) -> { log.error("workerExecutor has uncaughtException."); - log.error(throwable.getMessage(), throwable); }) + log.error(throwable.getMessage(), throwable); + }) .setDaemon(true) .setNameFormat("alerter-worker-%d") .build(); @@ -61,9 +60,9 @@ public class AlerterWorkerPool { } /** - * Run the alerter task 运行alerter任务 - * @param runnable task 任务 - * @throws RejectedExecutionException when The thread pool is full of 线程池满 + * Run the alerter task + * @param runnable task + * @throws RejectedExecutionException when The thread pool is full of */ public void executeJob(Runnable runnable) throws RejectedExecutionException { workerExecutor.execute(runnable); diff --git a/alerter/src/main/java/org/dromara/hertzbeat/alert/calculate/CalculateAlarm.java b/alerter/src/main/java/org/dromara/hertzbeat/alert/calculate/CalculateAlarm.java index 17b0a17948..761cd538e8 100644 --- a/alerter/src/main/java/org/dromara/hertzbeat/alert/calculate/CalculateAlarm.java +++ b/alerter/src/main/java/org/dromara/hertzbeat/alert/calculate/CalculateAlarm.java @@ -55,8 +55,6 @@ import static org.dromara.hertzbeat.common.constants.CommonConstants.*; /** * Calculate alarms based on the alarm definition rules and collected data - * 根据告警定义规则和采集数据匹配计算告警 - * * */ @Component @@ -96,7 +94,6 @@ public class CalculateAlarm { this.triggeredAlertMap = new ConcurrentHashMap<>(128); this.notRecoveredAlertMap = new ConcurrentHashMap<>(128); // Initialize stateAlertMap - // 初始化stateAlertMap List monitors = monitorDao.findMonitorsByStatus(CommonConstants.UN_AVAILABLE_CODE); if (monitors != null) { for (Monitor monitor : monitors) { @@ -136,13 +133,12 @@ public class CalculateAlarm { long monitorId = metricsData.getId(); String app = metricsData.getApp(); String metrics = metricsData.getMetrics(); - // If the indicator group whose scheduling priority is 0 has the status of collecting response data UN_REACHABLE/UN_CONNECTABLE, the highest severity alarm is generated to monitor the status change - // 先判断调度优先级为0的指标组采集响应数据状态 UN_REACHABLE/UN_CONNECTABLE 则需发最高级别告警进行任务状态变更 + // If the metrics whose scheduling priority is 0 has the status of collecting response data UN_REACHABLE/UN_CONNECTABLE, + // the highest severity alarm is generated to monitor the status change if (metricsData.getPriority() == 0) { handlerAvailableMetrics(monitorId, app, metricsData); } - // Query the alarm definitions associated with the indicator set of the monitoring type - // 查出此监控类型下的此指标集合下关联配置的告警定义信息 + // Query the alarm definitions associated with the metrics of the monitoring type // field - define[] Map> defineMap = alertDefineService.getMonitorBindAlertDefines(monitorId, app, metrics); if (defineMap.isEmpty()) { @@ -293,7 +289,6 @@ public class CalculateAlarm { .firstAlarmTime(currentTimeMilli) .lastAlarmTime(currentTimeMilli) // Keyword matching and substitution in the template - // 模板中关键字匹配替换 .content(AlertTemplateUtil.render(define.getTemplate(), fieldValueMap)) .build(); int defineTimes = define.getTimes() == null ? 1 : define.getTimes(); diff --git a/alerter/src/main/java/org/dromara/hertzbeat/alert/config/AlerterAutoConfiguration.java b/alerter/src/main/java/org/dromara/hertzbeat/alert/config/AlerterAutoConfiguration.java index 1af2b1a3c3..0c5e06ac40 100644 --- a/alerter/src/main/java/org/dromara/hertzbeat/alert/config/AlerterAutoConfiguration.java +++ b/alerter/src/main/java/org/dromara/hertzbeat/alert/config/AlerterAutoConfiguration.java @@ -22,7 +22,6 @@ import org.springframework.context.annotation.ComponentScan; /** * * @version 2.1 - * Created by Musk.Chen on 2023/1/14 */ @ComponentScan(basePackages = "org.dromara.hertzbeat.alert") public class AlerterAutoConfiguration { diff --git a/alerter/src/main/java/org/dromara/hertzbeat/alert/controller/AlertConvergeController.java b/alerter/src/main/java/org/dromara/hertzbeat/alert/controller/AlertConvergeController.java index bcf446ca34..6225abc363 100644 --- a/alerter/src/main/java/org/dromara/hertzbeat/alert/controller/AlertConvergeController.java +++ b/alerter/src/main/java/org/dromara/hertzbeat/alert/controller/AlertConvergeController.java @@ -34,8 +34,6 @@ import static org.springframework.http.MediaType.APPLICATION_JSON_VALUE; /** * Alarm Converge management API - * 告警收敛管理API - * * */ @Tag(name = "Alert Converge API | 告警收敛管理API") diff --git a/alerter/src/main/java/org/dromara/hertzbeat/alert/controller/AlertConvergesController.java b/alerter/src/main/java/org/dromara/hertzbeat/alert/controller/AlertConvergesController.java index 64e30cf5a0..373462cd76 100644 --- a/alerter/src/main/java/org/dromara/hertzbeat/alert/controller/AlertConvergesController.java +++ b/alerter/src/main/java/org/dromara/hertzbeat/alert/controller/AlertConvergesController.java @@ -42,8 +42,6 @@ import static org.springframework.http.MediaType.APPLICATION_JSON_VALUE; /** * Converge the batch API for alarms - * 收敛告警批量API - * * */ @Tag(name = "Alert Converge Batch API | 告警收敛管理API") diff --git a/alerter/src/main/java/org/dromara/hertzbeat/alert/controller/AlertDefineController.java b/alerter/src/main/java/org/dromara/hertzbeat/alert/controller/AlertDefineController.java index c7a58f7562..383e2e0fe0 100644 --- a/alerter/src/main/java/org/dromara/hertzbeat/alert/controller/AlertDefineController.java +++ b/alerter/src/main/java/org/dromara/hertzbeat/alert/controller/AlertDefineController.java @@ -45,8 +45,6 @@ import static org.springframework.http.MediaType.APPLICATION_JSON_VALUE; /** * Alarm definition management API - * 告警定义管理API - * * */ @Tag(name = "Alert Define API | 告警定义管理API") @@ -61,7 +59,6 @@ public class AlertDefineController { @Operation(summary = "New Alarm Definition | 新增告警定义", description = "Added an alarm definition | 新增一个告警定义") public ResponseEntity> addNewAlertDefine(@Valid @RequestBody AlertDefine alertDefine) { // Verify request data - // 校验请求数据 alertDefineService.validate(alertDefine, false); alertDefineService.addAlertDefine(alertDefine); return ResponseEntity.ok(Message.success("Add success")); @@ -71,7 +68,6 @@ public class AlertDefineController { @Operation(summary = "Modifying an Alarm Definition | 修改告警定义", description = "Modify an existing alarm definition | 修改一个已存在告警定义") public ResponseEntity> modifyAlertDefine(@Valid @RequestBody AlertDefine alertDefine) { // Verify request data - // 校验请求数据 alertDefineService.validate(alertDefine, true); alertDefineService.modifyAlertDefine(alertDefine); return ResponseEntity.ok(Message.success("Modify success")); @@ -83,7 +79,6 @@ public class AlertDefineController { public ResponseEntity> getAlertDefine( @Parameter(description = "Alarm Definition ID | 告警定义ID", example = "6565463543") @PathVariable("id") long id) { // Obtaining Monitoring Information - // 获取监控信息 AlertDefine alertDefine = alertDefineService.getAlertDefine(id); if (alertDefine == null) { return ResponseEntity.ok(Message.fail(MONITOR_NOT_EXIST_CODE, "AlertDefine not exist.")); @@ -98,7 +93,6 @@ public class AlertDefineController { public ResponseEntity> deleteAlertDefine( @Parameter(description = "Alarm Definition ID | 告警定义ID", example = "6565463543") @PathVariable("id") long id) { // If the alarm definition does not exist or is deleted successfully, the deletion succeeds - // 删除告警定义不存在或删除成功都返回成功 alertDefineService.deleteAlertDefine(id); return ResponseEntity.ok(Message.success("Delete success")); } diff --git a/alerter/src/main/java/org/dromara/hertzbeat/alert/controller/AlertDefinesController.java b/alerter/src/main/java/org/dromara/hertzbeat/alert/controller/AlertDefinesController.java index 2ac2bcb801..c97428538e 100644 --- a/alerter/src/main/java/org/dromara/hertzbeat/alert/controller/AlertDefinesController.java +++ b/alerter/src/main/java/org/dromara/hertzbeat/alert/controller/AlertDefinesController.java @@ -46,8 +46,6 @@ import static org.springframework.http.MediaType.APPLICATION_JSON_VALUE; /** * Define the batch API for alarms - * 告警定义批量API - * * */ @Tag(name = "Alert Define Batch API | 告警定义管理API") @@ -111,7 +109,6 @@ public class AlertDefinesController { Predicate[] predicates = new Predicate[andList.size()]; return criteriaBuilder.and(andList.toArray(predicates)); }; - // 分页是必须的 Sort sortExp = Sort.by(new Sort.Order(Sort.Direction.fromString(order), sort)); PageRequest pageRequest = PageRequest.of(pageIndex, pageSize, sortExp); Page alertDefinePage = alertDefineService.getAlertDefines(specification, pageRequest); diff --git a/alerter/src/main/java/org/dromara/hertzbeat/alert/controller/AlertReportController.java b/alerter/src/main/java/org/dromara/hertzbeat/alert/controller/AlertReportController.java index 7ecd028496..c8c063cd71 100644 --- a/alerter/src/main/java/org/dromara/hertzbeat/alert/controller/AlertReportController.java +++ b/alerter/src/main/java/org/dromara/hertzbeat/alert/controller/AlertReportController.java @@ -20,8 +20,8 @@ import java.util.Optional; import static org.springframework.http.MediaType.APPLICATION_JSON_VALUE; /** + * Extern Alarm Manage API * - * 第三方告警上报接口 */ @Tag(name = "Extern Alarm Manage API | 第三方告警管理API") @RestController @@ -33,8 +33,7 @@ public class AlertReportController { private AlertService alertService; @PostMapping("/{cloud}") - @Operation(summary = "Interface for reporting external alarm information of cloud service | 对外上报告警信息 接口", - description = "对外 新增一个云服务告警") + @Operation(summary = "Interface for reporting external alarm information of cloud service | 对外上报告警信息接口") public ResponseEntity> addNewAlertReportFromCloud(@PathVariable("cloud") String cloudServiceName, @RequestBody String alertReport) { // 根据枚举获取到对应的枚举对象 diff --git a/alerter/src/main/java/org/dromara/hertzbeat/alert/controller/AlertSilenceController.java b/alerter/src/main/java/org/dromara/hertzbeat/alert/controller/AlertSilenceController.java index f5a761fe2c..6dee805696 100644 --- a/alerter/src/main/java/org/dromara/hertzbeat/alert/controller/AlertSilenceController.java +++ b/alerter/src/main/java/org/dromara/hertzbeat/alert/controller/AlertSilenceController.java @@ -35,8 +35,6 @@ import static org.springframework.http.MediaType.APPLICATION_JSON_VALUE; /** * Alarm Silence management API - * 告警静默管理API - * * */ @Tag(name = "Alert Silence API | 告警静默管理API") diff --git a/alerter/src/main/java/org/dromara/hertzbeat/alert/controller/AlertSilencesController.java b/alerter/src/main/java/org/dromara/hertzbeat/alert/controller/AlertSilencesController.java index d4dbeb7340..5ddaf8efcb 100644 --- a/alerter/src/main/java/org/dromara/hertzbeat/alert/controller/AlertSilencesController.java +++ b/alerter/src/main/java/org/dromara/hertzbeat/alert/controller/AlertSilencesController.java @@ -42,8 +42,6 @@ import static org.springframework.http.MediaType.APPLICATION_JSON_VALUE; /** * Silence the batch API for alarms - * 静默告警批量API - * * */ @Tag(name = "Alert Silence Batch API | 告警静默管理API") diff --git a/alerter/src/main/java/org/dromara/hertzbeat/alert/controller/AlertsController.java b/alerter/src/main/java/org/dromara/hertzbeat/alert/controller/AlertsController.java index 6c509bf7d5..29f6a4e720 100644 --- a/alerter/src/main/java/org/dromara/hertzbeat/alert/controller/AlertsController.java +++ b/alerter/src/main/java/org/dromara/hertzbeat/alert/controller/AlertsController.java @@ -41,9 +41,7 @@ import java.util.List; import static org.springframework.http.MediaType.APPLICATION_JSON_VALUE; /** - * Alarm Management API 告警管理API - * - * + * Alarm Management API * * */ diff --git a/alerter/src/main/java/org/dromara/hertzbeat/alert/dao/AlertConvergeDao.java b/alerter/src/main/java/org/dromara/hertzbeat/alert/dao/AlertConvergeDao.java index afb8dea0bd..2f33f9f526 100644 --- a/alerter/src/main/java/org/dromara/hertzbeat/alert/dao/AlertConvergeDao.java +++ b/alerter/src/main/java/org/dromara/hertzbeat/alert/dao/AlertConvergeDao.java @@ -25,8 +25,7 @@ import org.springframework.data.jpa.repository.Modifying; import java.util.Set; /** - * AlertConverge 数据库操作 - * + * AlertConverge Dao * */ public interface AlertConvergeDao extends JpaRepository, JpaSpecificationExecutor { diff --git a/alerter/src/main/java/org/dromara/hertzbeat/alert/dao/AlertDao.java b/alerter/src/main/java/org/dromara/hertzbeat/alert/dao/AlertDao.java index a867515863..d9ac7cb5a9 100644 --- a/alerter/src/main/java/org/dromara/hertzbeat/alert/dao/AlertDao.java +++ b/alerter/src/main/java/org/dromara/hertzbeat/alert/dao/AlertDao.java @@ -29,26 +29,21 @@ import java.util.List; import java.util.Set; /** - * Alert Database Operations Alert数据库表操作 - * - * + * Alert Database Operations * */ public interface AlertDao extends JpaRepository, JpaSpecificationExecutor { /** - * Delete alerts based on ID list 根据ID列表删除告警 - * - * @param alertIds Alert ID List 告警ID列表 + * Delete alerts based on ID list + * @param alertIds Alert ID List */ void deleteAlertsByIdIn(Set alertIds); /** * Updates the alarm status based on the alarm ID-status value - * 根据告警ID-状态值 更新告警状态 - * - * @param status 状态值 - * @param ids 告警ID列表 + * @param status status value + * @param ids alarm ids */ @Modifying @Query("update Alert set status = :status where id in :ids") @@ -57,8 +52,7 @@ public interface AlertDao extends JpaRepository, JpaSpecificationEx /** * Query the number of unhandled alarms of each alarm severity * 查询各个告警级别的未处理告警数量 - * - * @return List of alerts num 告警数量 + * @return List of alerts num */ @Query("select new org.dromara.hertzbeat.alert.dto.AlertPriorityNum(mo.priority, count(mo.id)) from Alert mo where mo.status = 0 group by mo.priority") List findAlertPriorityNum(); diff --git a/alerter/src/main/java/org/dromara/hertzbeat/alert/dao/AlertDefineBindDao.java b/alerter/src/main/java/org/dromara/hertzbeat/alert/dao/AlertDefineBindDao.java index 35cb020597..c6856ce6c1 100644 --- a/alerter/src/main/java/org/dromara/hertzbeat/alert/dao/AlertDefineBindDao.java +++ b/alerter/src/main/java/org/dromara/hertzbeat/alert/dao/AlertDefineBindDao.java @@ -25,43 +25,33 @@ import java.util.List; import java.util.Set; /** - * AlertDefineBind database operations 数据库操作 - * - * + * AlertDefineBind database operations * */ public interface AlertDefineBindDao extends JpaRepository, JpaSpecificationExecutor { /** * Delete the alarm definition and monitor association based on the alarm definition ID - * 根据告警定义ID删除告警定义与监控关联 - * - * @param alertDefineId Alarm Definition ID 告警定义ID + * @param alertDefineId Alarm Definition ID */ void deleteAlertDefineBindsByAlertDefineIdEquals(Long alertDefineId); /** * Deleting alarms based on monitoring IDs defines monitoring associations - * 根据监控任务ID删除告警定义监控关联 - * - * @param monitorId Monitor Id 监控任务ID + * @param monitorId Monitor Id */ void deleteAlertDefineMonitorBindsByMonitorIdEquals(Long monitorId); /** * Delete alarm definition monitoring association based on monitoring ID list - * 根据监控任务ID列表删除告警定义监控关联 - * - * @param monitorIds Monitoring ID List 监控任务ID列表 + * @param monitorIds Monitoring ID List */ void deleteAlertDefineMonitorBindsByMonitorIdIn(Set monitorIds); /** * Query monitoring related information based on alarm definition ID - * 根据告警定义ID查询监控关联信息 - * - * @param alertDefineId Alarm Definition ID 告警定义ID - * @return Associated monitoring information 关联监控信息 + * @param alertDefineId Alarm Definition ID + * @return Associated monitoring information */ List getAlertDefineBindsByAlertDefineIdEquals(Long alertDefineId); } diff --git a/alerter/src/main/java/org/dromara/hertzbeat/alert/dao/AlertDefineDao.java b/alerter/src/main/java/org/dromara/hertzbeat/alert/dao/AlertDefineDao.java index be643be2b4..711e7edd96 100644 --- a/alerter/src/main/java/org/dromara/hertzbeat/alert/dao/AlertDefineDao.java +++ b/alerter/src/main/java/org/dromara/hertzbeat/alert/dao/AlertDefineDao.java @@ -27,25 +27,23 @@ import java.util.List; import java.util.Set; /** - * AlertDefine 数据库操作 - * + * AlertDefine Dao * */ public interface AlertDefineDao extends JpaRepository, JpaSpecificationExecutor { /** * Delete alarm definitions based on the ID list - * 根据ID列表删除告警定义 - * @param alertDefineIds 告警定义ID列表 + * @param alertDefineIds alarm define ids */ void deleteAlertDefinesByIdIn(Set alertDefineIds); /** - * Query the default alarm thresholds based on the monitoring indicator type + * Query the default alarm thresholds based on the monitoring metrics type * 根据监控指标类型查询对应默认告警定义阈值 - * @param app 监控类型 - * @param metric 指标集合类型 - * @return The alarm is defined | 告警定义 + * @param app monitoring type + * @param metric metrics + * @return alarm defines */ List queryAlertDefinesByAppAndMetricAndPresetTrueAndEnableTrue(String app, String metric); @@ -61,10 +59,10 @@ public interface AlertDefineDao extends JpaRepository, JpaSpe /** * Query the alarm definition list associated with the monitoring ID * 根据监控任务ID查询与之关联的告警定义列表 - * @param monitorId 监控任务ID - * @param app 监控类型 - * @param metrics 指标组 - * @return Alarm Definition List | 告警定义列表 + * @param monitorId monitor id + * @param app monitor type + * @param metrics metrics + * @return Alarm Definition List */ @Query("select define from AlertDefine define join AlertDefineMonitorBind bind on bind.alertDefineId = define.id " + "where bind.monitorId = :monitorId and define.app = :app and define.metric = :metrics and define.enable = true and define.preset = false") diff --git a/alerter/src/main/java/org/dromara/hertzbeat/alert/dao/AlertMonitorDao.java b/alerter/src/main/java/org/dromara/hertzbeat/alert/dao/AlertMonitorDao.java index 42633eea87..7ff493ae47 100644 --- a/alerter/src/main/java/org/dromara/hertzbeat/alert/dao/AlertMonitorDao.java +++ b/alerter/src/main/java/org/dromara/hertzbeat/alert/dao/AlertMonitorDao.java @@ -27,24 +27,15 @@ import org.springframework.data.repository.query.Param; import java.util.List; /** - * Alert Monitor 数据库操作 - * + * Alert Monitor Dao * */ public interface AlertMonitorDao extends JpaRepository, JpaSpecificationExecutor { - - /** - * Query the monitoring status of a specified monitoring state | 查询指定任务状态的监控 - * @param status 任务状态 - * @return Monitor the list | 监控列表 - */ - List findMonitorsByStatusIn(List status); - /** - * Query the monitoring status of a specified monitoring state | 查询指定任务状态的监控 - * @param status 任务状态 - * @return Monitor the list | 监控列表 + * Query the monitoring status of a specified monitoring state + * @param status status value + * @return Monitor the list */ List findMonitorsByStatus(Byte status); diff --git a/alerter/src/main/java/org/dromara/hertzbeat/alert/dao/AlertSilenceDao.java b/alerter/src/main/java/org/dromara/hertzbeat/alert/dao/AlertSilenceDao.java index a03abca403..cdd276bbe0 100644 --- a/alerter/src/main/java/org/dromara/hertzbeat/alert/dao/AlertSilenceDao.java +++ b/alerter/src/main/java/org/dromara/hertzbeat/alert/dao/AlertSilenceDao.java @@ -25,8 +25,7 @@ import org.springframework.data.jpa.repository.Modifying; import java.util.Set; /** - * AlertSilence 数据库操作 - * + * AlertSilence Dao * */ public interface AlertSilenceDao extends JpaRepository, JpaSpecificationExecutor { diff --git a/alerter/src/main/java/org/dromara/hertzbeat/alert/dto/AlertPriorityNum.java b/alerter/src/main/java/org/dromara/hertzbeat/alert/dto/AlertPriorityNum.java index 4a93653847..75a38fc93e 100644 --- a/alerter/src/main/java/org/dromara/hertzbeat/alert/dto/AlertPriorityNum.java +++ b/alerter/src/main/java/org/dromara/hertzbeat/alert/dto/AlertPriorityNum.java @@ -21,9 +21,7 @@ import lombok.AllArgsConstructor; import lombok.Data; /** - * Number of monitoring level alarms 监控级别告警数量 - * - * + * Number of monitoring level alarms * */ @Data @@ -31,12 +29,12 @@ import lombok.Data; public class AlertPriorityNum { /** - * Alarm level 告警级别 + * Alarm level */ private byte priority; /** - * count 数量 + * Alarm count */ private long num; } diff --git a/alerter/src/main/java/org/dromara/hertzbeat/alert/dto/AlertSummary.java b/alerter/src/main/java/org/dromara/hertzbeat/alert/dto/AlertSummary.java index 7a16c698b8..a216b991b8 100644 --- a/alerter/src/main/java/org/dromara/hertzbeat/alert/dto/AlertSummary.java +++ b/alerter/src/main/java/org/dromara/hertzbeat/alert/dto/AlertSummary.java @@ -26,9 +26,7 @@ import static io.swagger.v3.oas.annotations.media.Schema.AccessMode.READ_ONLY; /** - * Alarm Statistics Information 告警统计信息 - * - * + * Alarm Statistics Information * */ @Data diff --git a/alerter/src/main/java/org/dromara/hertzbeat/alert/enums/CloudServiceAlarmInformationEnum.java b/alerter/src/main/java/org/dromara/hertzbeat/alert/enums/CloudServiceAlarmInformationEnum.java index aee631b095..3e3e7bcaf9 100644 --- a/alerter/src/main/java/org/dromara/hertzbeat/alert/enums/CloudServiceAlarmInformationEnum.java +++ b/alerter/src/main/java/org/dromara/hertzbeat/alert/enums/CloudServiceAlarmInformationEnum.java @@ -8,7 +8,7 @@ import org.dromara.hertzbeat.alert.dto.TenCloudAlertReport; import java.util.Arrays; /** - * 云服务告警枚举 + * Cloud server alarm enum */ @AllArgsConstructor @Getter @@ -17,12 +17,12 @@ public enum CloudServiceAlarmInformationEnum { TencentCloud("tencloud", TenCloudAlertReport.class); /** - * 云服务名称 + * cloud service name */ private final String cloudServiceName; /** - * 云服务对应的请求实体 + * cloud service body */ private final Class cloudServiceAlarmInformationEntity; diff --git a/alerter/src/main/java/org/dromara/hertzbeat/alert/reduce/AlarmCommonReduce.java b/alerter/src/main/java/org/dromara/hertzbeat/alert/reduce/AlarmCommonReduce.java index a6012e099f..070861f112 100644 --- a/alerter/src/main/java/org/dromara/hertzbeat/alert/reduce/AlarmCommonReduce.java +++ b/alerter/src/main/java/org/dromara/hertzbeat/alert/reduce/AlarmCommonReduce.java @@ -16,7 +16,6 @@ import java.util.Map; /** * reduce alarm and send alert data * - * */ @Service @RequiredArgsConstructor diff --git a/alerter/src/main/java/org/dromara/hertzbeat/alert/reduce/AlarmConvergeReduce.java b/alerter/src/main/java/org/dromara/hertzbeat/alert/reduce/AlarmConvergeReduce.java index 40a38f8eae..4f5d83d044 100644 --- a/alerter/src/main/java/org/dromara/hertzbeat/alert/reduce/AlarmConvergeReduce.java +++ b/alerter/src/main/java/org/dromara/hertzbeat/alert/reduce/AlarmConvergeReduce.java @@ -16,24 +16,25 @@ import java.util.Objects; import java.util.concurrent.ConcurrentHashMap; /** - * alarm converge - * 告警收敛 + * alarm converge + * * */ @Service public class AlarmConvergeReduce { - + private final AlertConvergeDao alertConvergeDao; - + private final Map converageAlertMap; - + public AlarmConvergeReduce(AlertConvergeDao alertConvergeDao) { this.alertConvergeDao = alertConvergeDao; this.converageAlertMap = new ConcurrentHashMap<>(16); } - + /** * currentAlert converge filter data + * * @param currentAlert currentAlert * @return true when not filter */ @@ -109,9 +110,9 @@ public class AlarmConvergeReduce { if (evalInterval <= 0) { return true; } - int alertHash = Objects.hash(currentAlert.getPriority()) - + Arrays.hashCode(currentAlert.getTags().keySet().toArray(new String[0])) - + Arrays.hashCode(currentAlert.getTags().values().toArray(new String[0])); + int alertHash = Objects.hash(currentAlert.getPriority()) + + Arrays.hashCode(currentAlert.getTags().keySet().toArray(new String[0])) + + Arrays.hashCode(currentAlert.getTags().values().toArray(new String[0])); Alert preAlert = converageAlertMap.get(alertHash); if (preAlert == null) { currentAlert.setTimes(1); diff --git a/alerter/src/main/java/org/dromara/hertzbeat/alert/reduce/AlarmSilenceReduce.java b/alerter/src/main/java/org/dromara/hertzbeat/alert/reduce/AlarmSilenceReduce.java index 949d14274b..828e54354e 100644 --- a/alerter/src/main/java/org/dromara/hertzbeat/alert/reduce/AlarmSilenceReduce.java +++ b/alerter/src/main/java/org/dromara/hertzbeat/alert/reduce/AlarmSilenceReduce.java @@ -19,7 +19,6 @@ import java.util.Optional; /** * silence alarm * - * */ @Service @RequiredArgsConstructor diff --git a/alerter/src/main/java/org/dromara/hertzbeat/alert/service/AlertConvergeService.java b/alerter/src/main/java/org/dromara/hertzbeat/alert/service/AlertConvergeService.java index 360f3c4bbd..458c3435bb 100644 --- a/alerter/src/main/java/org/dromara/hertzbeat/alert/service/AlertConvergeService.java +++ b/alerter/src/main/java/org/dromara/hertzbeat/alert/service/AlertConvergeService.java @@ -10,29 +10,27 @@ import java.util.Set; /** * management interface service for alert converge * - * */ public interface AlertConvergeService { /** * Verify the correctness of the request data parameters - * 校验请求数据参数正确性 * @param alertConverge AlertConverge - * @param isModify 是否是修改配置 - * @throws IllegalArgumentException A checksum parameter error is thrown | 校验参数错误抛出 + * @param isModify whether modify + * @throws IllegalArgumentException A checksum parameter error is thrown */ void validate(AlertConverge alertConverge, boolean isModify) throws IllegalArgumentException; /** * New AlertConverge - * @param alertConverge AlertConverge Entity | 收敛策略实体 - * @throws RuntimeException Added procedure exception throwing | 新增过程异常抛出 + * @param alertConverge AlertConverge Entity + * @throws RuntimeException Added procedure exception throwing */ void addAlertConverge(AlertConverge alertConverge) throws RuntimeException; /** - * Modifying an AlertConverge | 修改收敛策略 - * @param alertConverge Alarm definition Entity | 收敛策略实体 - * @throws RuntimeException Exception thrown during modification | 修改过程中异常抛出 + * Modifying an AlertConverge + * @param alertConverge Alarm definition Entity + * @throws RuntimeException Exception thrown during modification */ void modifyAlertConverge(AlertConverge alertConverge) throws RuntimeException; @@ -40,24 +38,23 @@ public interface AlertConvergeService { * Obtain AlertConverge information * @param convergeId AlertConverge ID * @return AlertConverge - * @throws RuntimeException An exception was thrown during the query | 查询过程中异常抛出 + * @throws RuntimeException An exception was thrown during the query */ AlertConverge getAlertConverge(long convergeId) throws RuntimeException; /** - * Delete AlertConverge in batches | 批量删除收敛策略 - * @param convergeIds AlertConverge IDs | 收敛策略IDs - * @throws RuntimeException Exception thrown during deletion | 删除过程中异常抛出 + * Delete AlertConverge in batches + * @param convergeIds AlertConverge IDs + * @throws RuntimeException Exception thrown during deletion */ void deleteAlertConverges(Set convergeIds) throws RuntimeException; /** * Dynamic conditional query - * 动态条件查询 - * @param specification Query conditions | 查询条件 - * @param pageRequest Paging parameters | 分页参数 - * @return The query results | 查询结果 + * @param specification Query conditions + * @param pageRequest Paging parameters + * @return The query results */ Page getAlertConverges(Specification specification, PageRequest pageRequest); } diff --git a/alerter/src/main/java/org/dromara/hertzbeat/alert/service/AlertDefineService.java b/alerter/src/main/java/org/dromara/hertzbeat/alert/service/AlertDefineService.java index 8485fb0878..1b65cbb8ad 100644 --- a/alerter/src/main/java/org/dromara/hertzbeat/alert/service/AlertDefineService.java +++ b/alerter/src/main/java/org/dromara/hertzbeat/alert/service/AlertDefineService.java @@ -28,110 +28,104 @@ import java.util.Map; import java.util.Set; /** - * 告警定义管理接口 - * + * Alarm define manager service * */ public interface AlertDefineService { /** * Verify the correctness of the request data parameters - * 校验请求数据参数正确性 * @param alertDefine alertDefine - * @param isModify 是否是修改配置 - * @throws IllegalArgumentException A checksum parameter error is thrown | 校验参数错误抛出 + * @param isModify whether modify + * @throws IllegalArgumentException A checksum parameter error is thrown */ void validate(AlertDefine alertDefine, boolean isModify) throws IllegalArgumentException; /** * New Alarm Definition - * 新增告警定义 - * @param alertDefine Alarm definition Entity | 告警定义实体 - * @throws RuntimeException Added procedure exception throwing | 新增过程异常抛出 + * @param alertDefine Alarm definition Entity + * @throws RuntimeException Added procedure exception throwing */ void addAlertDefine(AlertDefine alertDefine) throws RuntimeException; /** - * Modifying an Alarm Definition | 修改告警定义 - * @param alertDefine Alarm definition Entity | 告警定义实体 - * @throws RuntimeException Exception thrown during modification | 修改过程中异常抛出 + * Modifying an Alarm Definition + * @param alertDefine Alarm definition Entity + * @throws RuntimeException Exception thrown during modification */ void modifyAlertDefine(AlertDefine alertDefine) throws RuntimeException; /** * Deleting an Alarm Definition - * 删除告警定义 - * @param alertId Alarm Definition ID | 告警定义ID - * @throws RuntimeException Exception thrown during deletion | 删除过程中异常抛出 + * @param alertId Alarm Definition ID + * @throws RuntimeException Exception thrown during deletion */ void deleteAlertDefine(long alertId) throws RuntimeException; /** * Obtain alarm definition information - * 获取告警定义信息 - * @param alertId Monitor the ID | 监控任务ID + * @param alertId Monitor the ID * @return AlertDefine - * @throws RuntimeException An exception was thrown during the query | 查询过程中异常抛出 + * @throws RuntimeException An exception was thrown during the query */ AlertDefine getAlertDefine(long alertId) throws RuntimeException; /** - * Delete alarm definitions in batches | 批量删除告警定义 - * @param alertIds Alarm Definition IDs | 告警定义IDs - * @throws RuntimeException Exception thrown during deletion | 删除过程中异常抛出 + * Delete alarm definitions in batches + * @param alertIds Alarm Definition IDs + * @throws RuntimeException Exception thrown during deletion */ void deleteAlertDefines(Set alertIds) throws RuntimeException; /** - * Dynamic conditional query | 动态条件查询 - * @param specification Query conditions | 查询条件 - * @param pageRequest Paging parameters | 分页参数 - * @return The query results | 查询结果 + * Dynamic conditional query + * @param specification Query conditions + * @param pageRequest Paging parameters + * @return The query results */ Page getMonitorBindAlertDefines(Specification specification, PageRequest pageRequest); /** - * Association between application alarm schedule and monitoring |应用告警定于与监控关联关系 - * @param alertId Alarm Definition ID | 告警定义ID - * @param alertDefineBinds correlation | 关联关系 + * Association between application alarm schedule and monitoring + * @param alertId Alarm Definition ID + * @param alertDefineBinds correlation */ void applyBindAlertDefineMonitors(Long alertId, List alertDefineBinds); /** - * Query the alarm definitions that match the specified indicator group associated with the monitoring ID - * 查询与此监控任务ID关联的指定指标组匹配的告警定义 - * @param monitorId Monitor the ID | 监控任务ID - * @param app Monitoring type | 监控类型 - * @param metrics Index group | 指标组 + * Query the alarm definitions that match the specified metrics associated with the monitoring ID + * 查询与此监控任务ID关联的指定指标匹配的告警定义 + * @param monitorId Monitor the ID + * @param app Monitoring type + * @param metrics metrics * @return field - define[] */ Map> getMonitorBindAlertDefines(long monitorId, String app, String metrics); /** - * Query the alarm definitions that match the specified indicator group associated with the monitoring ID + * Query the alarm definitions that match the specified metrics associated with the monitoring ID * 查询与此监控任务ID关联的可用性告警定义 - * @param monitorId Monitor the ID | 监控任务ID - * @param app Monitoring type | 监控类型 - * @param metrics Index group | 指标组 + * @param monitorId Monitor the ID + * @param app Monitoring type + * @param metrics metrics * @return field - define[] */ AlertDefine getMonitorBindAlertAvaDefine(long monitorId, String app, String metrics); /** * Dynamic conditional query - * 动态条件查询 - * @param specification Query conditions | 查询条件 - * @param pageRequest Paging parameters | 分页参数 - * @return The query results | 查询结果 + * @param specification Query conditions + * @param pageRequest Paging parameters + * @return The query results */ Page getAlertDefines(Specification specification, PageRequest pageRequest); /** * Query the associated monitoring list information based on the alarm definition ID * 根据告警定义ID查询其关联的监控列表关联信息 - * @param alertDefineId Alarm Definition ID | 告警定义ID - * @return Associated information about the monitoring list | 监控列表关联信息 + * @param alertDefineId Alarm Definition ID + * @return Associated information about the monitoring list */ List getBindAlertDefineMonitors(long alertDefineId); } diff --git a/alerter/src/main/java/org/dromara/hertzbeat/alert/service/AlertService.java b/alerter/src/main/java/org/dromara/hertzbeat/alert/service/AlertService.java index 4287a8dd15..0fe77ddbee 100644 --- a/alerter/src/main/java/org/dromara/hertzbeat/alert/service/AlertService.java +++ b/alerter/src/main/java/org/dromara/hertzbeat/alert/service/AlertService.java @@ -29,76 +29,61 @@ import java.util.List; /** * Alarm information management interface - * 告警信息管理接口 - * - * * */ public interface AlertService { /** * Add alarm record - * 新增告警记录 - * - * @param alert Alert entity 告警实体 - * @throws RuntimeException Add process exception throw 新增过程异常抛出 + * @param alert Alert entity + * @throws RuntimeException Add process exception throw */ void addAlert(Alert alert) throws RuntimeException; /** * Dynamic conditional query - * 动态条件查询 - * - * @param specification Query conditions 查询条件 - * @param pageRequest pagination parameters 分页参数 - * @return search result 查询结果 + * @param specification Query conditions + * @param pageRequest pagination parameters + * @return search result */ Page getAlerts(Specification specification, PageRequest pageRequest); /** * Delete alarms in batches according to the alarm ID list * 根据告警ID列表批量删除告警 - * - * @param ids Alarm ID List 告警IDS + * @param ids Alarm ID List */ void deleteAlerts(HashSet ids); /** * Clear all alerts - * 清空所有告警记录 */ void clearAlerts(); /** * Update the alarm status according to the alarm ID-status value * 根据告警ID-状态值 更新告警状态 - * - * @param status Alarm status to be modified 待修改为的告警状态 - * @param ids Alarm ID List to be modified 待修改的告警ID集合 + * @param status Alarm status to be modified + * @param ids Alarm ID List to be modified */ void editAlertStatus(Byte status, List ids); /** - * Get alarm statistics information 获取告警统计信息 - * - * @return Alarm statistics information 告警统计 + * Get alarm statistics information + * @return Alarm statistics information */ AlertSummary getAlertsSummary(); /** - * A third party reports an alarm 第三方 上报告警信息 - * @param alertReport The alarm information 告警信息 + * A third party reports an alarm + * @param alertReport The alarm information */ void addNewAlertReport(AlertReport alertReport); /** * Dynamic conditional query - * 动态条件查询 - * - * @param specification Query conditions 查询条件 - * @return search result 查询结果 + * @param specification Query conditions + * @return search result */ List getAlerts(Specification specification); - - } diff --git a/alerter/src/main/java/org/dromara/hertzbeat/alert/service/AlertSilenceService.java b/alerter/src/main/java/org/dromara/hertzbeat/alert/service/AlertSilenceService.java index 07c6dfebb8..b94ff18529 100644 --- a/alerter/src/main/java/org/dromara/hertzbeat/alert/service/AlertSilenceService.java +++ b/alerter/src/main/java/org/dromara/hertzbeat/alert/service/AlertSilenceService.java @@ -10,29 +10,27 @@ import java.util.Set; /** * management interface service for alert silence * - * */ public interface AlertSilenceService { /** * Verify the correctness of the request data parameters - * 校验请求数据参数正确性 * @param alertSilence AlertSilence - * @param isModify 是否是修改配置 - * @throws IllegalArgumentException A checksum parameter error is thrown | 校验参数错误抛出 + * @param isModify whether modify + * @throws IllegalArgumentException A checksum parameter error is thrown */ void validate(AlertSilence alertSilence, boolean isModify) throws IllegalArgumentException; /** * New AlertSilence - * @param alertSilence AlertSilence Entity | 静默策略实体 - * @throws RuntimeException Added procedure exception throwing | 新增过程异常抛出 + * @param alertSilence AlertSilence Entity + * @throws RuntimeException Added procedure exception throwing */ void addAlertSilence(AlertSilence alertSilence) throws RuntimeException; /** - * Modifying an AlertSilence | 修改静默策略 - * @param alertSilence Alarm definition Entity | 静默策略实体 - * @throws RuntimeException Exception thrown during modification | 修改过程中异常抛出 + * Modifying an AlertSilence + * @param alertSilence Alarm definition Entity + * @throws RuntimeException Exception thrown during modification */ void modifyAlertSilence(AlertSilence alertSilence) throws RuntimeException; @@ -40,24 +38,23 @@ public interface AlertSilenceService { * Obtain AlertSilence information * @param silenceId AlertSilence ID * @return AlertSilence - * @throws RuntimeException An exception was thrown during the query | 查询过程中异常抛出 + * @throws RuntimeException An exception was thrown during the query */ AlertSilence getAlertSilence(long silenceId) throws RuntimeException; /** - * Delete AlertSilence in batches | 批量删除静默策略 - * @param silenceIds AlertSilence IDs | 静默策略IDs - * @throws RuntimeException Exception thrown during deletion | 删除过程中异常抛出 + * Delete AlertSilence in batches + * @param silenceIds AlertSilence IDs + * @throws RuntimeException Exception thrown during deletion */ void deleteAlertSilences(Set silenceIds) throws RuntimeException; /** * Dynamic conditional query - * 动态条件查询 - * @param specification Query conditions | 查询条件 - * @param pageRequest Paging parameters | 分页参数 - * @return The query results | 查询结果 + * @param specification Query conditions + * @param pageRequest Paging parameters + * @return The query results */ Page getAlertSilences(Specification specification, PageRequest pageRequest); } diff --git a/alerter/src/main/java/org/dromara/hertzbeat/alert/service/impl/AlertConvergeServiceImpl.java b/alerter/src/main/java/org/dromara/hertzbeat/alert/service/impl/AlertConvergeServiceImpl.java index 77d900468d..fd295995b0 100644 --- a/alerter/src/main/java/org/dromara/hertzbeat/alert/service/impl/AlertConvergeServiceImpl.java +++ b/alerter/src/main/java/org/dromara/hertzbeat/alert/service/impl/AlertConvergeServiceImpl.java @@ -19,7 +19,6 @@ import java.util.Set; /** * implement for alert converge service * - * */ @Service @Transactional(rollbackFor = Exception.class) diff --git a/alerter/src/main/java/org/dromara/hertzbeat/alert/service/impl/AlertDefineServiceImpl.java b/alerter/src/main/java/org/dromara/hertzbeat/alert/service/impl/AlertDefineServiceImpl.java index f38f94467f..4298e06cf3 100644 --- a/alerter/src/main/java/org/dromara/hertzbeat/alert/service/impl/AlertDefineServiceImpl.java +++ b/alerter/src/main/java/org/dromara/hertzbeat/alert/service/impl/AlertDefineServiceImpl.java @@ -37,8 +37,6 @@ import java.util.stream.Collectors; /** * Alarm definition management interface implementation - * 告警定义管理接口实现 - * * */ @Service @@ -101,10 +99,8 @@ public class AlertDefineServiceImpl implements AlertDefineService { // todo 校验此告警定义和监控是否存在 // Delete all associations of this alarm - // 先删除此告警的所有关联 alertDefineBindDao.deleteAlertDefineBindsByAlertDefineIdEquals(alertId); // Save the associated - // 保存关联 alertDefineBindDao.saveAll(alertDefineBinds); } diff --git a/alerter/src/main/java/org/dromara/hertzbeat/alert/service/impl/AlertServiceImpl.java b/alerter/src/main/java/org/dromara/hertzbeat/alert/service/impl/AlertServiceImpl.java index 8639e2b7da..1e215d83a5 100644 --- a/alerter/src/main/java/org/dromara/hertzbeat/alert/service/impl/AlertServiceImpl.java +++ b/alerter/src/main/java/org/dromara/hertzbeat/alert/service/impl/AlertServiceImpl.java @@ -43,9 +43,7 @@ import java.util.List; import java.util.Map; /** - * Realization of Alarm Information Service 告警信息服务实现 - * - * + * Realization of Alarm Information Service * */ @Service @@ -87,8 +85,7 @@ public class AlertServiceImpl implements AlertService { @Override public AlertSummary getAlertsSummary() { AlertSummary alertSummary = new AlertSummary(); - //Statistics on the alarm information in the alarm state - //统计正在告警状态下的告警信息 + // Statistics on the alarm information in the alarm state List priorityNums = alertDao.findAlertPriorityNum(); if (priorityNums != null) { for (AlertPriorityNum priorityNum : priorityNums) { @@ -140,9 +137,9 @@ public class AlertServiceImpl implements AlertService { } /** - * The external alarm information is converted to Alert 对外告警信息 转换为Alert - * @param alertReport 对外告警信息 - * @return Alert entity | Alert实体 + * The external alarm information is converted to Alert + * @param alertReport alarm body + * @return Alert entity */ private Alert buildAlertData(AlertReport alertReport){ Map annotations = alertReport.getAnnotations(); diff --git a/alerter/src/main/java/org/dromara/hertzbeat/alert/service/impl/AlertSilenceServiceImpl.java b/alerter/src/main/java/org/dromara/hertzbeat/alert/service/impl/AlertSilenceServiceImpl.java index 29b1c97df2..4637c78c92 100644 --- a/alerter/src/main/java/org/dromara/hertzbeat/alert/service/impl/AlertSilenceServiceImpl.java +++ b/alerter/src/main/java/org/dromara/hertzbeat/alert/service/impl/AlertSilenceServiceImpl.java @@ -20,7 +20,6 @@ import java.util.Set; /** * management interface service implement for alert silence * - * */ @Service @Transactional(rollbackFor = Exception.class) diff --git a/alerter/src/main/java/org/dromara/hertzbeat/alert/util/AlertTemplateUtil.java b/alerter/src/main/java/org/dromara/hertzbeat/alert/util/AlertTemplateUtil.java index bb5ac4db7c..76b9560be7 100644 --- a/alerter/src/main/java/org/dromara/hertzbeat/alert/util/AlertTemplateUtil.java +++ b/alerter/src/main/java/org/dromara/hertzbeat/alert/util/AlertTemplateUtil.java @@ -27,7 +27,6 @@ import java.util.regex.Pattern; * Alarm template keyword matching replacement engine tool * 告警模版关键字匹配替换引擎工具 * - * */ @Slf4j public class AlertTemplateUtil { diff --git a/alerter/src/main/java/org/dromara/hertzbeat/alert/util/DateUtil.java b/alerter/src/main/java/org/dromara/hertzbeat/alert/util/DateUtil.java index 7d49206d3a..02dc53b043 100644 --- a/alerter/src/main/java/org/dromara/hertzbeat/alert/util/DateUtil.java +++ b/alerter/src/main/java/org/dromara/hertzbeat/alert/util/DateUtil.java @@ -1,11 +1,14 @@ package org.dromara.hertzbeat.alert.util; +import lombok.extern.slf4j.Slf4j; + import java.text.ParseException; import java.text.SimpleDateFormat; /** - * 记录一些常用的日期格式 + * date time common util */ +@Slf4j public class DateUtil { private static final String[] DATE_FORMATS = { @@ -13,7 +16,8 @@ public class DateUtil { "yyyy-MM-dd HH:mm:ss"}; /** - * 常用日期格式转时间戳 + * convert date to timestamp + * @param date date */ public static Long getTimeStampFromSomeFormats(String date) { SimpleDateFormat sdf; @@ -21,21 +25,24 @@ public class DateUtil { try { sdf = new SimpleDateFormat(dateFormat); return sdf.parse(date).getTime(); - } catch (ParseException e) {} + } catch (ParseException e) { + log.error(e.getMessage()); + } } return null; } /** - * 指定日期格式转换时间戳 + * convert format data to timestamp */ public static Long getTimeStampFromFormat(String date, String format) { SimpleDateFormat sdf = new SimpleDateFormat(format); try { return sdf.parse(date).getTime(); } catch (Exception e) { - throw new RuntimeException("时间格式解析异常!"); + log.error(e.getMessage()); } + return null; } } diff --git a/collector/src/main/java/org/dromara/hertzbeat/collector/collect/AbstractCollect.java b/collector/src/main/java/org/dromara/hertzbeat/collector/collect/AbstractCollect.java index 483c28c0db..63f3df08cf 100644 --- a/collector/src/main/java/org/dromara/hertzbeat/collector/collect/AbstractCollect.java +++ b/collector/src/main/java/org/dromara/hertzbeat/collector/collect/AbstractCollect.java @@ -22,23 +22,19 @@ import org.dromara.hertzbeat.common.entity.job.Metrics; import org.dromara.hertzbeat.common.entity.message.CollectRep; /** - * Specific metrics group collection implementation abstract class - * - * + * Specific metrics collection implementation abstract class * */ public abstract class AbstractCollect { /** * Real acquisition implementation interface - * * @param builder response builder - * @param appId App monitoring ID - * @param app Application Type - * @param metrics Metric group configuration - * return response builder + * @param monitorId monitor id + * @param app monitor type + * @param metrics metric configuration */ - public abstract void collect(CollectRep.MetricsData.Builder builder, long appId, String app, Metrics metrics); + public abstract void collect(CollectRep.MetricsData.Builder builder, long monitorId, String app, Metrics metrics); /** * the protocol this collect instance support diff --git a/collector/src/main/java/org/dromara/hertzbeat/collector/collect/common/cache/CacheCloseable.java b/collector/src/main/java/org/dromara/hertzbeat/collector/collect/common/cache/CacheCloseable.java index 082d32d5d8..d51d53d00a 100644 --- a/collector/src/main/java/org/dromara/hertzbeat/collector/collect/common/cache/CacheCloseable.java +++ b/collector/src/main/java/org/dromara/hertzbeat/collector/collect/common/cache/CacheCloseable.java @@ -18,14 +18,13 @@ package org.dromara.hertzbeat.collector.collect.common.cache; /** - * 连接资源关闭回调接口 - * + * resource in cache remove callback * */ public interface CacheCloseable { /** - * 在缓存remove掉此对象前,回调接口对连接对象进行相关资源的释放 + * when the resource in cache want to be removed, callback this */ void close(); } diff --git a/collector/src/main/java/org/dromara/hertzbeat/collector/collect/common/cache/CacheIdentifier.java b/collector/src/main/java/org/dromara/hertzbeat/collector/collect/common/cache/CacheIdentifier.java index 9d34547aab..fa192388d0 100644 --- a/collector/src/main/java/org/dromara/hertzbeat/collector/collect/common/cache/CacheIdentifier.java +++ b/collector/src/main/java/org/dromara/hertzbeat/collector/collect/common/cache/CacheIdentifier.java @@ -23,8 +23,7 @@ import lombok.Data; import java.util.Objects; /** - * 缓存key唯一标识符 - * + * resource identifier in cache * */ @Data diff --git a/collector/src/main/java/org/dromara/hertzbeat/collector/collect/common/cache/CommonCache.java b/collector/src/main/java/org/dromara/hertzbeat/collector/collect/common/cache/CommonCache.java index 5ca8f31151..e61c1481ce 100644 --- a/collector/src/main/java/org/dromara/hertzbeat/collector/collect/common/cache/CommonCache.java +++ b/collector/src/main/java/org/dromara/hertzbeat/collector/collect/common/cache/CommonCache.java @@ -30,50 +30,45 @@ import java.util.concurrent.ThreadPoolExecutor; import java.util.concurrent.TimeUnit; /** - * lru cache 对连接对象进行缓存 - * + * lru common resource cache * */ @Slf4j public class CommonCache { /** - * 默认缓存时间 800s + * default cache time 800s */ private static final long DEFAULT_CACHE_TIMEOUT = 800 * 1000L; /** - * 默认最大缓存数量 + * default cache num */ private static final int DEFAULT_MAX_CAPACITY = 10000; /** - * cacheTime数组大小 + * cacheTime length */ private static final int CACHE_TIME_LENGTH = 2; /** - * 存储对象的数据过期时间点 + * cache timeout map */ private Map timeoutMap; /** - * 存储缓存对象 + * object cache */ private ConcurrentLinkedHashMap cacheMap; /** - * 过期数据清理线程池 + * the executor who clean cache when timeout */ private ThreadPoolExecutor cleanTimeoutExecutor; private CommonCache() { init();} - - /** - * 初始化 cache - */ + private void init() { - // 初始化lru hashmap cacheMap = new ConcurrentLinkedHashMap .Builder<>() .maximumWeightedCapacity(DEFAULT_MAX_CAPACITY) @@ -84,17 +79,12 @@ public class CommonCache { } log.info("lru cache discard key: {}, value: {}.", key, value); }).build(); - - // 初始化时间纪录map timeoutMap = new ConcurrentHashMap<>(DEFAULT_MAX_CAPACITY >> 6); - - // 初始化过期数据清理线程池 cleanTimeoutExecutor = new ThreadPoolExecutor(1, 1, 1, TimeUnit.SECONDS, new ArrayBlockingQueue<>(1), r -> new Thread("lru-cache-timeout-cleaner"), new ThreadPoolExecutor.DiscardOldestPolicy()); - - // 初始化可用性探测定位任务,每次探测间隔时间为20分钟 + // init monitor available detector cyc task ScheduledThreadPoolExecutor scheduledExecutor = new ScheduledThreadPoolExecutor(1, r -> new Thread(r, "lru-cache-available-detector")); scheduledExecutor.scheduleWithFixedDelay(this::detectCacheAvailable, @@ -102,12 +92,11 @@ public class CommonCache { } /** - * 探测所有可探测的缓存对象的可用性,清除不可用和过期对象 + * detect all cache available, cleanup not ava object */ private void detectCacheAvailable() { try { cacheMap.forEach((key, value) -> { - // 先判断是否过期 Long[] cacheTime = timeoutMap.get(key); long currentTime = System.currentTimeMillis(); if (cacheTime == null || cacheTime.length != CACHE_TIME_LENGTH @@ -126,7 +115,7 @@ public class CommonCache { } /** - * 清理过期线程 + * clean timeout cache */ private void cleanTimeoutCache() { try { @@ -137,7 +126,7 @@ public class CommonCache { if (cacheTime == null || cacheTime.length != CACHE_TIME_LENGTH) { timeoutMap.put(key, new Long[]{currentTime, DEFAULT_CACHE_TIMEOUT}); } else if (cacheTime[0] + cacheTime[1] < currentTime) { - // 过期了 discard 关闭这个cache的资源 + // timeout, remove this object cache log.warn("[cache] clean the timeout cache, key {}", key); timeoutMap.remove(key); cacheMap.remove(key); @@ -153,10 +142,10 @@ public class CommonCache { } /** - * 新增或更新cache - * @param key 存储对象key - * @param value 存储对象 - * @param timeDiff 缓存对象保存时间 millis + * add update cache + * @param key cache key + * @param value cache value + * @param timeDiff cache time millis */ public void addCache(Object key, Object value, Long timeDiff) { removeCache(key); @@ -176,19 +165,19 @@ public class CommonCache { } /** - * 新增或更新cache - * @param key 存储对象key - * @param value 存储对象 + * add update cache + * @param key cache key + * @param value cache value */ public void addCache(Object key, Object value) { addCache(key, value, DEFAULT_CACHE_TIMEOUT); } /** - * 根据缓存key获取缓存对象 - * @param key key - * @param refreshCache 是否刷新命中的缓存的存活时间 true是,false否 - * @return 缓存对象 + * get cache by key + * @param key cache key + * @param refreshCache is refresh cache + * @return cache object */ public Optional getCache(Object key, boolean refreshCache) { Long[] cacheTime = timeoutMap.get(key); @@ -215,7 +204,7 @@ public class CommonCache { } /** - * 根据缓存key删除缓存对象 + * remove cache by key * @param key key */ public void removeCache(Object key) { @@ -227,7 +216,7 @@ public class CommonCache { } /** - * 获取缓存实例 + * get common cache instance * @return cache */ public static CommonCache getInstance() { @@ -235,12 +224,9 @@ public class CommonCache { } /** - * 静态内部类 + * static instance */ private static class SingleInstance { - /** - * 单例 - */ private static final CommonCache INSTANCE= new CommonCache(); } } diff --git a/collector/src/main/java/org/dromara/hertzbeat/collector/collect/common/cache/JdbcConnect.java b/collector/src/main/java/org/dromara/hertzbeat/collector/collect/common/cache/JdbcConnect.java index a2bcf6b5c7..b8fab31e21 100644 --- a/collector/src/main/java/org/dromara/hertzbeat/collector/collect/common/cache/JdbcConnect.java +++ b/collector/src/main/java/org/dromara/hertzbeat/collector/collect/common/cache/JdbcConnect.java @@ -24,7 +24,6 @@ import java.sql.Connection; /** * jdbc common connection * - * */ @Slf4j public class JdbcConnect implements CacheCloseable { diff --git a/collector/src/main/java/org/dromara/hertzbeat/collector/collect/common/cache/JmxConnect.java b/collector/src/main/java/org/dromara/hertzbeat/collector/collect/common/cache/JmxConnect.java index 2a6ae9af19..0e3aed3f87 100644 --- a/collector/src/main/java/org/dromara/hertzbeat/collector/collect/common/cache/JmxConnect.java +++ b/collector/src/main/java/org/dromara/hertzbeat/collector/collect/common/cache/JmxConnect.java @@ -5,9 +5,7 @@ import lombok.extern.slf4j.Slf4j; import javax.management.remote.JMXConnector; /** - * jmx链接销毁管理 - * - * + * jmx connect object * **/ @Slf4j diff --git a/collector/src/main/java/org/dromara/hertzbeat/collector/collect/common/cache/MongodbConnect.java b/collector/src/main/java/org/dromara/hertzbeat/collector/collect/common/cache/MongodbConnect.java index a55eb8ac51..f662fe6884 100644 --- a/collector/src/main/java/org/dromara/hertzbeat/collector/collect/common/cache/MongodbConnect.java +++ b/collector/src/main/java/org/dromara/hertzbeat/collector/collect/common/cache/MongodbConnect.java @@ -6,8 +6,6 @@ import lombok.extern.slf4j.Slf4j; /** * mongodb connect client * - * - * */ @Slf4j public class MongodbConnect implements CacheCloseable { diff --git a/collector/src/main/java/org/dromara/hertzbeat/collector/collect/common/cache/RedisConnect.java b/collector/src/main/java/org/dromara/hertzbeat/collector/collect/common/cache/RedisConnect.java index 7eae3c30a0..a6b9e2907d 100644 --- a/collector/src/main/java/org/dromara/hertzbeat/collector/collect/common/cache/RedisConnect.java +++ b/collector/src/main/java/org/dromara/hertzbeat/collector/collect/common/cache/RedisConnect.java @@ -23,8 +23,6 @@ import lombok.extern.slf4j.Slf4j; /** * redis connection * - * - * */ @Slf4j public class RedisConnect implements CacheCloseable { diff --git a/collector/src/main/java/org/dromara/hertzbeat/collector/collect/common/cache/SshConnect.java b/collector/src/main/java/org/dromara/hertzbeat/collector/collect/common/cache/SshConnect.java index 66123cf7a3..a10c2fca5b 100644 --- a/collector/src/main/java/org/dromara/hertzbeat/collector/collect/common/cache/SshConnect.java +++ b/collector/src/main/java/org/dromara/hertzbeat/collector/collect/common/cache/SshConnect.java @@ -6,8 +6,6 @@ import org.apache.sshd.client.session.ClientSession; /** * ssh connection holder * - * - * */ @Slf4j public class SshConnect implements CacheCloseable { diff --git a/collector/src/main/java/org/dromara/hertzbeat/collector/collect/common/http/CommonHttpClient.java b/collector/src/main/java/org/dromara/hertzbeat/collector/collect/common/http/CommonHttpClient.java index 55bdf8f2c4..6ca6e723a3 100644 --- a/collector/src/main/java/org/dromara/hertzbeat/collector/collect/common/http/CommonHttpClient.java +++ b/collector/src/main/java/org/dromara/hertzbeat/collector/collect/common/http/CommonHttpClient.java @@ -40,8 +40,7 @@ import java.util.Date; import java.util.concurrent.TimeUnit; /** - * 统一的http客户端连接池 - * + * common http client * */ @Slf4j @@ -52,50 +51,51 @@ public class CommonHttpClient { private static PoolingHttpClientConnectionManager connectionManager; /** - * 此连接池所能提供的最大连接数 + * all max total connection */ private static final int MAX_TOTAL_CONNECTIONS = 50000; /** - * 每个路由所能分配的最大连接数 + * peer route max total connection */ private static final int MAX_PER_ROUTE_CONNECTIONS = 80; /** - * 从连接池中获取连接的默认超时时间 4秒 + * timeout for get connect from pool(ms) */ private static final int REQUIRE_CONNECT_TIMEOUT = 4000; /** - * 双端建立连接超时时间 4秒 + * tcp connect timeout(ms) */ private static final int CONNECT_TIMEOUT = 4000; /** - * socketReadTimeout 响应tcp报文的最大间隔超时时间 + * socket read timeout(ms) */ private static final int SOCKET_TIMEOUT = 60000; /** + * validated time for idle connection * 空闲连接免检的有效时间,被重用的空闲连接若超过此时间,需检查此连接的可用性 */ private static final int INACTIVITY_VALIDATED_TIME = 10000; /** - * ssl版本 + * ssl supported version */ private static final String[] SUPPORTED_SSL = {"TLSv1","TLSv1.1","TLSv1.2","SSLv3"}; static { try { - // 初始化ssl上下文 SSLContext sslContext = SSLContexts.createDefault(); X509TrustManager x509TrustManager = new X509TrustManager() { @Override public void checkClientTrusted(X509Certificate[] x509Certificates, String s) throws CertificateException { } @Override public void checkServerTrusted(X509Certificate[] x509Certificates, String s) throws CertificateException { - // 判断服务器证书有效期时间 + // check server certificate timeout + // 判断服务器证书有效时间 Date now = new Date(); if (x509Certificates != null && x509Certificates.length > 0) { for (X509Certificate certificate : x509Certificates) { @@ -110,30 +110,23 @@ public class CommonHttpClient { public X509Certificate[] getAcceptedIssuers() { return null; } }; sslContext.init(null, new TrustManager[]{x509TrustManager}, null); - // 设置支持的ssl版本 SSLConnectionSocketFactory sslFactory = new SSLConnectionSocketFactory(sslContext, SUPPORTED_SSL, null, new NoopHostnameVerifier()); - // 注册 http https Registry registry = RegistryBuilder.create() .register("http", PlainConnectionSocketFactory.INSTANCE) .register("https", sslFactory) .build(); - // 网络请求默认配置 RequestConfig requestConfig = RequestConfig.custom() - // 从连接池获取连接超时时间 .setConnectionRequestTimeout(REQUIRE_CONNECT_TIMEOUT) - // 和对端新连接建立时间,三次握手时间 .setConnectTimeout(CONNECT_TIMEOUT) - // 数据传输最大响应间隔时间 .setSocketTimeout(SOCKET_TIMEOUT) - // 遇到301 302自动重定向跳转 + // auto redirect when 301 302 response status .setRedirectsEnabled(true) .build(); - // 连接池 + // connection pool connectionManager = new PoolingHttpClientConnectionManager(registry); connectionManager.setMaxTotal(MAX_TOTAL_CONNECTIONS); connectionManager.setDefaultMaxPerRoute(MAX_PER_ROUTE_CONNECTIONS); connectionManager.setValidateAfterInactivity(INACTIVITY_VALIDATED_TIME); - // 构造单例 httpClient httpClient = HttpClients.custom() .setConnectionManager(connectionManager) .setDefaultRequestConfig(requestConfig) @@ -142,7 +135,6 @@ public class CommonHttpClient { // 定期清理可用但空闲的连接 .evictIdleConnections(100, TimeUnit.SECONDS) .build(); - // 构造连接清理器 Thread connectCleaner = new Thread(() -> { while (Thread.currentThread().isInterrupted()) { try { @@ -153,7 +145,7 @@ public class CommonHttpClient { } } }); - connectCleaner.setName("HttpConnectCleaner"); + connectCleaner.setName("http-connection-pool-cleaner"); connectCleaner.setDaemon(true); connectCleaner.start(); } catch (Exception e) { @@ -163,8 +155,4 @@ public class CommonHttpClient { public static CloseableHttpClient getHttpClient() { return httpClient; } - - public static PoolingHttpClientConnectionManager getConnectionManager() { - return connectionManager; - } } diff --git a/collector/src/main/java/org/dromara/hertzbeat/collector/collect/common/ssh/CommonSshClient.java b/collector/src/main/java/org/dromara/hertzbeat/collector/collect/common/ssh/CommonSshClient.java index a3cf9bdd92..855ff42662 100644 --- a/collector/src/main/java/org/dromara/hertzbeat/collector/collect/common/ssh/CommonSshClient.java +++ b/collector/src/main/java/org/dromara/hertzbeat/collector/collect/common/ssh/CommonSshClient.java @@ -7,22 +7,20 @@ import org.apache.sshd.common.PropertyResolverUtils; import org.apache.sshd.core.CoreModuleProperties; /** - * ssh公共client - * + * common ssh pool client * */ @Slf4j public class CommonSshClient { private static final SshClient SSH_CLIENT; - - + static { SSH_CLIENT = SshClient.setUpDefaultClient(); - // 接受所有服务端公钥校验,会打印warn日志 Server at {} presented unverified {} key: {} + // accept all server key verifier, will print warn log : Server at {} presented unverified {} key: {} AcceptAllServerKeyVerifier verifier = AcceptAllServerKeyVerifier.INSTANCE; SSH_CLIENT.setServerKeyVerifier(verifier); - // 设置链接保活心跳2000毫秒一次, 客户端等待保活心跳响应超时时间300_000毫秒 + // set connection heartbeat interval time 2000ms, wait for heartbeat response timeout 300_000ms PropertyResolverUtils.updateProperty( SSH_CLIENT, CoreModuleProperties.HEARTBEAT_INTERVAL.getName(), 2000); PropertyResolverUtils.updateProperty( diff --git a/collector/src/main/java/org/dromara/hertzbeat/collector/collect/database/JdbcCommonCollect.java b/collector/src/main/java/org/dromara/hertzbeat/collector/collect/database/JdbcCommonCollect.java index a22e3c5248..66d471b004 100644 --- a/collector/src/main/java/org/dromara/hertzbeat/collector/collect/database/JdbcCommonCollect.java +++ b/collector/src/main/java/org/dromara/hertzbeat/collector/collect/database/JdbcCommonCollect.java @@ -46,8 +46,7 @@ import java.util.Objects; import java.util.Optional; /** - * 数据库JDBC通用查询 - * + * common query for database query * */ @Slf4j @@ -56,15 +55,14 @@ public class JdbcCommonCollect extends AbstractCollect { private static final String QUERY_TYPE_ONE_ROW = "oneRow"; private static final String QUERY_TYPE_MULTI_ROW = "multiRow"; private static final String QUERY_TYPE_COLUMNS = "columns"; - private static final String RUN_SCRIPT = "runScript"; public JdbcCommonCollect(){} @Override - public void collect(CollectRep.MetricsData.Builder builder, long appId, String app, Metrics metrics) { + public void collect(CollectRep.MetricsData.Builder builder, long monitorId, String app, Metrics metrics) { long startTime = System.currentTimeMillis(); - // 简单校验必有参数 + // check the params if (metrics == null || metrics.getJdbc() == null) { builder.setCode(CollectRep.Code.FAIL); builder.setMsg("DATABASE collect must has jdbc params"); @@ -72,7 +70,6 @@ public class JdbcCommonCollect extends AbstractCollect { } JdbcProtocol jdbcProtocol = metrics.getJdbc(); String databaseUrl = constructDatabaseUrl(jdbcProtocol); - // 查询超时时间默认6000毫秒 int timeout = CollectUtil.getTimeout(jdbcProtocol.getTimeout()); Statement statement = null; try { @@ -147,11 +144,11 @@ public class JdbcCommonCollect extends AbstractCollect { JdbcConnect jdbcConnect = (JdbcConnect) cacheOption.get(); try { statement = jdbcConnect.getConnection().createStatement(); - // 设置查询超时时间10秒 + // set query timeout int timeoutSecond = timeout / 1000; timeoutSecond = timeoutSecond <= 0 ? 1 : timeoutSecond; statement.setQueryTimeout(timeoutSecond); - // 设置查询最大行数1000行 + // set query max row number statement.setMaxRows(1000); } catch (Exception e) { log.info("The jdbc connect from cache, create statement error: {}", e.getMessage()); @@ -170,14 +167,12 @@ public class JdbcCommonCollect extends AbstractCollect { if (statement != null) { return statement; } - // 复用失败则新建连接 + // renew connection when failed Connection connection = DriverManager.getConnection(url, username, password); statement = connection.createStatement(); - // 设置查询超时时间10秒 int timeoutSecond = timeout / 1000; timeoutSecond = timeoutSecond <= 0 ? 1 : timeoutSecond; statement.setQueryTimeout(timeoutSecond); - // 设置查询最大行数1000行 statement.setMaxRows(1000); JdbcConnect jdbcConnect = new JdbcConnect(connection); CommonCache.getInstance().addCache(identifier, jdbcConnect); @@ -185,13 +180,13 @@ public class JdbcCommonCollect extends AbstractCollect { } /** - * 查询一行数据, 通过查询返回结果集的列名称,和查询的字段映射 + * query one row record, response metrics header and one value row * eg: - * 查询字段:one tow three four - * 查询SQL:select one, tow, three, four from book limit 1; - * @param statement 执行器 + * query metrics:one tow three four + * query sql:select one, tow, three, four from book limit 1; + * @param statement statement * @param sql sql - * @param columns 查询的列头(一般是数据库表字段,也可能包含特殊字段,eg: responseTime) + * @param columns query metrics field list * @throws Exception when error happen */ private void queryOneRow(Statement statement, String sql, List columns, @@ -216,14 +211,18 @@ public class JdbcCommonCollect extends AbstractCollect { } /** - * 查询一行数据, 通过查询的两列数据(key-value),key和查询的字段匹配,value为查询字段的值 + * query two columns to mapping one row * eg: - * 查询字段:one two three four - * 查询SQL:select key, value from book; - * 返回的key映射查询字段 - * @param statement 执行器 + * query metrics:one two three four + * query sql:select key, value from book; the key is the query metrics fields + * select key, value from book; + * one - value1 + * two - value2 + * three - value3 + * four - value4 + * @param statement statement * @param sql sql - * @param columns 查询的列头(一般是数据库表字段,也可能包含特殊字段,eg: responseTime) + * @param columns query metrics field list * @throws Exception when error happen */ private void queryOneRowByMatchTwoColumns(Statement statement, String sql, List columns, @@ -251,13 +250,14 @@ public class JdbcCommonCollect extends AbstractCollect { } /** - * 查询多行数据, 通过查询返回结果集的列名称,和查询的字段映射 + * query multi row record, response metrics header and multi value row * eg: - * 查询字段:one tow three four - * 查询SQL:select one, tow, three, four from book; - * @param statement 执行器 + * query metrics:one tow three four + * query sql:select one, tow, three, four from book; + * and return multi row record mapping with the metrics + * @param statement statement * @param sql sql - * @param columns 查询的列头(一般是数据库表字段,也可能包含特殊字段,eg: responseTime) + * @param columns query metrics field list * @throws Exception when error happen */ private void queryMultiRow(Statement statement, String sql, List columns, @@ -281,7 +281,7 @@ public class JdbcCommonCollect extends AbstractCollect { } /** - * 根据jdbc入参构造数据库URL + * construct jdbc url due the jdbc protocol * @param jdbcProtocol jdbc * @return URL */ @@ -289,7 +289,7 @@ public class JdbcCommonCollect extends AbstractCollect { if (Objects.nonNull(jdbcProtocol.getUrl()) && !Objects.equals("", jdbcProtocol.getUrl()) && jdbcProtocol.getUrl().startsWith("jdbc")) { - // 入参数URL有效 则优先级最高返回 + // when has config jdbc url, use it return jdbcProtocol.getUrl(); } String url; diff --git a/collector/src/main/java/org/dromara/hertzbeat/collector/collect/database/JdbcSpiLoader.java b/collector/src/main/java/org/dromara/hertzbeat/collector/collect/database/JdbcSpiLoader.java index a76efd88b7..183ff650b1 100644 --- a/collector/src/main/java/org/dromara/hertzbeat/collector/collect/database/JdbcSpiLoader.java +++ b/collector/src/main/java/org/dromara/hertzbeat/collector/collect/database/JdbcSpiLoader.java @@ -24,8 +24,7 @@ import org.springframework.core.annotation.Order; import org.springframework.stereotype.Service; /** - * 预加载jdbc驱动包 避免spi并发加载造成死锁 - * + * load the jdbc driver first to avoid spi concurrent deadlock * */ @Service diff --git a/collector/src/main/java/org/dromara/hertzbeat/collector/collect/ftp/FtpCollectImpl.java b/collector/src/main/java/org/dromara/hertzbeat/collector/collect/ftp/FtpCollectImpl.java index 244268d2b1..d46d337f51 100644 --- a/collector/src/main/java/org/dromara/hertzbeat/collector/collect/ftp/FtpCollectImpl.java +++ b/collector/src/main/java/org/dromara/hertzbeat/collector/collect/ftp/FtpCollectImpl.java @@ -18,9 +18,6 @@ import java.util.Objects; /** * ftp protocol collection implementation - * ftp协议采集实现 - * - * * */ @Slf4j @@ -30,7 +27,7 @@ public class FtpCollectImpl extends AbstractCollect { private final String PASSWORD = "password"; @Override - public void collect(CollectRep.MetricsData.Builder builder, long appId, String app, Metrics metrics) { + public void collect(CollectRep.MetricsData.Builder builder, long monitorId, String app, Metrics metrics) { FTPClient ftpClient = new FTPClient(); FtpProtocol ftpProtocol = metrics.getFtp(); // Set timeout @@ -67,10 +64,10 @@ public class FtpCollectImpl extends AbstractCollect { /** * collect data: key-value - * Please modify this, if you want to add some indicators. + * Please modify this, if you want to add some metrics. */ private Map collectValue(FTPClient ftpClient, FtpProtocol ftpProtocol) { - Boolean isActive; + boolean isActive; String responseTime; try { long startTime = System.currentTimeMillis(); @@ -79,14 +76,14 @@ public class FtpCollectImpl extends AbstractCollect { // In here, we can do some extended operation without changing the architecture isActive = ftpClient.changeWorkingDirectory(ftpProtocol.getDirection()); long endTime = System.currentTimeMillis(); - responseTime = (endTime - startTime) + ""; + responseTime = String.valueOf(endTime - startTime); ftpClient.disconnect(); } catch (Exception e) { log.info("[FTPClient] error: {}", CommonUtil.getMessageFromThrowable(e), e); throw new IllegalArgumentException(e.getMessage()); } return new HashMap<>(8) {{ - put("isActive", isActive.toString()); + put("isActive", Boolean.toString(isActive)); put("responseTime", responseTime); }}; } diff --git a/collector/src/main/java/org/dromara/hertzbeat/collector/collect/http/HttpCollectImpl.java b/collector/src/main/java/org/dromara/hertzbeat/collector/collect/http/HttpCollectImpl.java index ef1b47aeea..418704c4df 100644 --- a/collector/src/main/java/org/dromara/hertzbeat/collector/collect/http/HttpCollectImpl.java +++ b/collector/src/main/java/org/dromara/hertzbeat/collector/collect/http/HttpCollectImpl.java @@ -101,9 +101,8 @@ public class HttpCollectImpl extends AbstractCollect { @Override public void collect(CollectRep.MetricsData.Builder builder, - long appId, String app, Metrics metrics) { + long monitorId, String app, Metrics metrics) { long startTime = System.currentTimeMillis(); - // 校验参数 try { validateParams(metrics); } catch (Exception e) { @@ -120,16 +119,13 @@ public class HttpCollectImpl extends AbstractCollect { boolean isSuccessInvoke = checkSuccessInvoke(metrics, statusCode); log.debug("http response status: {}", statusCode); if (!isSuccessInvoke) { - // 状态码不在successCodes中的状态码为失败 builder.setCode(CollectRep.Code.FAIL); builder.setMsg("StatusCode " + statusCode); return; } - // 在successCodes中的状态码成功 // todo 这里直接将InputStream转为了String, 对于prometheus exporter大数据来说, 会生成大对象, 可能会严重影响JVM内存空间 // todo 方法一、使用InputStream进行解析, 代码改动大; 方法二、手动触发gc, 可以参考dubbo for long i String resp = EntityUtils.toString(response.getEntity(), StandardCharsets.UTF_8); - // 根据不同的解析方式解析 if (resp == null || "".equals(resp)) { log.info("http response entity is empty, status: {}.", statusCode); } @@ -164,25 +160,21 @@ public class HttpCollectImpl extends AbstractCollect { builder.setCode(CollectRep.Code.UN_CONNECTABLE); builder.setMsg(errorMsg); } catch (UnknownHostException e2) { - // 对端不可达 String errorMsg = CommonUtil.getMessageFromThrowable(e2); log.info(errorMsg); builder.setCode(CollectRep.Code.UN_REACHABLE); builder.setMsg("unknown host:" + errorMsg); } catch (InterruptedIOException | ConnectException | SSLException e3) { - // 对端连接失败 String errorMsg = CommonUtil.getMessageFromThrowable(e3); log.info(errorMsg); builder.setCode(CollectRep.Code.UN_CONNECTABLE); builder.setMsg(errorMsg); } catch (IOException e4) { - // 其它IO异常 String errorMsg = CommonUtil.getMessageFromThrowable(e4); log.info(errorMsg); builder.setCode(CollectRep.Code.FAIL); builder.setMsg(errorMsg); } catch (Exception e) { - // 其它异常 String errorMsg = CommonUtil.getMessageFromThrowable(e); log.error(errorMsg, e); builder.setCode(CollectRep.Code.FAIL); @@ -218,7 +210,6 @@ public class HttpCollectImpl extends AbstractCollect { private void parseResponseByWebsite(String resp, List aliasFields, HttpProtocol http, CollectRep.MetricsData.Builder builder, Long responseTime) { CollectRep.ValueRow.Builder valueRowBuilder = CollectRep.ValueRow.newBuilder(); - // 网站关键词数量监测 int keywordNum = CollectUtil.countMatchKeyword(resp, http.getKeyword()); for (String alias : aliasFields) { if (CollectorConstants.RESPONSE_TIME.equalsIgnoreCase(alias)) { @@ -235,7 +226,6 @@ public class HttpCollectImpl extends AbstractCollect { private void parseResponseBySiteMap(String resp, List aliasFields, CollectRep.MetricsData.Builder builder) { List siteUrls = new LinkedList<>(); - // 使用xml解析 boolean isXmlFormat = true; try { DocumentBuilderFactory dbf = DocumentBuilderFactory.newInstance(); @@ -288,13 +278,10 @@ public class HttpCollectImpl extends AbstractCollect { errorMsg = e1.getMessage(); } } catch (UnknownHostException e2) { - // 对端不可达 errorMsg = "unknown host"; } catch (InterruptedIOException | ConnectException | SSLException e3) { - // 对端连接失败 errorMsg = "connect error: " + e3.getMessage(); } catch (IOException e4) { - // 其它IO异常 errorMsg = "io error: " + e4.getMessage(); } catch (Exception e) { errorMsg = "error: " + e.getMessage(); @@ -458,7 +445,6 @@ public class HttpCollectImpl extends AbstractCollect { /** * create httpContext - * * @param httpProtocol http protocol * @return context */ @@ -483,14 +469,12 @@ public class HttpCollectImpl extends AbstractCollect { } /** - * 根据http配置参数构造请求头 - * - * @param httpProtocol http参数配置 - * @return 请求体 + * create http request + * @param httpProtocol http params + * @return http uri request */ public HttpUriRequest createHttpRequest(HttpProtocol httpProtocol) { RequestBuilder requestBuilder; - // method String httpMethod = httpProtocol.getMethod().toUpperCase(); if (HttpMethod.GET.matches(httpMethod)) { requestBuilder = RequestBuilder.get(); @@ -540,11 +524,9 @@ public class HttpCollectImpl extends AbstractCollect { requestBuilder.addHeader(HttpHeaders.ACCEPT, "*/*"); } - // 判断是否使用Bearer Token认证 if (httpProtocol.getAuthorization() != null) { HttpProtocol.Authorization authorization = httpProtocol.getAuthorization(); if (DispatchConstants.BEARER_TOKEN.equalsIgnoreCase(authorization.getType())) { - // 若使用 将token放入到header里面 String value = DispatchConstants.BEARER + " " + authorization.getBearerTokenToken(); requestBuilder.addHeader(HttpHeaders.AUTHORIZATION, value); } else if (DispatchConstants.BASIC_AUTH.equals(authorization.getType())) { @@ -557,7 +539,7 @@ public class HttpCollectImpl extends AbstractCollect { } } - // 请求内容,会覆盖post协议的params + // if it has payload, would override post params if (StringUtils.hasLength(httpProtocol.getPayload())) { requestBuilder.setEntity(new StringEntity(httpProtocol.getPayload(), StandardCharsets.UTF_8)); } diff --git a/collector/src/main/java/org/dromara/hertzbeat/collector/collect/http/SslCertificateCollectImpl.java b/collector/src/main/java/org/dromara/hertzbeat/collector/collect/http/SslCertificateCollectImpl.java index a6d32f3e79..075115c4b4 100644 --- a/collector/src/main/java/org/dromara/hertzbeat/collector/collect/http/SslCertificateCollectImpl.java +++ b/collector/src/main/java/org/dromara/hertzbeat/collector/collect/http/SslCertificateCollectImpl.java @@ -46,7 +46,6 @@ import static org.dromara.hertzbeat.common.constants.SignConstants.RIGHT_DASH; /** * ssl Certificate * - * */ @Slf4j public class SslCertificateCollectImpl extends AbstractCollect { @@ -62,7 +61,7 @@ public class SslCertificateCollectImpl extends AbstractCollect { @Override public void collect(CollectRep.MetricsData.Builder builder, - long appId, String app, Metrics metrics) { + long monitorId, String app, Metrics metrics) { long startTime = System.currentTimeMillis(); try { validateParams(metrics); @@ -126,25 +125,21 @@ public class SslCertificateCollectImpl extends AbstractCollect { builder.setCode(CollectRep.Code.FAIL); builder.setMsg(errorMsg); } catch (UnknownHostException e2) { - // 对端不可达 String errorMsg = CommonUtil.getMessageFromThrowable(e2); log.info(errorMsg); builder.setCode(CollectRep.Code.UN_REACHABLE); builder.setMsg("unknown host:" + errorMsg); } catch (InterruptedIOException | ConnectException | SSLException e3) { - // 对端连接失败 String errorMsg = CommonUtil.getMessageFromThrowable(e3); log.info(errorMsg); builder.setCode(CollectRep.Code.UN_CONNECTABLE); builder.setMsg(errorMsg); } catch (IOException e4) { - // 其它IO异常 String errorMsg = CommonUtil.getMessageFromThrowable(e4); log.info(errorMsg); builder.setCode(CollectRep.Code.FAIL); builder.setMsg(errorMsg); } catch (Exception e) { - // 其它异常 String errorMsg = CommonUtil.getMessageFromThrowable(e); log.error(errorMsg, e); builder.setCode(CollectRep.Code.FAIL); diff --git a/collector/src/main/java/org/dromara/hertzbeat/collector/collect/icmp/IcmpCollectImpl.java b/collector/src/main/java/org/dromara/hertzbeat/collector/collect/icmp/IcmpCollectImpl.java index 7a181bb7d4..f7fbebd7d7 100644 --- a/collector/src/main/java/org/dromara/hertzbeat/collector/collect/icmp/IcmpCollectImpl.java +++ b/collector/src/main/java/org/dromara/hertzbeat/collector/collect/icmp/IcmpCollectImpl.java @@ -32,8 +32,7 @@ import java.net.InetAddress; import java.net.UnknownHostException; /** - * icmp协议采集实现 - ping - * + * icmp ping collect * */ @Slf4j @@ -42,7 +41,7 @@ public class IcmpCollectImpl extends AbstractCollect { public IcmpCollectImpl(){} @Override - public void collect(CollectRep.MetricsData.Builder builder, long appId, String app, Metrics metrics) { + public void collect(CollectRep.MetricsData.Builder builder, long monitorId, String app, Metrics metrics) { long startTime = System.currentTimeMillis(); // 简单校验必有参数 if (metrics == null || metrics.getIcmp() == null) { @@ -59,8 +58,9 @@ public class IcmpCollectImpl extends AbstractCollect { log.warn(e.getMessage()); } try { + // todo need root java jcm to use ICMP, else it telnet the peer server 7 port available // todo 需要配置java虚拟机root权限从而使用ICMP,否则是判断telnet对端7号端口是否开通 - // https://stackoverflow.com/questions/11506321/how-to-ping-an-ip-address + // todo https://stackoverflow.com/questions/11506321/how-to-ping-an-ip-address boolean status = InetAddress.getByName(icmp.getHost()).isReachable(timeout); long responseTime = System.currentTimeMillis() - startTime; if (status) { diff --git a/collector/src/main/java/org/dromara/hertzbeat/collector/collect/jmx/JmxCollectImpl.java b/collector/src/main/java/org/dromara/hertzbeat/collector/collect/jmx/JmxCollectImpl.java index b1f8800c04..3b87958307 100644 --- a/collector/src/main/java/org/dromara/hertzbeat/collector/collect/jmx/JmxCollectImpl.java +++ b/collector/src/main/java/org/dromara/hertzbeat/collector/collect/jmx/JmxCollectImpl.java @@ -26,11 +26,8 @@ import java.util.concurrent.TimeUnit; import java.util.stream.Collectors; /** - * jmx 协议采集实现 - jmx * jmx protocol acquisition implementation * - * - * */ @Slf4j public class JmxCollectImpl extends AbstractCollect { @@ -45,7 +42,7 @@ public class JmxCollectImpl extends AbstractCollect { } @Override - public void collect(CollectRep.MetricsData.Builder builder, long appId, String app, Metrics metrics) { + public void collect(CollectRep.MetricsData.Builder builder, long monitorId, String app, Metrics metrics) { try { JmxProtocol jmxProtocol = metrics.getJmx(); diff --git a/collector/src/main/java/org/dromara/hertzbeat/collector/collect/mongodb/MongodbSingleCollectImpl.java b/collector/src/main/java/org/dromara/hertzbeat/collector/collect/mongodb/MongodbSingleCollectImpl.java index d553a590ef..975b09447c 100644 --- a/collector/src/main/java/org/dromara/hertzbeat/collector/collect/mongodb/MongodbSingleCollectImpl.java +++ b/collector/src/main/java/org/dromara/hertzbeat/collector/collect/mongodb/MongodbSingleCollectImpl.java @@ -44,7 +44,7 @@ import org.dromara.hertzbeat.collector.collect.AbstractCollect; import lombok.extern.slf4j.Slf4j; /** - * Mongodb 单机指标收集器 + * Mongodb single collect * * * see also https://www.mongodb.com/languages/java, @@ -80,7 +80,7 @@ public class MongodbSingleCollectImpl extends AbstractCollect { }; @Override - public void collect(CollectRep.MetricsData.Builder builder, long appId, String app, Metrics metrics) { + public void collect(CollectRep.MetricsData.Builder builder, long monitorId, String app, Metrics metrics) { try { preCheck(metrics); } catch (Exception e) { diff --git a/collector/src/main/java/org/dromara/hertzbeat/collector/collect/mq/RocketmqCollectData.java b/collector/src/main/java/org/dromara/hertzbeat/collector/collect/mq/RocketmqCollectData.java index 4386999833..c33e29e968 100644 --- a/collector/src/main/java/org/dromara/hertzbeat/collector/collect/mq/RocketmqCollectData.java +++ b/collector/src/main/java/org/dromara/hertzbeat/collector/collect/mq/RocketmqCollectData.java @@ -6,10 +6,9 @@ import java.util.List; import java.util.Map; /** - * rocketmq采集数据实体类 + * rocketmq collect data * * - * @since 5/6/2023 */ @Data public class RocketmqCollectData { diff --git a/collector/src/main/java/org/dromara/hertzbeat/collector/collect/mq/RocketmqSingleCollectImpl.java b/collector/src/main/java/org/dromara/hertzbeat/collector/collect/mq/RocketmqSingleCollectImpl.java index ed6c1b5f5a..398354dd10 100644 --- a/collector/src/main/java/org/dromara/hertzbeat/collector/collect/mq/RocketmqSingleCollectImpl.java +++ b/collector/src/main/java/org/dromara/hertzbeat/collector/collect/mq/RocketmqSingleCollectImpl.java @@ -48,7 +48,7 @@ import java.util.concurrent.atomic.AtomicLong; import java.util.stream.Collectors; /** - * rocketmq采集实现类 + * rocketmq collect * * * @since 5/6/2023 @@ -96,7 +96,7 @@ public class RocketmqSingleCollectImpl extends AbstractCollect implements Dispos } @Override - public void collect(CollectRep.MetricsData.Builder builder, long appId, String app, Metrics metrics) { + public void collect(CollectRep.MetricsData.Builder builder, long monitorId, String app, Metrics metrics) { try { preCheck(metrics); } catch (Exception e) { @@ -131,9 +131,8 @@ public class RocketmqSingleCollectImpl extends AbstractCollect implements Dispos } /** - * 采集前置条件, 入参判断 - * - * @param metrics 数据指标 + * preCheck params + * @param metrics metrics config */ private void preCheck(Metrics metrics) { if (metrics == null || metrics.getRocketmq() == null) { @@ -145,9 +144,9 @@ public class RocketmqSingleCollectImpl extends AbstractCollect implements Dispos } /** - * 创建DefaultMQAdminExt实体类; 这里有个小问题, 是否需要每次都重新创建 - * - * @param metrics 数据指标 + * create the DefaultMQAdminExt + * one problem the DefaultMQAdminExt can not reuse + * @param metrics metrics * @return DefaultMQAdminExt */ private DefaultMQAdminExt createMqAdminExt(Metrics metrics) { @@ -164,11 +163,10 @@ public class RocketmqSingleCollectImpl extends AbstractCollect implements Dispos } /** - * 采集rocketmq数据 - * - * @param mqAdminExt rocketmq提供的远程调用类 - * @param rocketmqCollectData rocketmq数据采集类 - * @throws Exception 远程调用异常 + * collect rocketmq data + * @param mqAdminExt rocketmq rpc admin + * @param rocketmqCollectData rocketmq data + * @throws Exception when rpc error */ private void collectData(DefaultMQAdminExt mqAdminExt, RocketmqCollectData rocketmqCollectData) throws Exception { this.collectClusterData(mqAdminExt, rocketmqCollectData); @@ -177,11 +175,10 @@ public class RocketmqSingleCollectImpl extends AbstractCollect implements Dispos } /** - * 采集rocketmq的集群数据 - * - * @param mqAdminExt rocketmq提供的远程调用类 - * @param rocketmqCollectData rocketmq数据采集类 - * @throws Exception 远程调用异常 + * collect rocketmq cluster data + * @param mqAdminExt rocketmq rpc admin + * @param rocketmqCollectData rocketmq data + * @throws Exception when rpc error */ private void collectClusterData(DefaultMQAdminExt mqAdminExt, RocketmqCollectData rocketmqCollectData) throws Exception { try { @@ -239,7 +236,6 @@ public class RocketmqSingleCollectImpl extends AbstractCollect implements Dispos clusterBrokerData.setTodayConsumeCount(todayConsumerCount); } } - } } catch (Exception e) { log.warn("collect rocketmq cluster data error", e); @@ -248,16 +244,15 @@ public class RocketmqSingleCollectImpl extends AbstractCollect implements Dispos } /** - * 采集rocketmq的消费者数据 - * - * @param mqAdminExt rocketmq提供的远程调用类 - * @param rocketmqCollectData rocketmq数据采集类 - * @throws Exception 远程调用异常 + * collect rocketmq consumer data + * @param mqAdminExt rocketmq rpc admin + * @param rocketmqCollectData rocketmq data + * @throws Exception when rpc error */ private void collectConsumerData(DefaultMQAdminExt mqAdminExt, RocketmqCollectData rocketmqCollectData) throws Exception { Set consumerGroupSet = new HashSet<>(); try { - // 获取consumerGroup集合 + // get consumerGroup ClusterInfo clusterInfo = mqAdminExt.examineBrokerClusterInfo(); for (BrokerData brokerData : clusterInfo.getBrokerAddrTable().values()) { SubscriptionGroupWrapper subscriptionGroupWrapper = mqAdminExt.getAllSubscriptionGroup(brokerData.selectBrokerAddr(), 3000L); @@ -316,9 +311,10 @@ public class RocketmqSingleCollectImpl extends AbstractCollect implements Dispos } /** - * @param mqAdminExt rocketmq提供的远程调用类 - * @param rocketmqCollectData rocketmq数据采集类 - * @throws Exception 远程调用异常 + * collect topic data + * @param mqAdminExt rocketmq rpc admin + * @param rocketmqCollectData rocketmq data + * @throws Exception when rpc error */ private void collectTopicData(DefaultMQAdminExt mqAdminExt, RocketmqCollectData rocketmqCollectData) throws Exception { try { @@ -333,7 +329,6 @@ public class RocketmqSingleCollectImpl extends AbstractCollect implements Dispos List topicQueueInfoList = new ArrayList<>(); // todo 查询topic的queue信息需要for循环调用 mqAdminExt.examineTopicStats(), topic数量很大的情况, 调用次数也会很多 - topicQueueInfoTable.put(topic, topicQueueInfoList); topicInfoList.add(topicQueueInfoTable); rocketmqCollectData.setTopicInfoList(topicInfoList); @@ -345,12 +340,12 @@ public class RocketmqSingleCollectImpl extends AbstractCollect implements Dispos } /** - * 采集数据填充到builder + * fill data to builder * - * @param rocketmqCollectData rocketmq数据采集类 + * @param rocketmqCollectData rocketmq data * @param builder metrics data builder - * @param aliasFields 字段别名 - * @param parseScript JSON的base path + * @param aliasFields alia fields + * @param parseScript JSON base path */ private void fillBuilder(RocketmqCollectData rocketmqCollectData, CollectRep.MetricsData.Builder builder, List aliasFields, String parseScript) { String dataJson = JSONObject.toJSONString(rocketmqCollectData); diff --git a/collector/src/main/java/org/dromara/hertzbeat/collector/collect/prometheus/PrometheusAutoCollectImpl.java b/collector/src/main/java/org/dromara/hertzbeat/collector/collect/prometheus/PrometheusAutoCollectImpl.java index 1b5df1f84f..9e4c7409df 100644 --- a/collector/src/main/java/org/dromara/hertzbeat/collector/collect/prometheus/PrometheusAutoCollectImpl.java +++ b/collector/src/main/java/org/dromara/hertzbeat/collector/collect/prometheus/PrometheusAutoCollectImpl.java @@ -68,8 +68,7 @@ import static org.dromara.hertzbeat.common.constants.SignConstants.RIGHT_DASH; /** - * http https collect - * + * prometheus auto collect * */ @Slf4j @@ -100,18 +99,15 @@ public class PrometheusAutoCollectImpl { boolean isSuccessInvoke = defaultSuccessStatusCodes.contains(statusCode); log.debug("http response status: {}", statusCode); if (!isSuccessInvoke) { - // 状态码不在successCodes中的状态码为失败 builder.setCode(CollectRep.Code.FAIL); builder.setMsg("StatusCode " + statusCode); return null; } - // 在successCodes中的状态码成功 // todo 这里直接将InputStream转为了String, 对于prometheus exporter大数据来说, 会生成大对象, 可能会严重影响JVM内存空间 // todo 方法一、使用InputStream进行解析, 代码改动大; 方法二、手动触发gc, 可以参考dubbo for long i String resp = EntityUtils.toString(response.getEntity(), StandardCharsets.UTF_8); long collectTime = System.currentTimeMillis(); builder.setTime(collectTime); - // 根据不同的解析方式解析 if (resp == null || "".equals(resp)) { log.error("http response content is empty, status: {}.", statusCode); builder.setCode(CollectRep.Code.FAIL); @@ -131,25 +127,21 @@ public class PrometheusAutoCollectImpl { builder.setCode(CollectRep.Code.UN_CONNECTABLE); builder.setMsg(errorMsg); } catch (UnknownHostException e2) { - // 对端不可达 String errorMsg = CommonUtil.getMessageFromThrowable(e2); log.info(errorMsg); builder.setCode(CollectRep.Code.UN_REACHABLE); builder.setMsg("unknown host:" + errorMsg); } catch (InterruptedIOException | ConnectException | SSLException e3) { - // 对端连接失败 String errorMsg = CommonUtil.getMessageFromThrowable(e3); log.info(errorMsg); builder.setCode(CollectRep.Code.UN_CONNECTABLE); builder.setMsg(errorMsg); } catch (IOException e4) { - // 其它IO异常 String errorMsg = CommonUtil.getMessageFromThrowable(e4); log.info(errorMsg); builder.setCode(CollectRep.Code.FAIL); builder.setMsg(errorMsg); } catch (Exception e) { - // 其它异常 String errorMsg = CommonUtil.getMessageFromThrowable(e); log.error(errorMsg, e); builder.setCode(CollectRep.Code.FAIL); @@ -264,12 +256,11 @@ public class PrometheusAutoCollectImpl { } return null; } - + /** - * 根据http配置参数构造请求头 - * - * @param protocol 参数配置 - * @return 请求体 + * create http request + * @param protocol http params + * @return http uri request */ public HttpUriRequest createHttpRequest(PrometheusProtocol protocol) { RequestBuilder requestBuilder = RequestBuilder.get(); @@ -299,11 +290,9 @@ public class PrometheusAutoCollectImpl { // add accept requestBuilder.addHeader(HttpHeaders.ACCEPT, "*/*"); - // 判断是否使用Bearer Token认证 if (protocol.getAuthorization() != null) { PrometheusProtocol.Authorization authorization = protocol.getAuthorization(); if (DispatchConstants.BEARER_TOKEN.equalsIgnoreCase(authorization.getType())) { - // 若使用 将token放入到header里面 String value = DispatchConstants.BEARER + " " + authorization.getBearerTokenToken(); requestBuilder.addHeader(HttpHeaders.AUTHORIZATION, value); } else if (DispatchConstants.BASIC_AUTH.equals(authorization.getType())) { @@ -315,8 +304,8 @@ public class PrometheusAutoCollectImpl { } } } - - // 请求内容,会覆盖post协议的params + + // if it has payload, would override post params if (StringUtils.hasLength(protocol.getPayload())) { requestBuilder.setEntity(new StringEntity(protocol.getPayload(), StandardCharsets.UTF_8)); } @@ -353,7 +342,7 @@ public class PrometheusAutoCollectImpl { } /** - * 获取实例 + * get collect instance * @return instance */ public static PrometheusAutoCollectImpl getInstance() { @@ -361,7 +350,7 @@ public class PrometheusAutoCollectImpl { } /** - * 静态内部类 + * static instance */ private static class SingleInstance { private static final PrometheusAutoCollectImpl INSTANCE = new PrometheusAutoCollectImpl(); diff --git a/collector/src/main/java/org/dromara/hertzbeat/collector/collect/push/PushCollectImpl.java b/collector/src/main/java/org/dromara/hertzbeat/collector/collect/push/PushCollectImpl.java index 247c458c9d..8b79964f75 100644 --- a/collector/src/main/java/org/dromara/hertzbeat/collector/collect/push/PushCollectImpl.java +++ b/collector/src/main/java/org/dromara/hertzbeat/collector/collect/push/PushCollectImpl.java @@ -54,16 +54,16 @@ public class PushCollectImpl extends AbstractCollect { @Override public void collect(CollectRep.MetricsData.Builder builder, - long appId, String app, Metrics metrics) { + long monitorId, String app, Metrics metrics) { long curTime = System.currentTimeMillis(); PushProtocol pushProtocol = metrics.getPush(); - Long time = timeMap.getOrDefault(appId, curTime - firstCollectInterval); - timeMap.put(appId, curTime); + Long time = timeMap.getOrDefault(monitorId, curTime - firstCollectInterval); + timeMap.put(monitorId, curTime); HttpContext httpContext = createHttpContext(pushProtocol); - HttpUriRequest request = createHttpRequest(pushProtocol, appId, time); + HttpUriRequest request = createHttpRequest(pushProtocol, monitorId, time); try { CloseableHttpResponse response = CommonHttpClient.getHttpClient().execute(request, httpContext); diff --git a/collector/src/main/java/org/dromara/hertzbeat/collector/collect/redis/RedisCommonCollectImpl.java b/collector/src/main/java/org/dromara/hertzbeat/collector/collect/redis/RedisCommonCollectImpl.java index be5deec63f..56ee20dd40 100644 --- a/collector/src/main/java/org/dromara/hertzbeat/collector/collect/redis/RedisCommonCollectImpl.java +++ b/collector/src/main/java/org/dromara/hertzbeat/collector/collect/redis/RedisCommonCollectImpl.java @@ -55,7 +55,7 @@ public class RedisCommonCollectImpl extends AbstractCollect { } @Override - public void collect(CollectRep.MetricsData.Builder builder, long appId, String app, Metrics metrics) { + public void collect(CollectRep.MetricsData.Builder builder, long monitorId, String app, Metrics metrics) { try { preCheck(metrics); } catch (Exception e) { @@ -298,9 +298,7 @@ public class RedisCommonCollectImpl extends AbstractCollect { .forEach(it -> { result.put(it[0], it[1]); }); - // https://github.com/dromara/hertzbeat/pull/913 - // fix 数组越界 - // 如果返回的指标数量小于yml配置的指标总和,不区分指标类型 赋值   + // fix https://github.com/dromara/hertzbeat/pull/913 if (result.size() < fieldTotalSize) { for (Metrics.Field field : metrics.getFields()) { if (!result.containsKey(field.getField())) { diff --git a/collector/src/main/java/org/dromara/hertzbeat/collector/collect/snmp/SnmpCollectImpl.java b/collector/src/main/java/org/dromara/hertzbeat/collector/collect/snmp/SnmpCollectImpl.java index 0676b35ca4..f01f3060a0 100644 --- a/collector/src/main/java/org/dromara/hertzbeat/collector/collect/snmp/SnmpCollectImpl.java +++ b/collector/src/main/java/org/dromara/hertzbeat/collector/collect/snmp/SnmpCollectImpl.java @@ -47,9 +47,6 @@ import java.util.concurrent.ExecutionException; /** * Snmp protocol collection implementation - * snmp 协议采集实现 - * - * * */ @Slf4j @@ -69,9 +66,8 @@ public class SnmpCollectImpl extends AbstractCollect { @Override - public void collect(CollectRep.MetricsData.Builder builder, long appId, String app, Metrics metrics) { + public void collect(CollectRep.MetricsData.Builder builder, long monitorId, String app, Metrics metrics) { long startTime = System.currentTimeMillis(); - // 校验参数 try { validateParams(metrics); } catch (Exception e) { diff --git a/collector/src/main/java/org/dromara/hertzbeat/collector/collect/ssh/SshCollectImpl.java b/collector/src/main/java/org/dromara/hertzbeat/collector/collect/ssh/SshCollectImpl.java index 9ea6fb4777..ae6387eff3 100644 --- a/collector/src/main/java/org/dromara/hertzbeat/collector/collect/ssh/SshCollectImpl.java +++ b/collector/src/main/java/org/dromara/hertzbeat/collector/collect/ssh/SshCollectImpl.java @@ -60,8 +60,6 @@ import java.util.stream.Collectors; /** * Ssh protocol collection implementation - * ssh协议采集实现 - * * */ @Slf4j @@ -77,9 +75,8 @@ public class SshCollectImpl extends AbstractCollect { } @Override - public void collect(CollectRep.MetricsData.Builder builder, long appId, String app, Metrics metrics) { + public void collect(CollectRep.MetricsData.Builder builder, long monitorId, String app, Metrics metrics) { long startTime = System.currentTimeMillis(); - // 校验参数 try { validateParams(metrics); } catch (Exception e) { diff --git a/collector/src/main/java/org/dromara/hertzbeat/collector/collect/strategy/CollectStrategyFactory.java b/collector/src/main/java/org/dromara/hertzbeat/collector/collect/strategy/CollectStrategyFactory.java index 660710caf1..d412933f67 100644 --- a/collector/src/main/java/org/dromara/hertzbeat/collector/collect/strategy/CollectStrategyFactory.java +++ b/collector/src/main/java/org/dromara/hertzbeat/collector/collect/strategy/CollectStrategyFactory.java @@ -11,8 +11,6 @@ import java.util.concurrent.ConcurrentHashMap; /** * Specific metrics collection factory - * 数据收集策略工厂 - * * */ @Configuration @@ -20,13 +18,12 @@ import java.util.concurrent.ConcurrentHashMap; public class CollectStrategyFactory implements CommandLineRunner { /** - * strategy container 策略容器 + * strategy container */ private static final ConcurrentHashMap COLLECT_STRATEGY = new ConcurrentHashMap<>(); /** * get instance of this protocol collection - * 获取注册的收集实现类 * @param protocol collect protocol * @return implement of Metrics Collection */ diff --git a/collector/src/main/java/org/dromara/hertzbeat/collector/collect/telnet/TelnetCollectImpl.java b/collector/src/main/java/org/dromara/hertzbeat/collector/collect/telnet/TelnetCollectImpl.java index b7d9fcbcb6..622fa14469 100644 --- a/collector/src/main/java/org/dromara/hertzbeat/collector/collect/telnet/TelnetCollectImpl.java +++ b/collector/src/main/java/org/dromara/hertzbeat/collector/collect/telnet/TelnetCollectImpl.java @@ -19,6 +19,7 @@ package org.dromara.hertzbeat.collector.collect.telnet; import org.dromara.hertzbeat.collector.collect.AbstractCollect; import org.dromara.hertzbeat.collector.dispatch.DispatchConstants; +import org.dromara.hertzbeat.collector.util.CollectUtil; import org.dromara.hertzbeat.common.constants.CollectorConstants; import org.dromara.hertzbeat.common.entity.job.Metrics; import org.dromara.hertzbeat.common.entity.job.protocol.TelnetProtocol; @@ -35,8 +36,7 @@ import java.util.*; import java.util.stream.Collectors; /** - * telnet协议采集实现 - * + * telnet collect * */ @Slf4j @@ -45,9 +45,8 @@ public class TelnetCollectImpl extends AbstractCollect { public TelnetCollectImpl(){} @Override - public void collect(CollectRep.MetricsData.Builder builder, long appId, String app, Metrics metrics) { + public void collect(CollectRep.MetricsData.Builder builder, long monitorId, String app, Metrics metrics) { long startTime = System.currentTimeMillis(); - // 简单校验必有参数 if (metrics == null || metrics.getTelnet() == null) { builder.setCode(CollectRep.Code.FAIL); builder.setMsg("Telnet collect must has telnet params"); @@ -55,16 +54,9 @@ public class TelnetCollectImpl extends AbstractCollect { } TelnetProtocol telnet = metrics.getTelnet(); - // 超时时间默认6000毫秒 - int timeout = 6000; - try { - timeout = Integer.parseInt(telnet.getTimeout()); - } catch (Exception e) { - log.warn(e.getMessage()); - } + int timeout = CollectUtil.getTimeout(telnet.getTimeout()); TelnetClient telnetClient = null; try { - //指明Telnet终端类型,否则会返回来的数据中文会乱码 telnetClient = new TelnetClient("vt200"); telnetClient.setConnectTimeout(timeout); telnetClient.connect(telnet.getHost(), Integer.parseInt(telnet.getPort())); @@ -132,7 +124,7 @@ public class TelnetCollectImpl extends AbstractCollect { String result = new String(telnetClient.getInputStream().readAllBytes()); String[] lines = result.split("\n"); boolean contains = lines[0].contains("="); - Map mapValue = Arrays.stream(lines) + return Arrays.stream(lines) .map(item -> { if (contains) { return item.split("="); @@ -142,6 +134,5 @@ public class TelnetCollectImpl extends AbstractCollect { }) .filter(item -> item.length == 2) .collect(Collectors.toMap(x -> x[0], x -> x[1])); - return mapValue; } } diff --git a/collector/src/main/java/org/dromara/hertzbeat/collector/collect/udp/UdpCollectImpl.java b/collector/src/main/java/org/dromara/hertzbeat/collector/collect/udp/UdpCollectImpl.java index e17647bea7..58e60d80cb 100644 --- a/collector/src/main/java/org/dromara/hertzbeat/collector/collect/udp/UdpCollectImpl.java +++ b/collector/src/main/java/org/dromara/hertzbeat/collector/collect/udp/UdpCollectImpl.java @@ -32,8 +32,7 @@ import java.net.*; import java.nio.charset.StandardCharsets; /** - * udp探测协议采集实现 - * + * udp collect * */ @Slf4j @@ -45,16 +44,14 @@ public class UdpCollectImpl extends AbstractCollect { } @Override - public void collect(CollectRep.MetricsData.Builder builder, long appId, String app, Metrics metrics) { + public void collect(CollectRep.MetricsData.Builder builder, long monitorId, String app, Metrics metrics) { long startTime = System.currentTimeMillis(); - // 简单校验必有参数 if (metrics == null || metrics.getUdp() == null) { builder.setCode(CollectRep.Code.FAIL); builder.setMsg("Udp collect must has udp params"); return; } UdpProtocol udpProtocol = metrics.getUdp(); - // 超时时间默认6000毫秒 int timeout = CollectUtil.getTimeout(udpProtocol.getTimeout()); try (DatagramSocket socket = new DatagramSocket()) { socket.setSoTimeout(timeout); diff --git a/collector/src/main/java/org/dromara/hertzbeat/collector/dispatch/CollectDataDispatch.java b/collector/src/main/java/org/dromara/hertzbeat/collector/dispatch/CollectDataDispatch.java index 74d737d929..9ad5eba2f8 100644 --- a/collector/src/main/java/org/dromara/hertzbeat/collector/dispatch/CollectDataDispatch.java +++ b/collector/src/main/java/org/dromara/hertzbeat/collector/dispatch/CollectDataDispatch.java @@ -26,27 +26,23 @@ import java.util.List; /** * Collection data scheduler interface - * 采集数据调度器接口 */ public interface CollectDataDispatch { /** * Processing and distributing collection result data - * 处理分发采集结果数据 - * - * @param timeout time wheel timeout 时间轮timeout - * @param metrics The following indicator group collection tasks 下面的指标组采集任务 - * @param metricsData Collect result data 采集结果数据 + * @param timeout time wheel timeout + * @param metrics The following metrics collection tasks + * @param metricsData Collect result data */ void dispatchCollectData(Timeout timeout, Metrics metrics, CollectRep.MetricsData metricsData); /** * Processing and distributing collection result data - * 处理分发采集结果数据 * - * @param timeout time wheel timeout 时间轮timeout - * @param metrics The following indicator group collection tasks 下面的指标组采集任务 - * @param metricsDataList Collect result data 采集结果数据 + * @param timeout time wheel timeout + * @param metrics The following metrics collection tasks + * @param metricsDataList Collect result data */ void dispatchCollectData(Timeout timeout, Metrics metrics, List metricsDataList); diff --git a/collector/src/main/java/org/dromara/hertzbeat/collector/dispatch/CommonDispatcher.java b/collector/src/main/java/org/dromara/hertzbeat/collector/dispatch/CommonDispatcher.java index 5977c40cdf..16a6b8fd03 100644 --- a/collector/src/main/java/org/dromara/hertzbeat/collector/dispatch/CommonDispatcher.java +++ b/collector/src/main/java/org/dromara/hertzbeat/collector/dispatch/CommonDispatcher.java @@ -47,9 +47,7 @@ import java.util.concurrent.atomic.AtomicInteger; import java.util.concurrent.atomic.AtomicReference; /** - * Indicator group collection task and response data scheduler - * 指标组采集任务与响应数据调度器 - * + * Collection task and response data scheduler * */ @Component @@ -57,34 +55,28 @@ import java.util.concurrent.atomic.AtomicReference; public class CommonDispatcher implements MetricsTaskDispatch, CollectDataDispatch, DisposableBean { /** - * Metric group collection task timeout value - * 指标组采集任务超时时间值 + * Collection task timeout value */ private static final long DURATION_TIME = 240_000L; /** - * trigger sub task max num - * 触发子任务最大数量 + * Trigger sub task max num */ private static final int MAX_SUB_TASK_NUM = 50; private static final Gson GSON = new Gson(); /** - * Priority queue of index group collection tasks - * 指标组采集任务优先级队列 + * Priority queue of index collection tasks */ private final MetricsCollectorQueue jobRequestQueue; /** * Time round task scheduler - * 时间轮任务调度器 */ private final TimerDispatch timerDispatch; /** * collection data exporter - * 采集数据导出器 */ private final CommonDataQueue commonDataQueue; /** - * Metric group task and start time mapping map - * 指标组任务与开始时间映射map + * Metrics task and start time mapping map */ private final Map metricsTimeoutMonitorMap; @@ -121,8 +113,7 @@ public class CommonDispatcher implements MetricsTaskDispatch, CollectDataDispatc public void start() { try { - // Pull the indicator group collection task from the task queue and put it into the thread pool for execution - // 从任务队列拉取指标组采集任务放入线程池执行 + // Pull the collection task from the task queue and put it into the thread pool for execution poolExecutor.execute(() -> { Thread.currentThread().setName("metrics-task-dispatcher"); while (!Thread.currentThread().isInterrupted()) { @@ -138,7 +129,6 @@ public class CommonDispatcher implements MetricsTaskDispatch, CollectDataDispatc try { Thread.sleep(1000); if (metricsCollect != null) { - // 在队列里的优先级增大 metricsCollect.setRunPriority((byte) (metricsCollect.getRunPriority() + 1)); jobRequestQueue.addJob(metricsCollect); } @@ -154,19 +144,18 @@ public class CommonDispatcher implements MetricsTaskDispatch, CollectDataDispatc } } }); - // Monitoring indicator group collection task execution t - // 监控指标组采集任务执行时间 + // Monitoring metrics collection task execution time poolExecutor.execute(() -> { Thread.currentThread().setName("metrics-task-monitor"); while (!Thread.currentThread().isInterrupted()) { try { - // Detect whether the collection unit of each indicator group has timed out for 4 minutes, and if it times out, it will be discarded and an exception will be returned. - // 检测每个指标组采集单元是否超时4分钟,超时则丢弃并返回异常 + // Detect whether the collection unit of each metrics has timed out for 4 minutes, + // and if it times out, it will be discarded and an exception will be returned. long deadline = System.currentTimeMillis() - DURATION_TIME; for (Map.Entry entry : metricsTimeoutMonitorMap.entrySet()) { MetricsTime metricsTime = entry.getValue(); if (metricsTime.getStartTime() < deadline) { - // Metric group collection timeout 指标组采集超时 + // Metrics collection timeout WheelTimerTask timerJob = (WheelTimerTask) metricsTime.getTimeout().task(); CollectRep.MetricsData metricsData = CollectRep.MetricsData.newBuilder() .setId(timerJob.getJob().getMonitorId()) @@ -199,10 +188,8 @@ public class CommonDispatcher implements MetricsTaskDispatch, CollectDataDispatc @Override public void dispatchMetricsTask(Timeout timeout) { - // Divide the collection task of a single application into corresponding collection tasks of the indicator group according to the indicator group under it. AbstractCollect - //Put each indicator group into the thread pool for scheduling - // 将单个应用的采集任务根据其下的指标组拆分为对应的指标组采集任务 AbstractCollect - // 将每个指标组放入线程池进行调度 + // Divide the collection task of a single application into corresponding collection tasks of the metrics according to the metrics under it. + // Put each collect task into the thread pool for scheduling WheelTimerTask timerTask = (WheelTimerTask) timeout.task(); Job job = timerTask.getJob(); job.constructPriorMetrics(); @@ -238,8 +225,7 @@ public class CommonDispatcher implements MetricsTaskDispatch, CollectDataDispatc } Set metricsSet = job.getNextCollectMetrics(metrics, false); if (job.isCyclic()) { - // If it is an asynchronous periodic cyclic task, directly send the collected data of the indicator group to the message middleware - // 若是异步的周期性循环任务,直接发送指标组的采集数据到消息中间件 + // If it is an asynchronous periodic cyclic task, directly response the collected data commonDataQueue.sendMetricsData(metricsData); if (log.isDebugEnabled()) { log.debug("Cyclic Job: {} - {} - {}", job.getMonitorId(), job.getApp(), metricsData.getMetrics()); @@ -249,31 +235,25 @@ public class CommonDispatcher implements MetricsTaskDispatch, CollectDataDispatc } } } - //If metricsSet is null, it means that the execution is completed or whether the priority of the collection indicator group is 0, that is, the availability collection indicator group. - // If the availability collection fails, the next indicator group scheduling will be cancelled and the next round of scheduling will be entered directly. - // 若metricsSet为null表示执行完成 - // 或判断采集指标组是否优先级为0,即为可用性采集指标组 若可用性采集失败 则取消后面的指标组调度直接进入下一轮调度 + // If metricsSet is null, it means that the execution is completed or whether the priority of the collection metrics is 0, that is, the availability collection metrics. + // If the availability collection fails, the next metrics scheduling will be cancelled and the next round of scheduling will be entered directly. boolean isAvailableCollectFailed = metricsSet != null && !metricsSet.isEmpty() && metrics.getPriority() == (byte) 0 && metricsData.getCode() != CollectRep.Code.SUCCESS; if (metricsSet == null || isAvailableCollectFailed) { - // The collection and execution of all index groups of this job are completed. + // The collection and execution task of this job are completed. // The periodic task pushes the task to the time wheel again. // First, determine the execution time of the task and the task collection interval. - // 此Job所有指标组采集执行完成 - // 周期性任务再次将任务push到时间轮 - // 先判断此次任务执行时间与任务采集间隔时间 if (timeout.isCancelled()) { return; } long spendTime = System.currentTimeMillis() - job.getDispatchTime(); long interval = job.getInterval() - spendTime / 1000; interval = interval <= 0 ? 0 : interval; - // Reset Construction Execution Metrics Group View 重置构造执行指标组视图 + // Reset Construction Execution Metrics Task View job.constructPriorMetrics(); timerDispatch.cyclicJob(timerJob, interval, TimeUnit.SECONDS); } else if (!metricsSet.isEmpty()) { - // The execution of the current level indicator group is completed, and the execution of the next level indicator group starts - // 当前级别指标组执行完成,开始执行下一级别的指标组 + // The execution of the current level metrics is completed, and the execution of the next level metrics starts // use pre collect metrics data to replace next metrics config params List> configmapList = getConfigmapFromPreCollectData(metricsData); for (Metrics metricItem : metricsSet) { @@ -306,16 +286,12 @@ public class CommonDispatcher implements MetricsTaskDispatch, CollectDataDispatc } } else { - // The list of indicator groups at the current execution level has not been fully executed. - // It needs to wait for the execution of other indicator groups of the same level to complete the execution and enter the next level for execution. - // 当前执行级别的指标组列表未全执行完成, - // 需等待其它同级别指标组执行完成后进入下一级别执行 + // The list of metrics at the current execution level has not been fully executed. + // It needs to wait for the execution of other metrics task of the same level to complete the execution and enter the next level for execution. } } else { - // If it is a temporary one-time task, you need to wait for the collected data of all indicator groups to be packaged and returned. - // Insert the current indicator group data into the job for unified assembly - // 若是临时性一次任务,需等待所有指标组的采集数据统一包装返回 - // 将当前指标组数据插入job里统一组装 + // If it is a temporary one-time task, you need to wait for the collected data of all metrics task to be packaged and returned. + // Insert the current metrics data into the job for unified assembly job.addCollectMetricsData(metricsData); if (log.isDebugEnabled()) { log.debug("One-time Job: {}", metricsData.getMetrics()); @@ -326,14 +302,11 @@ public class CommonDispatcher implements MetricsTaskDispatch, CollectDataDispatc } } if (metricsSet == null) { - // The collection and execution of all indicator groups of this job are completed - // and the result listener is notified of the combination of all indicator group data - // 此Job所有指标组采集执行完成 - // 将所有指标组数据组合一起通知结果监听器 + // The collection and execution of all metrics of this job are completed + // and the result listener is notified of the combination of all metrics data timerDispatch.responseSyncJobData(job.getId(), job.getResponseDataTemp()); } else if (!metricsSet.isEmpty()) { - // The execution of the current level indicator group is completed, and the execution of the next level indicator group starts - // 当前级别指标组执行完成,开始执行下一级别的指标组 + // The execution of the current level metrics is completed, and the execution of the next level metrics starts metricsSet.forEach(metricItem -> { MetricsCollect metricsCollect = new MetricsCollect(metricItem, timeout, this, collectorIdentity, unitConvertList); @@ -342,10 +315,8 @@ public class CommonDispatcher implements MetricsTaskDispatch, CollectDataDispatc new MetricsTime(System.currentTimeMillis(), metricItem, timeout)); }); } else { - // The list of indicator groups at the current execution level has not been fully executed. - // It needs to wait for the execution of other indicator groups of the same level to complete the execution and enter the next level for execution. - // 当前执行级别的指标组列表未全执行完成, - // 需等待其它同级别指标组执行完成后进入下一级别执行 + // The list of metrics task at the current execution level has not been fully executed. + // It needs to wait for the execution of other metrics task of the same level to complete the execution and enter the next level for execution. } } } @@ -356,27 +327,23 @@ public class CommonDispatcher implements MetricsTaskDispatch, CollectDataDispatc Job job = timerJob.getJob(); metricsTimeoutMonitorMap.remove(String.valueOf(job.getId())); if (job.isCyclic()) { - // If it is an asynchronous periodic cyclic task, directly send the collected data of the indicator group to the message middleware - // 若是异步的周期性循环任务,直接发送指标组的采集数据到消息中间件 + // If it is an asynchronous periodic cyclic task, directly response the collected data metricsDataList.forEach(commonDataQueue::sendMetricsData); - // The collection and execution of all index groups of this job are completed. + // The collection and execution of all task of this job are completed. // The periodic task pushes the task to the time wheel again. // First, determine the execution time of the task and the task collection interval. - // 此Job所有指标组采集执行完成 - // 周期性任务再次将任务push到时间轮 - // 先判断此次任务执行时间与任务采集间隔时间 if (timeout.isCancelled()) { return; } long spendTime = System.currentTimeMillis() - job.getDispatchTime(); long interval = job.getInterval() - spendTime / 1000; interval = interval <= 0 ? 0 : interval; - // Reset Construction Execution Metrics Group View 重置构造执行指标组视图 + // Reset Construction Execution Metrics Task View job.constructPriorMetrics(); timerDispatch.cyclicJob(timerJob, interval, TimeUnit.SECONDS); } else { - // The collection and execution of all indicator groups of this job are completed - // and the result listener is notified of the combination of all indicator group data + // The collection and execution of all metrics of this job are completed + // and the result listener is notified of the combination of all metrics data timerDispatch.responseSyncJobData(job.getId(), metricsDataList); } diff --git a/collector/src/main/java/org/dromara/hertzbeat/collector/dispatch/DispatchConstants.java b/collector/src/main/java/org/dromara/hertzbeat/collector/dispatch/DispatchConstants.java index d05e7c29d5..19ea65a9d6 100644 --- a/collector/src/main/java/org/dromara/hertzbeat/collector/dispatch/DispatchConstants.java +++ b/collector/src/main/java/org/dromara/hertzbeat/collector/dispatch/DispatchConstants.java @@ -18,7 +18,7 @@ package org.dromara.hertzbeat.collector.dispatch; /** - * dispatch constant 常量 + * dispatch constant */ public interface DispatchConstants { @@ -123,7 +123,7 @@ public interface DispatchConstants { */ String PARSE_XML_PATH = "xmlPath"; /** - * Analysis method Website availability monitoring rules Provide responseTime indicators + * Analysis method Website availability monitoring rules Provide responseTime metrics * 解析方式 网站可用性监控规则 提供responseTime指标 */ String PARSE_WEBSITE = "website"; diff --git a/collector/src/main/java/org/dromara/hertzbeat/collector/dispatch/DispatchProperties.java b/collector/src/main/java/org/dromara/hertzbeat/collector/dispatch/DispatchProperties.java index 28552f9193..da9be72047 100644 --- a/collector/src/main/java/org/dromara/hertzbeat/collector/dispatch/DispatchProperties.java +++ b/collector/src/main/java/org/dromara/hertzbeat/collector/dispatch/DispatchProperties.java @@ -22,7 +22,6 @@ import org.springframework.stereotype.Component; /** * Schedule Distribution Task Configuration Properties - * 调度分发任务配置属性 */ @Component @ConfigurationProperties(prefix = "collector.dispatch") @@ -30,13 +29,11 @@ public class DispatchProperties { /** * Scheduling entry configuration properties - * 调度入口配置属性 */ private EntranceProperties entrance; /** * Schedule Data Export Configuration Properties - * 调度数据出口配置属性 */ private ExportProperties export; @@ -58,10 +55,7 @@ public class DispatchProperties { /** * Scheduling entry configuration properties - * The entry can be etcd information, http request, message middleware message request - *

- * 调度入口配置属性 - * 入口可以时etcd信息,http请求,消息中间件消息请求 + * The entry can be netty information, http request, message middleware message request */ public static class EntranceProperties { @@ -69,10 +63,6 @@ public class DispatchProperties { * netty server client config */ private NettyProperties netty; - /** - * etcd配置信息 - */ - private EtcdProperties etcd; public NettyProperties getNetty() { return netty; @@ -82,128 +72,7 @@ public class DispatchProperties { this.netty = netty; } - public EtcdProperties getEtcd() { - return etcd; - } - - public void setEtcd(EtcdProperties etcd) { - this.etcd = etcd; - } - - public static class EtcdProperties { - - /** - * Whether etcd scheduling is started - * etcd调度是否启动 - */ - private boolean enabled = false; - - /** - * etcd's connection endpoint url - * etcd的连接端点url - */ - private String[] endpoints = new String[]{"http://127.0.0.1:2379"}; - - /** - * etcd connection username - * etcd连接用户名 - */ - private String username; - - /** - * etcd connection password - * etcd连接密码 - */ - private String password; - - /** - * Valid time of etcd lease in seconds - * etcd租约的有效时间 单位秒 - */ - private long ttl = 200; - - /** - * Collector registration directory - * 采集器注册目录 - */ - private String collectorDir = "/usthe/dispatch/collector/"; - - /** - * Task scheduling distribution directory - * 任务调度分发目录 - */ - private String assignDir = "/usthe/dispatch/assign/"; - - /** - * task inventory - * 任务详细目录 - */ - private String jobDir = "/usthe/dispatch/job/"; - - public boolean isEnabled() { - return enabled; - } - - public void setEnabled(boolean enabled) { - this.enabled = enabled; - } - - public String[] getEndpoints() { - return endpoints; - } - - public void setEndpoints(String[] endpoints) { - this.endpoints = endpoints; - } - - public String getUsername() { - return username; - } - - public void setUsername(String username) { - this.username = username; - } - - public String getPassword() { - return password; - } - - public void setPassword(String password) { - this.password = password; - } - - public long getTtl() { - return ttl; - } - - public void setTtl(long ttl) { - this.ttl = ttl; - } - - public String getCollectorDir() { - return collectorDir; - } - - public void setCollectorDir(String collectorDir) { - this.collectorDir = collectorDir; - } - - public String getAssignDir() { - return assignDir; - } - - public void setAssignDir(String assignDir) { - this.assignDir = assignDir; - } - - public String getJobDir() { - return jobDir; - } - - public void setJobDir(String jobDir) { - this.jobDir = jobDir; - } - } + public static class NettyProperties { diff --git a/collector/src/main/java/org/dromara/hertzbeat/collector/dispatch/MetricsCollect.java b/collector/src/main/java/org/dromara/hertzbeat/collector/dispatch/MetricsCollect.java index ae62e98123..ef0f35412f 100644 --- a/collector/src/main/java/org/dromara/hertzbeat/collector/dispatch/MetricsCollect.java +++ b/collector/src/main/java/org/dromara/hertzbeat/collector/dispatch/MetricsCollect.java @@ -39,15 +39,13 @@ import java.util.*; import java.util.stream.Collectors; /** - * Index group collection - * 指标组采集 + * metrics collection */ @Slf4j @Data public class MetricsCollect implements Runnable, Comparable { /** * Scheduling alarm threshold time 100ms - * 调度告警阈值时间 100ms */ private static final long WARN_DISPATCH_TIME = 100; /** @@ -60,47 +58,38 @@ public class MetricsCollect implements Runnable, Comparable { protected long tenantId; /** * Monitor ID - * 监控任务ID */ protected long monitorId; /** * Monitoring type name - * 监控类型名称 */ protected String app; /** - * Metric group configuration - * 指标组配置 + * Metrics configuration */ protected Metrics metrics; /** * time wheel timeout - * 时间轮timeout */ protected Timeout timeout; /** * Task and Data Scheduling - * 任务和数据调度 */ protected CollectDataDispatch collectDataDispatch; /** * task execution priority - * 任务执行优先级 */ protected byte runPriority; /** * Periodic collection or one-time collection true-periodic false-one-time - * 是周期性采集还是一次性采集 true-周期性 false-一次性 */ protected boolean isCyclic; /** - * Time for creating an indicator group collection task - * 指标组采集任务新建时间 + * Time for creating collection task */ protected long newTime; /** - * Start time of the index group collection task - * 指标组采集任务开始执行时间 + * Start time of the collection task */ protected long startTime; @@ -123,7 +112,6 @@ public class MetricsCollect implements Runnable, Comparable { this.isCyclic = job.isCyclic(); this.unitConvertList = unitConvertList; // Temporary one-time tasks are executed with high priority - // 临时一次性任务执行优先级高 if (isCyclic) { runPriority = (byte) -1; } else { @@ -148,8 +136,8 @@ public class MetricsCollect implements Runnable, Comparable { return; } response.setMetrics(metrics.getName()); - // According to the indicator group collection protocol, application type, etc., dispatch to the real application indicator group collection implementation class - // 根据指标组采集协议,应用类型等来调度到真正的应用指标组采集实现类 + // According to the metrics collection protocol, application type, etc., + // dispatch to the real application metrics collection implementation class AbstractCollect abstractCollect = CollectStrategyFactory.invoke(metrics.getProtocol()); if (abstractCollect == null) { log.error("[Dispatcher] - not support this: app: {}, metrics: {}, protocol: {}.", @@ -173,7 +161,6 @@ public class MetricsCollect implements Runnable, Comparable { } } // Alias attribute expression replacement calculation - // 别名属性表达式替换计算 if (fastFailed()) { return; } @@ -184,14 +171,10 @@ public class MetricsCollect implements Runnable, Comparable { /** - * Calculate the real indicator (fields) value according to the calculates and aliasFields configuration - * Calculate instance value - *

- * 根据 calculates 和 aliasFields 配置计算出真正的指标(fields)值 - * 计算instance实例值 + * Calculate the real metrics value according to the calculates and aliasFields configuration * - * @param metrics Metric group configuration 指标组配置 - * @param collectData Data collection 采集数据 + * @param metrics Metrics configuration + * @param collectData Data collection */ private void calculateFields(Metrics metrics, CollectRep.MetricsData.Builder collectData) { collectData.setPriority(metrics.getPriority()); @@ -210,11 +193,11 @@ public class MetricsCollect implements Runnable, Comparable { return; } collectData.clearValues(); - // Preprocess calculates first 先预处理 calculates + // Preprocess calculates first if (metrics.getCalculates() == null) { metrics.setCalculates(Collections.emptyList()); } - // eg: database_pages=Database pages unconventional mapping 非常规映射 + // eg: database_pages=Database pages unconventional mapping Map fieldAliasMap = new HashMap<>(8); Map fieldExpressionMap = metrics.getCalculates() .stream() @@ -244,7 +227,6 @@ public class MetricsCollect implements Runnable, Comparable { } } - StringBuilder instanceBuilder = new StringBuilder(); for (Metrics.Field field : fields) { String realField = field.getField(); Expression expression = fieldExpressionMap.get(realField); @@ -252,7 +234,6 @@ public class MetricsCollect implements Runnable, Comparable { String aliasFieldUnit = null; if (expression != null) { // If there is a calculation expression, calculate the value - // 存在计算表达式 则计算值 if (CommonConstants.TYPE_NUMBER == field.getType()) { for (String variable : expression.getVariableFullNames()) { // extract double value and unit from aliasField value @@ -283,7 +264,6 @@ public class MetricsCollect implements Runnable, Comparable { } } else { // does not exist then map the alias value - // 不存在 则映射别名值 String aliasField = fieldAliasMap.get(realField); if (aliasField != null) { value = aliasFieldValueMap.get(aliasField); @@ -306,8 +286,7 @@ public class MetricsCollect implements Runnable, Comparable { } } } - - // 单位处理 + Pair unitPair = fieldUnitMap.get(realField); if (aliasFieldUnit != null) { if (unitPair != null) { @@ -323,8 +302,7 @@ public class MetricsCollect implements Runnable, Comparable { } } } - // Handle indicator values that may have units such as 34%, 34Mb, and limit values to 4 decimal places - // 处理可能带单位的指标数值 比如 34%, 34Mb,并将数值小数点限制到4位 + // Handle metrics values that may have units such as 34%, 34Mb, and limit values to 4 decimal places if (CommonConstants.TYPE_NUMBER == field.getType()) { value = CommonUtil.parseDoubleStr(value, field.getUnit()); } @@ -342,9 +320,9 @@ public class MetricsCollect implements Runnable, Comparable { /** - * @param cal - * @param fieldAliasMap - * @return + * @param cal cal + * @param fieldAliasMap field alias map + * @return expr */ private Object[] transformCal(String cal, Map fieldAliasMap) { int splitIndex = cal.indexOf("="); @@ -363,9 +341,8 @@ public class MetricsCollect implements Runnable, Comparable { /** * transform unit - * - * @param unit - * @return + * @param unit unit + * @return units */ private Object[] transformUnit(String unit) { int equalIndex = unit.indexOf("="); diff --git a/collector/src/main/java/org/dromara/hertzbeat/collector/dispatch/MetricsCollectorQueue.java b/collector/src/main/java/org/dromara/hertzbeat/collector/dispatch/MetricsCollectorQueue.java index 1374acd8ef..063a9dc250 100644 --- a/collector/src/main/java/org/dromara/hertzbeat/collector/dispatch/MetricsCollectorQueue.java +++ b/collector/src/main/java/org/dromara/hertzbeat/collector/dispatch/MetricsCollectorQueue.java @@ -25,7 +25,6 @@ import java.util.concurrent.TimeUnit; /** * queue of jobs to run - * 待运行的job队列 */ @Component @Slf4j diff --git a/collector/src/main/java/org/dromara/hertzbeat/collector/dispatch/MetricsTaskDispatch.java b/collector/src/main/java/org/dromara/hertzbeat/collector/dispatch/MetricsTaskDispatch.java index 0188f68c85..2d1a6514d7 100644 --- a/collector/src/main/java/org/dromara/hertzbeat/collector/dispatch/MetricsTaskDispatch.java +++ b/collector/src/main/java/org/dromara/hertzbeat/collector/dispatch/MetricsTaskDispatch.java @@ -20,14 +20,12 @@ package org.dromara.hertzbeat.collector.dispatch; import org.dromara.hertzbeat.collector.dispatch.timer.Timeout; /** - * Metric group collection task scheduler interface - * 指标组采集任务调度器接口 + * Metrics collection task scheduler interface */ public interface MetricsTaskDispatch { /** - * schedule 调度 - * + * schedule task * @param timeout timeout */ void dispatchMetricsTask(Timeout timeout); diff --git a/collector/src/main/java/org/dromara/hertzbeat/collector/dispatch/WorkerPool.java b/collector/src/main/java/org/dromara/hertzbeat/collector/dispatch/WorkerPool.java index 68e97ca124..0bfd3ae74d 100644 --- a/collector/src/main/java/org/dromara/hertzbeat/collector/dispatch/WorkerPool.java +++ b/collector/src/main/java/org/dromara/hertzbeat/collector/dispatch/WorkerPool.java @@ -30,7 +30,6 @@ import java.util.concurrent.TimeUnit; /** * Collection task worker thread pool - * 采集任务工作线程池 */ @Component @Slf4j @@ -43,7 +42,7 @@ public class WorkerPool implements DisposableBean { } private void initWorkExecutor() { - // thread factory 线程工厂 + // thread factory ThreadFactory threadFactory = new ThreadFactoryBuilder() .setUncaughtExceptionHandler((thread, throwable) -> { log.error("workerExecutor has uncaughtException."); @@ -63,10 +62,9 @@ public class WorkerPool implements DisposableBean { /** * Run the collection task thread - * 运行采集任务线程 * - * @param runnable Task 任务 - * @throws RejectedExecutionException when thread pool full 线程池满 + * @param runnable Task + * @throws RejectedExecutionException when thread pool full */ public void executeJob(Runnable runnable) throws RejectedExecutionException { workerExecutor.execute(runnable); diff --git a/collector/src/main/java/org/dromara/hertzbeat/collector/dispatch/timer/HashedWheelTimer.java b/collector/src/main/java/org/dromara/hertzbeat/collector/dispatch/timer/HashedWheelTimer.java index 0efac3ea74..5f16a6b76e 100644 --- a/collector/src/main/java/org/dromara/hertzbeat/collector/dispatch/timer/HashedWheelTimer.java +++ b/collector/src/main/java/org/dromara/hertzbeat/collector/dispatch/timer/HashedWheelTimer.java @@ -429,7 +429,7 @@ public class HashedWheelTimer implements Timer { // Initialize the startTime. startTime = System.nanoTime(); if (startTime == 0) { - // We use 0 as an indicator for the uninitialized value here, so make sure it's not 0 when initialized. + // We use 0 as an metric for the uninitialized value here, so make sure it's not 0 when initialized. startTime = 1; } diff --git a/collector/src/main/java/org/dromara/hertzbeat/collector/dispatch/timer/TimerDispatch.java b/collector/src/main/java/org/dromara/hertzbeat/collector/dispatch/timer/TimerDispatch.java index a178b47d92..c00922838b 100644 --- a/collector/src/main/java/org/dromara/hertzbeat/collector/dispatch/timer/TimerDispatch.java +++ b/collector/src/main/java/org/dromara/hertzbeat/collector/dispatch/timer/TimerDispatch.java @@ -26,8 +26,7 @@ import java.util.List; import java.util.concurrent.TimeUnit; /** - * 时间轮调度接口 - * + * timer dispatch service * * */ @@ -35,29 +34,24 @@ public interface TimerDispatch { /** * Add new job - * 增加新的job * * @param addJob job - * @param eventListener One-time synchronous task listener, asynchronous task does not need listener一次性同步任务监听器,异步任务不需要listener + * @param eventListener One-time synchronous task listener, asynchronous task does not need listener */ void addJob(Job addJob, CollectResponseEventListener eventListener); /** - * 调度循环周期性job - * + * Cyclic job * @param timerTask timerTask - * @param interval 开始调度的间隔时间 - * @param timeUnit 时间单位 + * @param interval collect interval + * @param timeUnit time unit */ void cyclicJob(WheelTimerTask timerTask, long interval, TimeUnit timeUnit); /** * Delete existing job - * 删除存在的job - * * @param jobId jobId * @param isCyclic Whether it is a periodic task, true is, false is a temporary task - * 是否是周期性任务,true是, false为临时性任务 */ void deleteJob(long jobId, boolean isCyclic); @@ -72,10 +66,9 @@ public interface TimerDispatch { void goOffline(); /** - * 一次性同步采集任务采集结果通知监听器 - * + * response sync collect task data * @param jobId jobId - * @param metricsDataTemps 采集结果数据 + * @param metricsDataTemps collect data */ void responseSyncJobData(long jobId, List metricsDataTemps); } diff --git a/collector/src/main/java/org/dromara/hertzbeat/collector/dispatch/timer/TimerDispatcher.java b/collector/src/main/java/org/dromara/hertzbeat/collector/dispatch/timer/TimerDispatcher.java index 35cf845d5e..af826dad37 100644 --- a/collector/src/main/java/org/dromara/hertzbeat/collector/dispatch/timer/TimerDispatcher.java +++ b/collector/src/main/java/org/dromara/hertzbeat/collector/dispatch/timer/TimerDispatcher.java @@ -40,22 +40,18 @@ public class TimerDispatcher implements TimerDispatch, DisposableBean { /** * time round schedule - * 时间轮调度 */ private final Timer wheelTimer; /** * Existing periodic scheduled tasks - * 已存在的周期性调度任务 */ private final Map currentCyclicTaskMap; /** * Existing temporary scheduled tasks - * 已存在的临时性调度任务 */ private final Map currentTempTaskMap; /** * One-time task response listener holds - * 一次性任务响应监听器持有 * jobId - listener */ private final Map eventListeners; @@ -101,7 +97,7 @@ public class TimerDispatcher implements TimerDispatch, DisposableBean { return; } Long jobId = timerTask.getJob().getId(); - // 判断此周期性job是否已经被取消 + // whether is the job has been canceled if (currentCyclicTaskMap.containsKey(jobId)) { Timeout timeout = wheelTimer.newTimeout(timerTask, interval, TimeUnit.SECONDS); currentCyclicTaskMap.put(timerTask.getJob().getId(), timeout); diff --git a/collector/src/main/java/org/dromara/hertzbeat/collector/dispatch/timer/WheelTimerTask.java b/collector/src/main/java/org/dromara/hertzbeat/collector/dispatch/timer/WheelTimerTask.java index d4e6fa1cd4..14b59ce166 100644 --- a/collector/src/main/java/org/dromara/hertzbeat/collector/dispatch/timer/WheelTimerTask.java +++ b/collector/src/main/java/org/dromara/hertzbeat/collector/dispatch/timer/WheelTimerTask.java @@ -27,7 +27,6 @@ import org.dromara.hertzbeat.common.constants.CommonConstants; import org.dromara.hertzbeat.common.entity.job.Configmap; import org.dromara.hertzbeat.common.entity.job.Job; import org.dromara.hertzbeat.common.entity.job.Metrics; -import org.dromara.hertzbeat.common.entity.job.protocol.PushProtocol; import org.dromara.hertzbeat.common.support.SpringContextHolder; import org.dromara.hertzbeat.common.util.AesUtil; @@ -38,8 +37,6 @@ import java.util.stream.Collectors; /** * Timer Task implementation - * TimerTask实现 - * * */ @Slf4j @@ -53,22 +50,18 @@ public class WheelTimerTask implements TimerTask { this.metricsTaskDispatch = SpringContextHolder.getBean(MetricsTaskDispatch.class); this.job = job; // The initialization job will monitor the actual parameter value and replace the collection field - // 初始化job 将监控实际参数值对采集字段进行替换 initJobMetrics(job); } /** * Initialize job fill information - * 初始化job填充信息 - * * @param job job */ private void initJobMetrics(Job job) { - // 将监控实际参数值对采集字段进行替换 List config = job.getConfigmap(); Map configmap = config.stream() .peek(item -> { - // 对加密串进行解密 + // decode password if (item.getType() == CommonConstants.PARAM_TYPE_PASSWORD && item.getValue() != null) { String decodeValue = AesUtil.aesDecode(String.valueOf(item.getValue())); if (decodeValue == null) { diff --git a/collector/src/main/java/org/dromara/hertzbeat/collector/dispatch/unit/TimeLengthUnit.java b/collector/src/main/java/org/dromara/hertzbeat/collector/dispatch/unit/TimeLengthUnit.java index 12d29a28eb..64e65f038a 100644 --- a/collector/src/main/java/org/dromara/hertzbeat/collector/dispatch/unit/TimeLengthUnit.java +++ b/collector/src/main/java/org/dromara/hertzbeat/collector/dispatch/unit/TimeLengthUnit.java @@ -1,10 +1,7 @@ package org.dromara.hertzbeat.collector.dispatch.unit; -import java.util.concurrent.TimeUnit; - /** * the enum of time length - * 时间长短的枚举类 * * */ diff --git a/collector/src/main/java/org/dromara/hertzbeat/collector/util/CollectUtil.java b/collector/src/main/java/org/dromara/hertzbeat/collector/util/CollectUtil.java index 2e9cfdcadc..c83b8db609 100644 --- a/collector/src/main/java/org/dromara/hertzbeat/collector/util/CollectUtil.java +++ b/collector/src/main/java/org/dromara/hertzbeat/collector/util/CollectUtil.java @@ -33,8 +33,7 @@ import java.util.regex.Matcher; import java.util.regex.Pattern; /** - * 采集器工具类 - * + * util for collector * */ @Slf4j @@ -52,11 +51,11 @@ public class CollectUtil { private static final List UNIT_SYMBOLS = Arrays.asList("%", "G", "g", "M", "m", "K", "k", "B", "b"); /** - * 关键字匹配计数 + * count match keyword number * - * @param content 内容 - * @param keyword 关键字 - * @return 匹配次数 + * @param content content + * @param keyword keyword + * @return match num */ public static int countMatchKeyword(String content, String keyword) { if (content == null || "".equals(content) || keyword == null || "".equals(keyword.trim())) { @@ -194,7 +193,6 @@ public class CollectUtil { /** * json parameter replacement - * json 参数替换 * * @param jsonElement json * @param configmap parameter map @@ -279,7 +277,6 @@ public class CollectUtil { /** * json parameter replacement - * json 参数替换 * * @param jsonElement json * @param configmap parameter map @@ -294,7 +291,6 @@ public class CollectUtil { JsonElement element = entry.getValue(); String key = entry.getKey(); // Replace the attributes of the KEY-VALUE case such as http headers params - // 替换KEY-VALUE情况的属性 比如http headers params if (key != null && key.startsWith(SMILING_PLACEHOLDER) && key.endsWith(SMILING_PLACEHOLDER)) { key = key.replaceAll(SMILING_PLACEHOLDER_REX, ""); Configmap param = configmap.get(key); @@ -315,10 +311,8 @@ public class CollectUtil { continue; } // Replace normal VALUE value - // 替换正常的VALUE值 if (element.isJsonPrimitive()) { // Check if there are special characters Replace - // 判断是否含有特殊字符 替换 String value = element.getAsString(); Matcher smilingMatcher = SMILING_PLACEHOLDER_REGEX_PATTERN.matcher(value); if (smilingMatcher.find()) { @@ -353,7 +347,6 @@ public class CollectUtil { JsonElement element = jsonArray.get(index); if (element.isJsonPrimitive()) { // Check if there are special characters Replace - // 判断是否含有特殊字符 替换 String value = element.getAsString(); Matcher smilingMatcher = SMILING_PLACEHOLDER_REGEX_PATTERN.matcher(value); if (smilingMatcher.find()) { @@ -416,10 +409,10 @@ public class CollectUtil { } /** - * 将16进制字符串转换为byte[] + * convert 16 hexString to byte[] * eg: 302c0201010409636f6d6d756e697479a11c020419e502e7020100020100300e300c06082b060102010102000500 * 16进制字符串不区分大小写,返回的数组相同 - * @param hexString 16进制字符串 + * @param hexString 16 hexString * @return byte[] */ public static byte[] fromHexString(String hexString) { @@ -427,12 +420,9 @@ public class CollectUtil { return null; } byte[] bytes = new byte[hexString.length() / HEX_STR_WIDTH]; - // 16进制字符串 String hex; for (int i = 0; i < hexString.length() / HEX_STR_WIDTH; i++) { - // 每次截取2位 hex = hexString.substring(i * HEX_STR_WIDTH, i * HEX_STR_WIDTH + HEX_STR_WIDTH); - // 16进制 --> 十进制 bytes[i] = (byte) Integer.parseInt(hex, 16); } return bytes; diff --git a/collector/src/main/java/org/dromara/hertzbeat/collector/util/JsonPathParser.java b/collector/src/main/java/org/dromara/hertzbeat/collector/util/JsonPathParser.java index 28baefe777..a9d03bc672 100644 --- a/collector/src/main/java/org/dromara/hertzbeat/collector/util/JsonPathParser.java +++ b/collector/src/main/java/org/dromara/hertzbeat/collector/util/JsonPathParser.java @@ -26,7 +26,6 @@ import java.util.*; /** * json path parser * - * */ public class JsonPathParser { @@ -41,10 +40,10 @@ public class JsonPathParser { } /** - * 使用jsonPath来解析json内容 - * @param content json内容 - * @param jsonPath jsonPath脚本 - * @return 解析后的内容 [{'name': 'tom', 'speed': '433'},{'name': 'lili', 'speed': '543'}] + * use json path to parse content + * @param content json content + * @param jsonPath jsonPath + * @return content [{'name': 'tom', 'speed': '433'},{'name': 'lili', 'speed': '543'}] */ public static List parseContentWithJsonPath(String content, String jsonPath) { if (content == null || jsonPath == null || "".equals(content) || "".equals(jsonPath)) { @@ -54,10 +53,10 @@ public class JsonPathParser { } /** - * 使用jsonPath来解析json内容 - * @param content json内容 - * @param jsonPath jsonPath脚本 - * @return 解析后的内容 [{'name': 'tom', 'speed': '433'},{'name': 'lili', 'speed': '543'}] + * use json path to parse content + * @param content json content + * @param jsonPath jsonPath + * @return content [{'name': 'tom', 'speed': '433'},{'name': 'lili', 'speed': '543'}] */ public static T parseContentWithJsonPath(String content, String jsonPath, TypeRef typeRef) { if (content == null || jsonPath == null || "".equals(content) || "".equals(jsonPath)) { diff --git a/collector/src/main/java/org/dromara/hertzbeat/collector/util/PrivateKeyUtils.java b/collector/src/main/java/org/dromara/hertzbeat/collector/util/PrivateKeyUtils.java index b040b1c7ee..41d81aa627 100644 --- a/collector/src/main/java/org/dromara/hertzbeat/collector/util/PrivateKeyUtils.java +++ b/collector/src/main/java/org/dromara/hertzbeat/collector/util/PrivateKeyUtils.java @@ -9,10 +9,9 @@ import java.nio.file.Paths; import java.util.Objects; /** - * 将私钥写入~/.ssh + * private key util + * write private key to ~/.ssh * - * - * Created by gcdd1993 on 2023/7/9 */ @Slf4j @UtilityClass diff --git a/common/src/main/java/org/dromara/hertzbeat/common/cache/CacheFactory.java b/common/src/main/java/org/dromara/hertzbeat/common/cache/CacheFactory.java index f078d05729..2fc38d1d8f 100644 --- a/common/src/main/java/org/dromara/hertzbeat/common/cache/CacheFactory.java +++ b/common/src/main/java/org/dromara/hertzbeat/common/cache/CacheFactory.java @@ -20,7 +20,7 @@ package org.dromara.hertzbeat.common.cache; import java.time.Duration; /** - * + * common cache factory * */ public class CacheFactory { @@ -36,7 +36,7 @@ public class CacheFactory { new CaffeineCacheServiceImpl<>(10, 1000, Duration.ofDays(1), false); /** - * 获取notice模块的cache + * get notice cache * @return caffeine cache */ public static ICacheService getNoticeCache() { diff --git a/common/src/main/java/org/dromara/hertzbeat/common/cache/CaffeineCacheServiceImpl.java b/common/src/main/java/org/dromara/hertzbeat/common/cache/CaffeineCacheServiceImpl.java index c3c6461765..4bc33a4aba 100644 --- a/common/src/main/java/org/dromara/hertzbeat/common/cache/CaffeineCacheServiceImpl.java +++ b/common/src/main/java/org/dromara/hertzbeat/common/cache/CaffeineCacheServiceImpl.java @@ -23,7 +23,7 @@ import com.github.benmanes.caffeine.cache.Caffeine; import java.time.Duration; /** - * + * caffeine cache impl * */ public class CaffeineCacheServiceImpl implements ICacheService { diff --git a/common/src/main/java/org/dromara/hertzbeat/common/cache/ICacheService.java b/common/src/main/java/org/dromara/hertzbeat/common/cache/ICacheService.java index 0962f4c60b..4c40964020 100644 --- a/common/src/main/java/org/dromara/hertzbeat/common/cache/ICacheService.java +++ b/common/src/main/java/org/dromara/hertzbeat/common/cache/ICacheService.java @@ -18,8 +18,7 @@ package org.dromara.hertzbeat.common.cache; /** - * common cache - * + * common cache service * */ public interface ICacheService { diff --git a/common/src/main/java/org/dromara/hertzbeat/common/config/AviatorConfiguration.java b/common/src/main/java/org/dromara/hertzbeat/common/config/AviatorConfiguration.java index 11852a70f1..4dd01ba7a6 100644 --- a/common/src/main/java/org/dromara/hertzbeat/common/config/AviatorConfiguration.java +++ b/common/src/main/java/org/dromara/hertzbeat/common/config/AviatorConfiguration.java @@ -34,7 +34,7 @@ import java.util.Objects; import java.util.regex.Pattern; /** - * + * aviator config * */ @Configuration diff --git a/common/src/main/java/org/dromara/hertzbeat/common/config/CommonConfig.java b/common/src/main/java/org/dromara/hertzbeat/common/config/CommonConfig.java index 0a2b027207..2ac63f536f 100644 --- a/common/src/main/java/org/dromara/hertzbeat/common/config/CommonConfig.java +++ b/common/src/main/java/org/dromara/hertzbeat/common/config/CommonConfig.java @@ -23,7 +23,7 @@ import org.springframework.context.annotation.ComponentScan; import org.springframework.context.annotation.Configuration; /** - * + * common module config * */ @ComponentScan(basePackages = "org.dromara.hertzbeat.common") diff --git a/common/src/main/java/org/dromara/hertzbeat/common/config/CommonProperties.java b/common/src/main/java/org/dromara/hertzbeat/common/config/CommonProperties.java index e45a4f86fa..9e3eb507c9 100644 --- a/common/src/main/java/org/dromara/hertzbeat/common/config/CommonProperties.java +++ b/common/src/main/java/org/dromara/hertzbeat/common/config/CommonProperties.java @@ -20,8 +20,7 @@ package org.dromara.hertzbeat.common.config; import org.springframework.boot.context.properties.ConfigurationProperties; /** - * common properties - * + * common module properties * * */ diff --git a/common/src/main/java/org/dromara/hertzbeat/common/constants/CollectorConstants.java b/common/src/main/java/org/dromara/hertzbeat/common/constants/CollectorConstants.java index dc6cadff74..0957a73da6 100644 --- a/common/src/main/java/org/dromara/hertzbeat/common/constants/CollectorConstants.java +++ b/common/src/main/java/org/dromara/hertzbeat/common/constants/CollectorConstants.java @@ -18,8 +18,7 @@ package org.dromara.hertzbeat.common.constants; /** - * collector 常量 - * + * collector constant * */ public interface CollectorConstants { @@ -39,7 +38,7 @@ public interface CollectorConstants { String HTTPS_HEADER = "https://"; /** - * POSTGRESQL状态码 不可达 + * POSTGRESQL un reachable status code */ String POSTGRESQL_UN_REACHABLE_CODE = "08001"; diff --git a/common/src/main/java/org/dromara/hertzbeat/common/constants/CommonConstants.java b/common/src/main/java/org/dromara/hertzbeat/common/constants/CommonConstants.java index 6a3f4ab4dc..06459aca48 100644 --- a/common/src/main/java/org/dromara/hertzbeat/common/constants/CommonConstants.java +++ b/common/src/main/java/org/dromara/hertzbeat/common/constants/CommonConstants.java @@ -18,8 +18,7 @@ package org.dromara.hertzbeat.common.constants; /** - * Public Constant - * + * Public Common Constant * */ public interface CommonConstants { @@ -158,7 +157,7 @@ public interface CommonConstants { byte TYPE_TIME = 3; /** - * Collection indicator value: null placeholder for empty value + * Collection metric value: null placeholder for empty value * 采集指标值:null空值占位符 */ String NULL_VALUE = " "; diff --git a/common/src/main/java/org/dromara/hertzbeat/common/constants/SignConstants.java b/common/src/main/java/org/dromara/hertzbeat/common/constants/SignConstants.java index f4d6248fa9..6f35a7757c 100644 --- a/common/src/main/java/org/dromara/hertzbeat/common/constants/SignConstants.java +++ b/common/src/main/java/org/dromara/hertzbeat/common/constants/SignConstants.java @@ -1,8 +1,7 @@ package org.dromara.hertzbeat.common.constants; /** - * 特殊字符常量 - * + * Sign Constants * */ public interface SignConstants { @@ -17,5 +16,4 @@ public interface SignConstants { String CARRIAGE_RETURN = "\r"; String RIGHT_DASH = "/"; - } diff --git a/common/src/main/java/org/dromara/hertzbeat/common/entity/alerter/Alert.java b/common/src/main/java/org/dromara/hertzbeat/common/entity/alerter/Alert.java index 72364858f7..74bee780ef 100644 --- a/common/src/main/java/org/dromara/hertzbeat/common/entity/alerter/Alert.java +++ b/common/src/main/java/org/dromara/hertzbeat/common/entity/alerter/Alert.java @@ -41,9 +41,7 @@ import static io.swagger.v3.oas.annotations.media.Schema.AccessMode.READ_ONLY; import static io.swagger.v3.oas.annotations.media.Schema.AccessMode.READ_WRITE; /** - * Alarm record entity 告警记录实体 - * - * + * Alarm record entity * */ @Entity @@ -74,8 +72,7 @@ public class Alert { example = "8743267443543", accessMode = READ_WRITE) private Long alertDefineId; - @Schema(title = "Alarm level 0: high-emergency-critical alarm-red 1: medium-critical-critical alarm-orange 2: low-warning-warning alarm-yellow", - description = "告警级别 0:高-emergency-紧急告警-红色 1:中-critical-严重告警-橙色 2:低-warning-警告告警-黄色", + @Schema(title = "Alarm level 0:High-Emergency-Critical Alarm 1:Medium-Critical-Critical Alarm 2:Low-Warning-Warning", example = "1", accessMode = READ_WRITE) @Min(0) @Max(2) @@ -122,11 +119,11 @@ public class Alert { @Column(length = 2048) private Map tags; - @Schema(title = "此条记录创建者", example = "tom", accessMode = READ_ONLY) + @Schema(title = "The creator of this record", example = "tom", accessMode = READ_ONLY) @CreatedBy private String creator; - @Schema(title = "此条记录最新修改者", example = "tom", accessMode = READ_ONLY) + @Schema(title = "The modifier of this record", example = "tom", accessMode = READ_ONLY) @LastModifiedBy private String modifier; @@ -136,7 +133,7 @@ public class Alert { @CreatedDate private LocalDateTime gmtCreate; - @Schema(title = "记录最新修改时间", example = "1612198444000", accessMode = READ_ONLY) + @Schema(title = "Record modify time", example = "1612198444000", accessMode = READ_ONLY) @LastModifiedDate private LocalDateTime gmtUpdate; diff --git a/common/src/main/java/org/dromara/hertzbeat/common/entity/alerter/AlertConverge.java b/common/src/main/java/org/dromara/hertzbeat/common/entity/alerter/AlertConverge.java index a1ba9201db..f5edf0ae78 100644 --- a/common/src/main/java/org/dromara/hertzbeat/common/entity/alerter/AlertConverge.java +++ b/common/src/main/java/org/dromara/hertzbeat/common/entity/alerter/AlertConverge.java @@ -43,8 +43,6 @@ import static io.swagger.v3.oas.annotations.media.Schema.AccessMode.READ_WRITE; /** * Alert Converge strategy entity - * 告警收敛策略 - * * */ @Entity @@ -78,7 +76,7 @@ public class AlertConverge { example = "true", accessMode = READ_WRITE) private boolean matchAll = true; - @Schema(title = "匹配告警级别,空为全部告警级别 0:高-emergency-紧急告警-红色 1:中-critical-严重告警-橙色 2:低-warning-警告告警-黄色", + @Schema(title = "Alarm Level 0:High-Emergency-Critical Alarm 1:Medium-Critical-Critical Alarm 2:Low-Warning-Warning", example = "[1]", accessMode = READ_WRITE) @Convert(converter = JsonByteListAttributeConverter.class) private List priorities; @@ -93,23 +91,19 @@ public class AlertConverge { @Min(0) private Integer evalInterval; - @Schema(title = "The creator of this record", description = "此条记录创建者", example = "tom", accessMode = READ_ONLY) + @Schema(title = "The creator of this record", example = "tom", accessMode = READ_ONLY) @CreatedBy private String creator; - @Schema(title = "This record was last modified by", - description = "此条记录最新修改者", - example = "tom", accessMode = READ_ONLY) + @Schema(title = "This record was last modified by", example = "tom", accessMode = READ_ONLY) @LastModifiedBy private String modifier; - @Schema(title = "This record creation time (millisecond timestamp)", - description = "记录创建时间", accessMode = READ_ONLY) + @Schema(title = "This record creation time (millisecond timestamp)", accessMode = READ_ONLY) @CreatedDate private LocalDateTime gmtCreate; - @Schema(title = "Record the latest modification time (timestamp in milliseconds)", - description = "记录最新修改时间", accessMode = READ_ONLY) + @Schema(title = "Record the latest modification time (timestamp in milliseconds)", accessMode = READ_ONLY) @LastModifiedDate private LocalDateTime gmtUpdate; } diff --git a/common/src/main/java/org/dromara/hertzbeat/common/entity/alerter/AlertDefine.java b/common/src/main/java/org/dromara/hertzbeat/common/entity/alerter/AlertDefine.java index 3484c37314..eaaa78ab31 100644 --- a/common/src/main/java/org/dromara/hertzbeat/common/entity/alerter/AlertDefine.java +++ b/common/src/main/java/org/dromara/hertzbeat/common/entity/alerter/AlertDefine.java @@ -45,8 +45,7 @@ import static io.swagger.v3.oas.annotations.media.Schema.AccessMode.READ_WRITE; /** - * 告警定义实体 - * + * Alarm Define Rule Entity * */ @Entity @@ -55,80 +54,80 @@ import static io.swagger.v3.oas.annotations.media.Schema.AccessMode.READ_WRITE; @Builder @AllArgsConstructor @NoArgsConstructor -@Schema(description = "Alert Define | 告警定义实体") +@Schema(description = "Alarm Threshold Entity | 告警阈值实体") @EntityListeners(AuditingEntityListener.class) public class AlertDefine { @Id @GeneratedValue(strategy = GenerationType.IDENTITY) - @Schema(title = "告警定义实体主键索引ID", example = "87584674384", accessMode = READ_ONLY) + @Schema(title = "Threshold Id", example = "87584674384", accessMode = READ_ONLY) private Long id; - @Schema(title = "配置告警的监控类型", example = "linux", accessMode = READ_WRITE) + @Schema(title = "Monitoring Type", example = "linux", accessMode = READ_WRITE) @Length(max = 100) @NotNull private String app; - @Schema(title = "配置告警的指标集合", example = "cpu", accessMode = READ_WRITE) + @Schema(title = "Monitoring Metrics", example = "cpu", accessMode = READ_WRITE) @Length(max = 100) @NotNull private String metric; - @Schema(title = "配置告警的指标", example = "usage", accessMode = READ_WRITE) + @Schema(title = "Monitoring Metrics Field", example = "usage", accessMode = READ_WRITE) @Length(max = 100) private String field; - @Schema(title = "是否是全局默认告警", example = "false", accessMode = READ_WRITE) + @Schema(title = "Is Apply All Default | 是否是全局默认告警", example = "false", accessMode = READ_WRITE) private boolean preset; - @Schema(title = "告警阈值触发条件表达式", example = "usage>90", accessMode = READ_WRITE) + @Schema(title = "Alarm Threshold Expr | 告警阈值触发条件表达式", example = "usage>90", accessMode = READ_WRITE) @Length(max = 2048) @Column(length = 2048) private String expr; - @Schema(title = "告警级别 0:高-emergency-紧急告警-红色 1:中-critical-严重告警-橙色 2:低-warning-警告告警-黄色", + @Schema(title = "Alarm Level 0:High-Emergency-Critical Alarm 1:Medium-Critical-Critical Alarm 2:Low-Warning-Warning", example = "1", accessMode = READ_WRITE) @Min(0) @Max(2) private byte priority; - @Schema(title = "阈值触发次数,即达到次数要求后才触发告警", example = "3", accessMode = READ_WRITE) + @Schema(title = "Alarm Trigger Times | 阈值触发次数,即达到次数要求后才触发告警", example = "3", accessMode = READ_WRITE) @Min(0) @Max(10) private Integer times; - @Schema(description = "附加告警标签(status:success,env:prod)", example = "{name: key1, value: value1}", + @Schema(description = "Tags(status:success,env:prod)", example = "{name: key1, value: value1}", accessMode = READ_WRITE) @Convert(converter = JsonTagListAttributeConverter.class) @Column(length = 2048) private List tags; - @Schema(title = "告警阈值开关", example = "true", accessMode = READ_WRITE) + @Schema(title = "Is Enable", example = "true", accessMode = READ_WRITE) private boolean enable = true; - @Schema(title = "Is send alarm recover notice | 是否发送告警恢复通知", example = "false", accessMode = READ_WRITE) + @Schema(title = "Is Send Alarm Recover Notice | 是否发送告警恢复通知", example = "false", accessMode = READ_WRITE) @Column(columnDefinition = "boolean default false") private boolean recoverNotice = false; - @Schema(title = "告警通知内容模版", example = "linux {monitor_name}: {monitor_id} cpu usage high", + @Schema(title = "Alarm Template | 告警通知内容模版", example = "linux {monitor_name}: {monitor_id} cpu usage high", accessMode = READ_WRITE) @Length(max = 2048) @Column(length = 2048) private String template; - @Schema(title = "此条记录创建者", example = "tom", accessMode = READ_ONLY) + @Schema(title = "The creator of this record", example = "tom", accessMode = READ_ONLY) @CreatedBy private String creator; - @Schema(title = "此条记录最新修改者", example = "tom", accessMode = READ_ONLY) + @Schema(title = "The modifier of this record", example = "tom", accessMode = READ_ONLY) @LastModifiedBy private String modifier; - @Schema(title = "记录创建时间", example = "1612198922000", accessMode = READ_ONLY) + @Schema(title = "Record create time", example = "1612198922000", accessMode = READ_ONLY) @CreatedDate private LocalDateTime gmtCreate; - @Schema(title = "记录最新修改时间", example = "1612198444000", accessMode = READ_ONLY) + @Schema(title = "Record modify time", example = "1612198444000", accessMode = READ_ONLY) @LastModifiedDate private LocalDateTime gmtUpdate; diff --git a/common/src/main/java/org/dromara/hertzbeat/common/entity/alerter/AlertDefineMonitorBind.java b/common/src/main/java/org/dromara/hertzbeat/common/entity/alerter/AlertDefineMonitorBind.java index 4b614fa733..89eb928b9b 100644 --- a/common/src/main/java/org/dromara/hertzbeat/common/entity/alerter/AlertDefineMonitorBind.java +++ b/common/src/main/java/org/dromara/hertzbeat/common/entity/alerter/AlertDefineMonitorBind.java @@ -37,8 +37,7 @@ import static io.swagger.v3.oas.annotations.media.Schema.AccessMode.READ_WRITE; /** - * 告警定义与监控关联实体 - * + * Alarm Threshold Relate Monitor Entity * */ @Entity @@ -50,27 +49,27 @@ import static io.swagger.v3.oas.annotations.media.Schema.AccessMode.READ_WRITE; @Builder @AllArgsConstructor @NoArgsConstructor -@Schema(description = "告警定义与监控关联实体") +@Schema(description = "Alarm Threshold Relate Monitor Entity") @EntityListeners(AuditingEntityListener.class) public class AlertDefineMonitorBind { @Id @GeneratedValue(strategy = GenerationType.IDENTITY) - @Schema(title = "告警定义与监控关联主键索引ID", example = "74384", accessMode = READ_ONLY) + @Schema(title = "id", example = "74384", accessMode = READ_ONLY) private Long id; - @Schema(title = "告警定义ID", example = "87432674384", accessMode = READ_WRITE) + @Schema(title = "Alarm Define Id", example = "87432674384", accessMode = READ_WRITE) private Long alertDefineId; - @Schema(title = "监控任务ID", example = "87432674336", accessMode = READ_WRITE) + @Schema(title = "Monitor Id", example = "87432674336", accessMode = READ_WRITE) @Column(name = "monitor_id") private Long monitorId; - @Schema(title = "记录创建时间", example = "1612198922000", accessMode = READ_ONLY) + @Schema(title = "Record create time", example = "1612198922000", accessMode = READ_ONLY) @CreatedDate private LocalDateTime gmtCreate; - @Schema(title = "记录最新修改时间", example = "1612198444000", accessMode = READ_ONLY) + @Schema(title = "Record modify time", example = "1612198444000", accessMode = READ_ONLY) @LastModifiedDate private LocalDateTime gmtUpdate; diff --git a/common/src/main/java/org/dromara/hertzbeat/common/entity/alerter/AlertSilence.java b/common/src/main/java/org/dromara/hertzbeat/common/entity/alerter/AlertSilence.java index 2153c14679..e573865aee 100644 --- a/common/src/main/java/org/dromara/hertzbeat/common/entity/alerter/AlertSilence.java +++ b/common/src/main/java/org/dromara/hertzbeat/common/entity/alerter/AlertSilence.java @@ -43,8 +43,6 @@ import static io.swagger.v3.oas.annotations.media.Schema.AccessMode.READ_WRITE; /** * Alert Silence strategy entity - * 告警静默策略 - * * */ @Entity @@ -90,7 +88,7 @@ public class AlertSilence { description = "已静默告警次数", accessMode = READ_WRITE) private Integer times; - @Schema(title = "匹配告警级别,空为全部告警级别 0:高-emergency-紧急告警-红色 1:中-critical-严重告警-橙色 2:低-warning-警告告警-黄色", + @Schema(title = "Alarm Level 0:High-Emergency-Critical Alarm 1:Medium-Critical-Critical Alarm 2:Low-Warning-Warning", example = "[1]", accessMode = READ_WRITE) @Convert(converter = JsonByteListAttributeConverter.class) private List priorities; @@ -111,23 +109,19 @@ public class AlertSilence { @Schema(title = "限制时间段截止", example = "23:59:59", accessMode = READ_WRITE) private ZonedDateTime periodEnd; - @Schema(title = "The creator of this record", description = "此条记录创建者", example = "tom", accessMode = READ_ONLY) + @Schema(title = "The creator of this record", example = "tom", accessMode = READ_ONLY) @CreatedBy private String creator; - @Schema(title = "This record was last modified by", - description = "此条记录最新修改者", - example = "tom", accessMode = READ_ONLY) + @Schema(title = "This record was last modified by", example = "tom", accessMode = READ_ONLY) @LastModifiedBy private String modifier; - @Schema(title = "This record creation time (millisecond timestamp)", - description = "记录创建时间", accessMode = READ_ONLY) + @Schema(title = "This record creation time (millisecond timestamp)", accessMode = READ_ONLY) @CreatedDate private LocalDateTime gmtCreate; - @Schema(title = "Record the latest modification time (timestamp in milliseconds)", - description = "记录最新修改时间", accessMode = READ_ONLY) + @Schema(title = "Record the latest modification time (timestamp in milliseconds)", accessMode = READ_ONLY) @LastModifiedDate private LocalDateTime gmtUpdate; } diff --git a/common/src/main/java/org/dromara/hertzbeat/common/entity/alerter/JsonMapAttributeConverter.java b/common/src/main/java/org/dromara/hertzbeat/common/entity/alerter/JsonMapAttributeConverter.java index e903903169..63b099cf03 100644 --- a/common/src/main/java/org/dromara/hertzbeat/common/entity/alerter/JsonMapAttributeConverter.java +++ b/common/src/main/java/org/dromara/hertzbeat/common/entity/alerter/JsonMapAttributeConverter.java @@ -24,8 +24,7 @@ import javax.persistence.AttributeConverter; import java.util.Map; /** - * json 互转map对象字段为数据String字段 - * + * json map converter * */ public class JsonMapAttributeConverter implements AttributeConverter, String> { diff --git a/common/src/main/java/org/dromara/hertzbeat/common/entity/dto/AlertReport.java b/common/src/main/java/org/dromara/hertzbeat/common/entity/dto/AlertReport.java index c4c81c1774..593149fbbb 100644 --- a/common/src/main/java/org/dromara/hertzbeat/common/entity/dto/AlertReport.java +++ b/common/src/main/java/org/dromara/hertzbeat/common/entity/dto/AlertReport.java @@ -29,15 +29,14 @@ import static io.swagger.v3.oas.annotations.media.Schema.AccessMode.READ_WRITE; /** - * 告警 对外上报实体类 - * + * Alarm Report Content Entity * */ @Data @Builder @AllArgsConstructor @NoArgsConstructor -@Schema(description = "告警对外上报字段") +@Schema(description = "Alarm Report Content Entity") public class AlertReport { @Schema(title = "Alert record saas index ID") diff --git a/common/src/main/java/org/dromara/hertzbeat/common/entity/dto/Field.java b/common/src/main/java/org/dromara/hertzbeat/common/entity/dto/Field.java index 17d6284ee4..afaad82ddd 100644 --- a/common/src/main/java/org/dromara/hertzbeat/common/entity/dto/Field.java +++ b/common/src/main/java/org/dromara/hertzbeat/common/entity/dto/Field.java @@ -24,30 +24,26 @@ import lombok.Data; import lombok.NoArgsConstructor; /** - * 监控指标组指标字段 - * + * monitoring metrics field * */ @Data @Builder @AllArgsConstructor @NoArgsConstructor -@Schema(description = "监控指标组指标字段") +@Schema(description = "Monitoring Metrics Field") public class Field { - @Schema(title = "指标采集字符名称") + @Schema(title = "Metrics Field Name") private String name; - @Schema(title = "字段类型:0-number数字 1-string字符串") + @Schema(title = "Field Type:0-number 1-string") private Byte type; - @Schema(title = "指标单位") + @Schema(title = "Field Unit") private String unit; - - @Schema(title = "是否是实例字段") - private Boolean instance; - @Schema(title = "是否是标签字段") + @Schema(title = "Whether is a label") private Boolean label; } diff --git a/common/src/main/java/org/dromara/hertzbeat/common/entity/dto/Message.java b/common/src/main/java/org/dromara/hertzbeat/common/entity/dto/Message.java index ade14bebcc..32de62be5c 100644 --- a/common/src/main/java/org/dromara/hertzbeat/common/entity/dto/Message.java +++ b/common/src/main/java/org/dromara/hertzbeat/common/entity/dto/Message.java @@ -34,25 +34,25 @@ import static org.dromara.hertzbeat.common.constants.CommonConstants.SUCCESS_COD * */ @Data -@Schema(description = "公共消息包装") +@Schema(description = "Common message structure") public class Message { /** * message body data */ - @Schema(description = "响应数据") + @Schema(description = "Response Data") private T data; /** * exception message when error happen or success message */ - @Schema(title = "携带消息") + @Schema(title = "Other Message") private String msg; /** * response code, not http code */ - @Schema(title = "携带编码") + @Schema(title = "Response Code") private byte code = SUCCESS_CODE; public static Message success() { @@ -90,4 +90,4 @@ public class Message { private Message(T data) { this.data = data; } -} \ No newline at end of file +} diff --git a/common/src/main/java/org/dromara/hertzbeat/common/entity/dto/MetricsData.java b/common/src/main/java/org/dromara/hertzbeat/common/entity/dto/MetricsData.java index 3ef866ec50..3cd7cc34e8 100644 --- a/common/src/main/java/org/dromara/hertzbeat/common/entity/dto/MetricsData.java +++ b/common/src/main/java/org/dromara/hertzbeat/common/entity/dto/MetricsData.java @@ -26,32 +26,31 @@ import lombok.NoArgsConstructor; import java.util.List; /** - * 指标组监控数据 - * + * Monitoring Metrics Data * */ @Data @Builder @AllArgsConstructor @NoArgsConstructor -@Schema(description = "指标组监控数据") +@Schema(description = "Monitoring Metrics Data") public class MetricsData { - @Schema(title = "监控任务ID") + @Schema(title = "Monitoring Task ID") private Long id; - @Schema(title = "监控类型") + @Schema(title = "Monitoring Type") private String app; - @Schema(title = "监控指标组") - private String metric; + @Schema(title = "Monitoring Metrics") + private String metrics; - @Schema(title = "最新采集时间") + @Schema(title = "Latest Collect Time") private Long time; - @Schema(description = "监控指标字段列表") + @Schema(description = "Monitoring Metrics fields") private List fields; - @Schema(description = "监控指标列表值集合") + @Schema(description = "Monitoring Metrics DataRow") private List valueRows; } diff --git a/common/src/main/java/org/dromara/hertzbeat/common/entity/dto/MetricsHistoryData.java b/common/src/main/java/org/dromara/hertzbeat/common/entity/dto/MetricsHistoryData.java index 0ddc9cde81..a3e5ec8514 100644 --- a/common/src/main/java/org/dromara/hertzbeat/common/entity/dto/MetricsHistoryData.java +++ b/common/src/main/java/org/dromara/hertzbeat/common/entity/dto/MetricsHistoryData.java @@ -27,29 +27,28 @@ import java.util.List; import java.util.Map; /** - * 历史单指标数据 - * + * Metric History Range Query Data * */ @Data @Builder @AllArgsConstructor @NoArgsConstructor -@Schema(description = "历史单指标数据") +@Schema(description = "Metric History Range Query Data") public class MetricsHistoryData { - @Schema(title = "监控任务ID") + @Schema(title = "Monitoring Task ID") private Long id; - @Schema(title = "监控类型") + @Schema(title = "Monitoring Type") private String app; - @Schema(title = "监控指标组") - private String metric; + @Schema(title = "Monitoring Metrics") + private String metrics; - @Schema(title = "监控指标") + @Schema(title = "Monitoring Metrics Field") private Field field; - @Schema(description = "监控指标历史值 instance<==>values") + @Schema(description = "Monitoring Range Query Data tags<==>values") private Map> values; } diff --git a/common/src/main/java/org/dromara/hertzbeat/common/entity/dto/PromVectorOrMatrix.java b/common/src/main/java/org/dromara/hertzbeat/common/entity/dto/PromVectorOrMatrix.java index a30d56d280..a8ba2fec23 100644 --- a/common/src/main/java/org/dromara/hertzbeat/common/entity/dto/PromVectorOrMatrix.java +++ b/common/src/main/java/org/dromara/hertzbeat/common/entity/dto/PromVectorOrMatrix.java @@ -17,7 +17,6 @@ import java.io.IOException; import java.util.List; /** - * * */ @Data diff --git a/common/src/main/java/org/dromara/hertzbeat/common/entity/dto/Value.java b/common/src/main/java/org/dromara/hertzbeat/common/entity/dto/Value.java index 4617e13e70..75731c5a6f 100644 --- a/common/src/main/java/org/dromara/hertzbeat/common/entity/dto/Value.java +++ b/common/src/main/java/org/dromara/hertzbeat/common/entity/dto/Value.java @@ -24,15 +24,14 @@ import lombok.Data; import lombok.NoArgsConstructor; /** - * 监控指标组指标值 - * + * Monitoring Metrics Data * */ @Data @Builder @AllArgsConstructor @NoArgsConstructor -@Schema(description = "监控指标组指标值") +@Schema(description = "Monitoring Metrics Data") public class Value { public Value(String origin) { @@ -44,21 +43,21 @@ public class Value { this.time = time; } - @Schema(title = "原始值") + @Schema(title = "Origin Value") private String origin; - @Schema(title = "平均值") + @Schema(title = "Mean Avg Value") private String mean; - @Schema(title = "中位数值,暂不支持") + @Schema(title = "Median Value, Not Support Now") private String median; - @Schema(title = "最小值") + @Schema(title = "Min Value") private String min; - @Schema(title = "最大值") + @Schema(title = "Max Value") private String max; - @Schema(title = "数据采集时间,此字段查历史数据时有效") + @Schema(title = "Collect Data Time(effect when history range data)") private Long time; } diff --git a/common/src/main/java/org/dromara/hertzbeat/common/entity/dto/ValueRow.java b/common/src/main/java/org/dromara/hertzbeat/common/entity/dto/ValueRow.java index 135c3d5a9c..95fa7b5b10 100644 --- a/common/src/main/java/org/dromara/hertzbeat/common/entity/dto/ValueRow.java +++ b/common/src/main/java/org/dromara/hertzbeat/common/entity/dto/ValueRow.java @@ -27,7 +27,7 @@ import java.util.List; import java.util.Map; /** - * 监控指标集合的一行指标数据 + * Monitoring Metrics DataRow * * */ @@ -35,12 +35,12 @@ import java.util.Map; @Builder @AllArgsConstructor @NoArgsConstructor -@Schema(description = "监控指标集合的一行指标数据") +@Schema(description = "Monitoring Metrics DataRow") public class ValueRow { @Schema(title = "Value Row Labels") private Map labels; - @Schema(description = "监控指标集合指标值") + @Schema(description = "Monitoring Metrics DataRow") private List values; } diff --git a/common/src/main/java/org/dromara/hertzbeat/common/entity/job/Configmap.java b/common/src/main/java/org/dromara/hertzbeat/common/entity/job/Configmap.java index 4938537044..08f415e20f 100644 --- a/common/src/main/java/org/dromara/hertzbeat/common/entity/job/Configmap.java +++ b/common/src/main/java/org/dromara/hertzbeat/common/entity/job/Configmap.java @@ -24,12 +24,8 @@ import lombok.NoArgsConstructor; /** * Monitoring configuration parameter properties and values - * 监控配置参数属性及值 * During the process, you need to replace the content with the identifier ^_^key^_^ * in the protocol configuration parameter with the real value in the configuration parameter - * 过程中需要将协议配置参数里面的标识符为^_^key^_^的内容替换为配置参数里的真实值 - * - * * */ @Data diff --git a/common/src/main/java/org/dromara/hertzbeat/common/entity/job/Job.java b/common/src/main/java/org/dromara/hertzbeat/common/entity/job/Job.java index 9d5f5c7740..8567527d87 100644 --- a/common/src/main/java/org/dromara/hertzbeat/common/entity/job/Job.java +++ b/common/src/main/java/org/dromara/hertzbeat/common/entity/job/Job.java @@ -33,8 +33,6 @@ import java.util.stream.Collectors; /** * Collect task details - * 采集任务详情 - * * */ @Data @@ -45,7 +43,7 @@ import java.util.stream.Collectors; public class Job { /** - * Task id 采集任务ID + * Task Job id */ private long id; /** @@ -53,23 +51,20 @@ public class Job { */ private long tenantId = 0; /** - * Monitoring ID Application ID - * 监控任务ID 应用ID + * Monitoring Task ID */ private long monitorId; /** - * Large categories of monitoring 监控的大类别 - * service-application service monitoring db-database monitoring custom-custom monitoring os-operating system monitoring - * service-应用服务 program-应用程序 db-数据库 custom-自定义 os-操作系统 bigdata-大数据 mid-中间件 webserver-web服务器 cache-缓存 cn-云原生 network-网络监控等等 os-操作系统监控 + * Large categories of monitoring + * service-application service monitoring db-database monitoring custom-custom monitoring os-operating system monitoring... */ private String category; /** * Type of monitoring eg: linux | mysql | jvm - * 监控的类型 eg: linux | mysql | jvm */ private String app; /** - * The internationalized name of the monitoring type 监控类型的国际化名称 + * The internationalized name of the monitoring type * zh-CN: PING连通性 * en-US: PING CONNECT */ @@ -104,8 +99,8 @@ public class Job { */ private List params; /** - * Indicator group configuration eg: cpu memory - * 指标组配置 eg: cpu memory + * Metrics configuration eg: cpu memory + * eg: cpu memory */ private List metrics; /** @@ -116,20 +111,13 @@ public class Job { /** * collector use - timestamp when the task was scheduled by the time wheel - * collector使用 - 任务被时间轮开始调度的时间戳 + * 任务被时间轮开始调度的时间戳 */ @JsonIgnore private transient long dispatchTime; - - /** - * collector use - task version, this field is not stored in etcd - * collector使用 - 任务版本,此字段不存储于etcd - */ - @JsonIgnore - private transient long version; + /** * collector usage - metric group task execution priority view - * collector使用 - 指标组任务执行优先级视图 * 0 - availability * 1 - cpu | memory * 2 - health @@ -142,15 +130,15 @@ public class Job { private transient LinkedList> priorMetrics; /** - * collector use - Temporarily store one-time task indicator group response data - * collector使用 - 临时存储一次性任务指标组响应数据 + * collector use - Temporarily store one-time task metrics response data + * collector使用 - 临时存储一次性任务响应数据 */ @JsonIgnore private transient List responseDataTemp; /** - * collector uses - construct to initialize metrics group execution view - * collector使用 - 构造初始化指标组执行视图 + * collector use - construct to initialize metrics execution view + * collector使用 - 构造初始化指标执行视图 */ public synchronized void constructPriorMetrics() { Map> map = metrics.stream() @@ -160,15 +148,15 @@ public class Job { if ((metric.getAliasFields() == null || metric.getAliasFields().isEmpty()) && metric.getFields() != null) { metric.setAliasFields(metric.getFields().stream().map(Metrics.Field::getField).collect(Collectors.toList())); } - // Set the default indicator group execution priority, if not filled, the default last priority - // 设置默认的指标组执行优先级,不填则默认最后优先级 + // Set the default metrics execution priority, if not filled, the default last priority + // 设置默认执行优先级,不填则默认最后优先级 if (metric.getPriority() == null) { metric.setPriority(Byte.MAX_VALUE); } }) .collect(Collectors.groupingBy(Metrics::getPriority)); - // Construct a linked list of task execution order of the indicator group - // 构造指标组任务执行顺序链表 + // Construct a linked list of task execution order of the metrics + // 构造采集任务执行顺序链表 priorMetrics = new LinkedList<>(); map.values().forEach(metric -> { Set metricsSet = Collections.synchronizedSet(new HashSet<>(metric)); @@ -186,18 +174,18 @@ public class Job { /** * collector use - to get the next set of priority metric group tasks - * collector使用 - 获取下一组优先级的指标组任务 + * collector使用 - 获取下一组优先级的采集任务 * - * @param metrics Current indicator group 当前指标组 - * @param first Is it the first time to get 是否是第一次获取 - * @return Metric Group Tasks 指标组任务 - * Returning null means: the job has been completed, and the collection of all indicator groups has ended - * 返回null表示:job已完成,所有指标组采集结束 - * Returning the empty set indicates that there are still indicator group collection tasks at the current - * level that have not been completed,and the next level indicator group task collection cannot be performed. - * 返回empty的集合表示:当前级别下还有指标组采集任务未结束,无法进行下一级别的指标组任务采集 - * Returns a set of data representation: get the next set of priority index group tasks - * 返回有数据集合表示:获取到下一组优先级的指标组任务 + * @param metrics Current Metrics + * @param first Is it the first time to get + * @return Metrics Tasks + * Returning null means: the job has been completed, and the collection of all metrics has ended + * 返回null表示:job已完成,所有采集任务结束 + * Returning the empty set metrics that there are still metrics collection tasks at the current + * level that have not been completed,and the next level metrics task collection cannot be performed. + * 返回empty的集合表示:当前级别下还有指标采集任务未结束,无法进行下一级别的任务采集 + * Returns a set of data representation: get the next set of priority index collcet tasks + * 返回有数据集合表示:获取到下一组优先级的采集任务 */ public synchronized Set getNextCollectMetrics(Metrics metrics, boolean first) { if (priorMetrics == null || priorMetrics.isEmpty()) { diff --git a/common/src/main/java/org/dromara/hertzbeat/common/entity/job/Metrics.java b/common/src/main/java/org/dromara/hertzbeat/common/entity/job/Metrics.java index 133fb303cd..5b14923619 100644 --- a/common/src/main/java/org/dromara/hertzbeat/common/entity/job/Metrics.java +++ b/common/src/main/java/org/dromara/hertzbeat/common/entity/job/Metrics.java @@ -33,9 +33,8 @@ import java.util.concurrent.atomic.AtomicInteger; import java.util.concurrent.atomic.AtomicReference; /** - * Details of the collection of indicators collected by monitoring + * Details of the monitoring metrics collected * eg: cpu | memory | health - * 监控采集的指标集合详情 eg: cpu | memory | health * * */ @@ -48,28 +47,26 @@ public class Metrics { /** * public property-name eg: cpu | memory | health - * 公共属性-名称 eg: cpu | memory | health */ private String name; /** - * metrics group name's i18n value - * 指标集合的国际化名称 + * metrics name's i18n value * zh-CN: CPU信息 * en-US: CPU Info */ private Map i18n; /** - * 公共属性-采集监控协议 eg: sql, ssh, http, telnet, wmi, snmp, sdk + * collect protocol eg: sql, ssh, http, telnet, wmi, snmp, sdk */ private String protocol; /** - * Range (0-127) indicator group scheduling priority, the smaller the value, the higher the priority - * The collection task of the next priority indicator group will be scheduled only after the scheduled collection with the higher priority is completed. - * The default priority of the availability indicator group is 0, and the range of other common indicator groups is 1-127, that is, - * the subsequent indicator group tasks will only be scheduled after the availability is collected successfully. - * 范围(0-127)指标组调度优先级,数值越小优先级越高 - * 优先级高的调度采集完成后才会调度下一优先级的指标组采集任务 - * 可用性指标组(availability)默认优先级为0,其它普通指标组范围为1-127,即需要等availability采集成功后才会调度后面的指标组任务 + * Range (0-127) metrics scheduling priority, the smaller the value, the higher the priority + * The collection task of the next priority metrics will be scheduled only after the scheduled collection with the higher priority is completed. + * The default priority of the availability metrics is 0, and the range of other common metrics is 1-127, that is, + * the subsequent metrics tasks will only be scheduled after the availability is collected successfully. + * 范围(0-127)调度优先级,数值越小优先级越高 + * 优先级高的调度采集完成后才会调度下一优先级的采集任务 + * 可用性指标(availability)默认优先级为0,其它普通指标采集范围为1-127,即需要等availability采集成功后才会调度后面的任务 */ private Byte priority; /** @@ -172,7 +169,7 @@ public class Metrics { private PrometheusProtocol prometheus; /** - * collector use - Temporarily store subTask indicator group response data + * collector use - Temporarily store subTask metrics response data * collector使用 - 临时存储分级任务指标响应数据 */ @JsonIgnore @@ -255,7 +252,7 @@ public class Metrics { @Builder public static class Field { /** - * Indicator name + * Metric name * 指标名称 */ private String field; @@ -267,12 +264,12 @@ public class Metrics { */ private Map i18n; /** - * Indicator type 0-number: number 1-string: string + * Metric type 0-number: number 1-string: string * 指标类型 0-number:数字 1-string:字符串 */ private byte type = 1; /** - * Whether this field is the instance primary key + * Whether this field is the instance */ private boolean instance = false; /** @@ -280,8 +277,7 @@ public class Metrics { */ private boolean label = false; /** - * Indicator unit - * 指标单位 + * Metric unit */ private String unit; } diff --git a/common/src/main/java/org/dromara/hertzbeat/common/entity/job/protocol/HttpProtocol.java b/common/src/main/java/org/dromara/hertzbeat/common/entity/job/protocol/HttpProtocol.java index 4bf2c2133d..e79ffd7996 100644 --- a/common/src/main/java/org/dromara/hertzbeat/common/entity/job/protocol/HttpProtocol.java +++ b/common/src/main/java/org/dromara/hertzbeat/common/entity/job/protocol/HttpProtocol.java @@ -28,7 +28,6 @@ import java.util.Map; /** * http 协议配置 * - * */ @Data @Builder diff --git a/common/src/main/java/org/dromara/hertzbeat/common/entity/job/protocol/IcmpProtocol.java b/common/src/main/java/org/dromara/hertzbeat/common/entity/job/protocol/IcmpProtocol.java index 15cb8e3f64..44d08cd5d6 100644 --- a/common/src/main/java/org/dromara/hertzbeat/common/entity/job/protocol/IcmpProtocol.java +++ b/common/src/main/java/org/dromara/hertzbeat/common/entity/job/protocol/IcmpProtocol.java @@ -25,7 +25,6 @@ import lombok.NoArgsConstructor; /** * icmp(即ping)协议配置 * - * */ @Data @Builder diff --git a/common/src/main/java/org/dromara/hertzbeat/common/entity/job/protocol/JdbcProtocol.java b/common/src/main/java/org/dromara/hertzbeat/common/entity/job/protocol/JdbcProtocol.java index 0a0ed74edf..7db351feed 100644 --- a/common/src/main/java/org/dromara/hertzbeat/common/entity/job/protocol/JdbcProtocol.java +++ b/common/src/main/java/org/dromara/hertzbeat/common/entity/job/protocol/JdbcProtocol.java @@ -25,7 +25,6 @@ import lombok.NoArgsConstructor; /** * 公共的jdbc规范实现的数据库配置信息 * - * */ @Data @Builder diff --git a/common/src/main/java/org/dromara/hertzbeat/common/entity/job/protocol/JmxProtocol.java b/common/src/main/java/org/dromara/hertzbeat/common/entity/job/protocol/JmxProtocol.java index c46aa005ba..c6c1891cac 100644 --- a/common/src/main/java/org/dromara/hertzbeat/common/entity/job/protocol/JmxProtocol.java +++ b/common/src/main/java/org/dromara/hertzbeat/common/entity/job/protocol/JmxProtocol.java @@ -9,7 +9,6 @@ import lombok.NoArgsConstructor; * Jmx protocol * * - * **/ @Data @Builder @@ -47,13 +46,13 @@ public class JmxProtocol { private String password; /** - * jmx protocol custom collection indicator address + * jmx protocol custom collection metric address * jmx协议自定义收集指标地址 */ private String url; /** - * The name of the type where the outer layer of the jmx indicator is located + * The name of the type where the outer layer of the jmx metric is located * jmx指标外层所在类型名称 */ private String objectName; diff --git a/common/src/main/java/org/dromara/hertzbeat/common/entity/job/protocol/MongodbProtocol.java b/common/src/main/java/org/dromara/hertzbeat/common/entity/job/protocol/MongodbProtocol.java index 76aedce2b9..5b93a09996 100644 --- a/common/src/main/java/org/dromara/hertzbeat/common/entity/job/protocol/MongodbProtocol.java +++ b/common/src/main/java/org/dromara/hertzbeat/common/entity/job/protocol/MongodbProtocol.java @@ -25,7 +25,6 @@ import lombok.NoArgsConstructor; /** * * @version 1.0 - * Created by Musk.Chen on 2022/5/17 */ @Data @Builder diff --git a/common/src/main/java/org/dromara/hertzbeat/common/entity/job/protocol/PrometheusProtocol.java b/common/src/main/java/org/dromara/hertzbeat/common/entity/job/protocol/PrometheusProtocol.java index acc6b5fea9..c4e8dc94d0 100644 --- a/common/src/main/java/org/dromara/hertzbeat/common/entity/job/protocol/PrometheusProtocol.java +++ b/common/src/main/java/org/dromara/hertzbeat/common/entity/job/protocol/PrometheusProtocol.java @@ -27,7 +27,6 @@ import java.util.Map; /** * Prometheus 协议配置 * - * */ @Data @Builder diff --git a/common/src/main/java/org/dromara/hertzbeat/common/entity/job/protocol/RedisProtocol.java b/common/src/main/java/org/dromara/hertzbeat/common/entity/job/protocol/RedisProtocol.java index b880a4113a..a06c36a43f 100644 --- a/common/src/main/java/org/dromara/hertzbeat/common/entity/job/protocol/RedisProtocol.java +++ b/common/src/main/java/org/dromara/hertzbeat/common/entity/job/protocol/RedisProtocol.java @@ -25,7 +25,6 @@ import lombok.NoArgsConstructor; /** * * @version 1.0 - * Created by Musk.Chen on 2022/5/17 */ @Data @Builder diff --git a/common/src/main/java/org/dromara/hertzbeat/common/entity/job/protocol/RocketmqProtocol.java b/common/src/main/java/org/dromara/hertzbeat/common/entity/job/protocol/RocketmqProtocol.java index b543de87da..910393ca68 100644 --- a/common/src/main/java/org/dromara/hertzbeat/common/entity/job/protocol/RocketmqProtocol.java +++ b/common/src/main/java/org/dromara/hertzbeat/common/entity/job/protocol/RocketmqProtocol.java @@ -8,8 +8,6 @@ import lombok.NoArgsConstructor; /** * rocketmq protocol * - * - * @since 5/6/2023 */ @Data @Builder diff --git a/common/src/main/java/org/dromara/hertzbeat/common/entity/job/protocol/SshProtocol.java b/common/src/main/java/org/dromara/hertzbeat/common/entity/job/protocol/SshProtocol.java index bca8fb2ad5..5d25e9c96a 100644 --- a/common/src/main/java/org/dromara/hertzbeat/common/entity/job/protocol/SshProtocol.java +++ b/common/src/main/java/org/dromara/hertzbeat/common/entity/job/protocol/SshProtocol.java @@ -25,8 +25,6 @@ import lombok.NoArgsConstructor; /** * ssh 协议参数配置 * - * - * */ @Data @Builder diff --git a/common/src/main/java/org/dromara/hertzbeat/common/entity/job/protocol/TelnetProtocol.java b/common/src/main/java/org/dromara/hertzbeat/common/entity/job/protocol/TelnetProtocol.java index d7f34a2ad2..68b0c7ca1b 100644 --- a/common/src/main/java/org/dromara/hertzbeat/common/entity/job/protocol/TelnetProtocol.java +++ b/common/src/main/java/org/dromara/hertzbeat/common/entity/job/protocol/TelnetProtocol.java @@ -25,7 +25,6 @@ import lombok.NoArgsConstructor; /** * telnet协议配置 * - * */ @Data @Builder diff --git a/common/src/main/java/org/dromara/hertzbeat/common/entity/job/protocol/UdpProtocol.java b/common/src/main/java/org/dromara/hertzbeat/common/entity/job/protocol/UdpProtocol.java index 2a1f56eff2..7db4e2d91f 100644 --- a/common/src/main/java/org/dromara/hertzbeat/common/entity/job/protocol/UdpProtocol.java +++ b/common/src/main/java/org/dromara/hertzbeat/common/entity/job/protocol/UdpProtocol.java @@ -25,7 +25,6 @@ import lombok.NoArgsConstructor; /** * 使用socket实现的udp进行服务端口可用性探测 * - * */ @Data @Builder diff --git a/common/src/main/java/org/dromara/hertzbeat/common/entity/manager/Collector.java b/common/src/main/java/org/dromara/hertzbeat/common/entity/manager/Collector.java index ccd30e379d..3d6210a5d2 100644 --- a/common/src/main/java/org/dromara/hertzbeat/common/entity/manager/Collector.java +++ b/common/src/main/java/org/dromara/hertzbeat/common/entity/manager/Collector.java @@ -56,19 +56,19 @@ public class Collector { @Schema(title = "collector mode: public or private") private String mode; - @Schema(title = "The creator of this record", description = "此条记录创建者", example = "tom") + @Schema(title = "The creator of this record", example = "tom") @CreatedBy private String creator; - @Schema(title = "This record was last modified by", description = "此条记录最新修改者") + @Schema(title = "This record was last modified by") @LastModifiedBy private String modifier; - @Schema(title = "This record creation time (millisecond timestamp)", description = "记录创建时间") + @Schema(title = "This record creation time (millisecond timestamp)") @CreatedDate private LocalDateTime gmtCreate; - @Schema(title = "Record the latest modification time (timestamp in milliseconds)", description = "记录最新修改时间") + @Schema(title = "Record the latest modification time (timestamp in milliseconds)") @LastModifiedDate private LocalDateTime gmtUpdate; } diff --git a/common/src/main/java/org/dromara/hertzbeat/common/entity/manager/CollectorMonitorBind.java b/common/src/main/java/org/dromara/hertzbeat/common/entity/manager/CollectorMonitorBind.java index f3f319d659..2771b825ba 100644 --- a/common/src/main/java/org/dromara/hertzbeat/common/entity/manager/CollectorMonitorBind.java +++ b/common/src/main/java/org/dromara/hertzbeat/common/entity/manager/CollectorMonitorBind.java @@ -50,19 +50,19 @@ public class CollectorMonitorBind { @Column(name = "monitor_id") private Long monitorId; - @Schema(title = "The creator of this record", description = "此条记录创建者", example = "tom") + @Schema(title = "The creator of this record", example = "tom") @CreatedBy private String creator; - @Schema(title = "This record was last modified by", description = "此条记录最新修改者") + @Schema(title = "This record was last modified by") @LastModifiedBy private String modifier; - @Schema(title = "This record creation time (millisecond timestamp)", description = "记录创建时间") + @Schema(title = "This record creation time (millisecond timestamp)") @CreatedDate private LocalDateTime gmtCreate; - @Schema(title = "Record the latest modification time (timestamp in milliseconds)", description = "记录最新修改时间") + @Schema(title = "Record the latest modification time (timestamp in milliseconds)") @LastModifiedDate private LocalDateTime gmtUpdate; } diff --git a/common/src/main/java/org/dromara/hertzbeat/common/entity/manager/GeneralConfig.java b/common/src/main/java/org/dromara/hertzbeat/common/entity/manager/GeneralConfig.java index a67f3907f9..d99b5e34e1 100644 --- a/common/src/main/java/org/dromara/hertzbeat/common/entity/manager/GeneralConfig.java +++ b/common/src/main/java/org/dromara/hertzbeat/common/entity/manager/GeneralConfig.java @@ -20,7 +20,7 @@ import static io.swagger.v3.oas.annotations.media.Schema.AccessMode.READ_ONLY; import static io.swagger.v3.oas.annotations.media.Schema.AccessMode.READ_WRITE; /** - * 公共配置实体 + * Common Config Entity * */ @Entity @@ -43,23 +43,19 @@ public class GeneralConfig { @Column(length = 8192) private String content; - @Schema(title = "The creator of this record", description = "此条记录创建者", example = "tom", accessMode = READ_ONLY) + @Schema(title = "The creator of this record", example = "tom", accessMode = READ_ONLY) @CreatedBy private String creator; - @Schema(title = "This record was last modified by", - description = "此条记录最新修改者", - example = "tom", accessMode = READ_ONLY) + @Schema(title = "This record was last modified by", example = "tom", accessMode = READ_ONLY) @LastModifiedBy private String modifier; - @Schema(title = "This record creation time (millisecond timestamp)", - description = "记录创建时间", accessMode = READ_ONLY) + @Schema(title = "This record creation time (millisecond timestamp)", accessMode = READ_ONLY) @CreatedDate private LocalDateTime gmtCreate; - @Schema(title = "Record the latest modification time (timestamp in milliseconds)", - description = "记录最新修改时间", accessMode = READ_ONLY) + @Schema(title = "Record the latest modification time (timestamp in milliseconds)", accessMode = READ_ONLY) @LastModifiedDate private LocalDateTime gmtUpdate; } diff --git a/common/src/main/java/org/dromara/hertzbeat/common/entity/manager/JsonByteListAttributeConverter.java b/common/src/main/java/org/dromara/hertzbeat/common/entity/manager/JsonByteListAttributeConverter.java index a80297c368..98dc7b3bf0 100644 --- a/common/src/main/java/org/dromara/hertzbeat/common/entity/manager/JsonByteListAttributeConverter.java +++ b/common/src/main/java/org/dromara/hertzbeat/common/entity/manager/JsonByteListAttributeConverter.java @@ -25,7 +25,7 @@ import java.util.List; import java.util.Map; /** - * json 互转list Byte 对象字段为数据String字段 + * json str to list Byte converter * * */ diff --git a/common/src/main/java/org/dromara/hertzbeat/common/entity/manager/JsonOptionListAttributeConverter.java b/common/src/main/java/org/dromara/hertzbeat/common/entity/manager/JsonOptionListAttributeConverter.java index 5cfb8943a2..6f543f94c1 100644 --- a/common/src/main/java/org/dromara/hertzbeat/common/entity/manager/JsonOptionListAttributeConverter.java +++ b/common/src/main/java/org/dromara/hertzbeat/common/entity/manager/JsonOptionListAttributeConverter.java @@ -24,7 +24,7 @@ import javax.persistence.AttributeConverter; import java.util.List; /** - * json 互转list paramDefine.Option 对象字段为数据String字段 + * json str to list paramDefine.Option * * */ diff --git a/common/src/main/java/org/dromara/hertzbeat/common/entity/manager/JsonTagListAttributeConverter.java b/common/src/main/java/org/dromara/hertzbeat/common/entity/manager/JsonTagListAttributeConverter.java index 9225a17593..a2dd2094d9 100644 --- a/common/src/main/java/org/dromara/hertzbeat/common/entity/manager/JsonTagListAttributeConverter.java +++ b/common/src/main/java/org/dromara/hertzbeat/common/entity/manager/JsonTagListAttributeConverter.java @@ -26,7 +26,7 @@ import java.util.Map; import java.util.stream.Collectors; /** - * json 互转 tag list 对象字段为数据String字段 + * json str to tag list * * */ diff --git a/common/src/main/java/org/dromara/hertzbeat/common/entity/manager/Monitor.java b/common/src/main/java/org/dromara/hertzbeat/common/entity/manager/Monitor.java index 696592125e..30f9b7e36d 100644 --- a/common/src/main/java/org/dromara/hertzbeat/common/entity/manager/Monitor.java +++ b/common/src/main/java/org/dromara/hertzbeat/common/entity/manager/Monitor.java @@ -40,8 +40,6 @@ import static io.swagger.v3.oas.annotations.media.Schema.AccessMode.READ_WRITE; /** * Monitor Entity - * 监控实体 - * * */ @Entity @@ -60,7 +58,6 @@ public class Monitor { /** * Monitor ID - * 主键ID */ @Id @Schema(title = "监控任务ID", example = "87584674384", accessMode = READ_ONLY) @@ -68,14 +65,12 @@ public class Monitor { /** * Job ID - * 监控对应下发的采集任务ID */ @Schema(title = "采集任务ID", example = "43243543543", accessMode = READ_ONLY) private Long jobId; /** * Monitor Name - * 监控的名称 */ @Schema(title = "任务名称", example = "Api-TanCloud.cn", accessMode = READ_WRITE) @Length(max = 100) @@ -125,33 +120,29 @@ public class Monitor { /** * The creator of this record - * 此条记录创建者 */ - @Schema(title = "此条记录创建者", example = "tom", accessMode = READ_ONLY) + @Schema(title = "The creator of this record", example = "tom", accessMode = READ_ONLY) @CreatedBy private String creator; /** * This record was last modified by - * 此条记录最新修改者 */ - @Schema(title = "此条记录最新修改者", example = "tom", accessMode = READ_ONLY) + @Schema(title = "The modifier of this record", example = "tom", accessMode = READ_ONLY) @LastModifiedBy private String modifier; /** - * record creation time (millisecond timestamp) - * 记录创建时间 + * Record create time */ - @Schema(title = "记录创建时间", example = "1612198922000", accessMode = READ_ONLY) + @Schema(title = "Record create time", example = "1612198922000", accessMode = READ_ONLY) @CreatedDate private LocalDateTime gmtCreate; /** * Record the latest modification time (timestamp in milliseconds) - * 记录最新修改时间 */ - @Schema(title = "记录最新修改时间", example = "1612198444000", accessMode = READ_ONLY) + @Schema(title = "Record modify time", example = "1612198444000", accessMode = READ_ONLY) @LastModifiedDate private LocalDateTime gmtUpdate; diff --git a/common/src/main/java/org/dromara/hertzbeat/common/entity/manager/NoticeReceiver.java b/common/src/main/java/org/dromara/hertzbeat/common/entity/manager/NoticeReceiver.java index 228aa803cd..a1451a755a 100644 --- a/common/src/main/java/org/dromara/hertzbeat/common/entity/manager/NoticeReceiver.java +++ b/common/src/main/java/org/dromara/hertzbeat/common/entity/manager/NoticeReceiver.java @@ -42,8 +42,6 @@ import static io.swagger.v3.oas.annotations.media.Schema.AccessMode.READ_WRITE; * Message notification recipient entity * 消息通知接收人实体 * - * - * */ @Entity @Table(name = "hzb_notice_receiver") @@ -195,23 +193,22 @@ public class NoticeReceiver { @Column(length = 300) private String serverChanToken; - @Schema(title = "The creator of this record", description = "此条记录创建者", example = "tom", + @Schema(title = "The creator of this record", example = "tom", accessMode = READ_ONLY) @CreatedBy private String creator; - @Schema(title = "This record was last modified by", description = "此条记录最新修改者", - example = "tom", accessMode = READ_ONLY) + @Schema(title = "This record was last modified by", example = "tom", accessMode = READ_ONLY) @LastModifiedBy private String modifier; - @Schema(title = "Record creation time (millisecond timestamp)", description = "记录创建时间", + @Schema(title = "Record creation time (millisecond timestamp)", example = "1612198922000", accessMode = READ_ONLY) @CreatedDate private LocalDateTime gmtCreate; @Schema(title = "Record the latest modification time (timestamp in milliseconds)", - description = "记录最新修改时间", example = "1612198444000", accessMode = READ_ONLY) + example = "1612198444000", accessMode = READ_ONLY) @LastModifiedDate private LocalDateTime gmtUpdate; diff --git a/common/src/main/java/org/dromara/hertzbeat/common/entity/manager/NoticeRule.java b/common/src/main/java/org/dromara/hertzbeat/common/entity/manager/NoticeRule.java index 05e3086746..96b1955d33 100644 --- a/common/src/main/java/org/dromara/hertzbeat/common/entity/manager/NoticeRule.java +++ b/common/src/main/java/org/dromara/hertzbeat/common/entity/manager/NoticeRule.java @@ -41,7 +41,6 @@ import static io.swagger.v3.oas.annotations.media.Schema.AccessMode.READ_WRITE; * Notification strategy entity * 通知策略 * - * */ @Entity @Table(name = "hzb_notice_rule") @@ -122,23 +121,19 @@ public class NoticeRule { @Schema(title = "限制时间段截止", example = "23:59:59", accessMode = READ_WRITE) private ZonedDateTime periodEnd; - @Schema(title = "The creator of this record", description = "此条记录创建者", example = "tom", accessMode = READ_ONLY) + @Schema(title = "The creator of this record", example = "tom", accessMode = READ_ONLY) @CreatedBy private String creator; - @Schema(title = "This record was last modified by", - description = "此条记录最新修改者", - example = "tom", accessMode = READ_ONLY) + @Schema(title = "This record was last modified by", example = "tom", accessMode = READ_ONLY) @LastModifiedBy private String modifier; - @Schema(title = "This record creation time (millisecond timestamp)", - description = "记录创建时间", accessMode = READ_ONLY) + @Schema(title = "This record creation time (millisecond timestamp)", accessMode = READ_ONLY) @CreatedDate private LocalDateTime gmtCreate; - @Schema(title = "Record the latest modification time (timestamp in milliseconds)", - description = "记录最新修改时间", accessMode = READ_ONLY) + @Schema(title = "Record the latest modification time (timestamp in milliseconds)", accessMode = READ_ONLY) @LastModifiedDate private LocalDateTime gmtUpdate; } diff --git a/common/src/main/java/org/dromara/hertzbeat/common/entity/manager/NoticeTemplate.java b/common/src/main/java/org/dromara/hertzbeat/common/entity/manager/NoticeTemplate.java index 4c76d90bb2..62ea477df5 100644 --- a/common/src/main/java/org/dromara/hertzbeat/common/entity/manager/NoticeTemplate.java +++ b/common/src/main/java/org/dromara/hertzbeat/common/entity/manager/NoticeTemplate.java @@ -42,7 +42,6 @@ import static io.swagger.v3.oas.annotations.media.Schema.AccessMode.READ_WRITE; * Notification template entity * 通知模版 * - * */ @Entity @Table(name = "hzb_notice_template") @@ -95,23 +94,19 @@ public class NoticeTemplate { @NotBlank private String content; - @Schema(title = "The creator of this record", description = "此条记录创建者", example = "tom", accessMode = READ_ONLY) + @Schema(title = "The creator of this record", example = "tom", accessMode = READ_ONLY) @CreatedBy private String creator; - @Schema(title = "This record was last modified by", - description = "此条记录最新修改者", - example = "tom", accessMode = READ_ONLY) + @Schema(title = "This record was last modified by", example = "tom", accessMode = READ_ONLY) @LastModifiedBy private String modifier; - @Schema(title = "This record creation time (millisecond timestamp)", - description = "记录创建时间", accessMode = READ_ONLY) + @Schema(title = "This record creation time (millisecond timestamp)", accessMode = READ_ONLY) @CreatedDate private LocalDateTime gmtCreate; - @Schema(title = "Record the latest modification time (timestamp in milliseconds)", - description = "记录最新修改时间", accessMode = READ_ONLY) + @Schema(title = "Record the latest modification time (timestamp in milliseconds)", accessMode = READ_ONLY) @LastModifiedDate private LocalDateTime gmtUpdate; } diff --git a/common/src/main/java/org/dromara/hertzbeat/common/entity/manager/Param.java b/common/src/main/java/org/dromara/hertzbeat/common/entity/manager/Param.java index 68aa3f781e..f21b38ccc8 100644 --- a/common/src/main/java/org/dromara/hertzbeat/common/entity/manager/Param.java +++ b/common/src/main/java/org/dromara/hertzbeat/common/entity/manager/Param.java @@ -41,8 +41,6 @@ import static io.swagger.v3.oas.annotations.media.Schema.AccessMode.READ_WRITE; * Monitor parameter values * 监控参数值 * - * - * */ @Entity @Table(name = "hzb_param", indexes = { @Index(columnList = "monitorId") }, @@ -97,18 +95,16 @@ public class Param { private byte type; /** - * Record Creation Time - * 记录创建时间 + * Record create time */ - @Schema(title = "记录创建时间", example = "1612198922000", accessMode = READ_ONLY) + @Schema(title = "Record create time", example = "1612198922000", accessMode = READ_ONLY) @CreatedDate private LocalDateTime gmtCreate; /** * Record the latest modification time - * 记录最新修改时间 */ - @Schema(title = "记录最新修改时间", example = "1612198444000", accessMode = READ_ONLY) + @Schema(title = "Record modify time", example = "1612198444000", accessMode = READ_ONLY) @LastModifiedDate private LocalDateTime gmtUpdate; diff --git a/common/src/main/java/org/dromara/hertzbeat/common/entity/manager/ParamDefine.java b/common/src/main/java/org/dromara/hertzbeat/common/entity/manager/ParamDefine.java index 0aa6a45fe3..3df371e4e9 100644 --- a/common/src/main/java/org/dromara/hertzbeat/common/entity/manager/ParamDefine.java +++ b/common/src/main/java/org/dromara/hertzbeat/common/entity/manager/ParamDefine.java @@ -41,8 +41,6 @@ import static io.swagger.v3.oas.annotations.media.Schema.AccessMode.READ_WRITE; * Monitoring parameter definitions * 监控参数定义 * - * - * */ @Entity @Table(name = "hzb_param_define") @@ -170,33 +168,29 @@ public class ParamDefine { /** * The creator of this record - * 此条记录创建者 */ - @Schema(title = "此条记录创建者", example = "tom", accessMode = READ_ONLY) + @Schema(title = "The creator of this record", example = "tom", accessMode = READ_ONLY) @CreatedBy private String creator; /** * This record was last modified by - * 此条记录最新修改者 */ - @Schema(title = "此条记录最新修改者", example = "tom", accessMode = READ_ONLY) + @Schema(title = "The modifier of this record", example = "tom", accessMode = READ_ONLY) @LastModifiedBy private String modifier; /** - * record creation time - * 记录创建时间 + * Record create time */ - @Schema(title = "记录创建时间", example = "1612198922000", accessMode = READ_ONLY) + @Schema(title = "Record create time", example = "1612198922000", accessMode = READ_ONLY) @CreatedDate private LocalDateTime gmtCreate; /** * Record the latest modification time - * 记录最新修改时间 */ - @Schema(title = "记录最新修改时间", example = "1612198444000", accessMode = READ_ONLY) + @Schema(title = "Record modify time", example = "1612198444000", accessMode = READ_ONLY) @LastModifiedDate private LocalDateTime gmtUpdate; diff --git a/common/src/main/java/org/dromara/hertzbeat/common/entity/manager/Tag.java b/common/src/main/java/org/dromara/hertzbeat/common/entity/manager/Tag.java index bae3d2ebb8..cf5d8dc2f2 100644 --- a/common/src/main/java/org/dromara/hertzbeat/common/entity/manager/Tag.java +++ b/common/src/main/java/org/dromara/hertzbeat/common/entity/manager/Tag.java @@ -38,9 +38,7 @@ import static io.swagger.v3.oas.annotations.media.Schema.AccessMode.READ_ONLY; import static io.swagger.v3.oas.annotations.media.Schema.AccessMode.READ_WRITE; /** - * Tag - * 标签 - * + * Tag Entity * */ @Entity @@ -74,19 +72,19 @@ public class Tag { @Max(3) private byte type; - @Schema(title = "此条记录创建者", example = "tom", accessMode = READ_ONLY) + @Schema(title = "The creator of this record", example = "tom", accessMode = READ_ONLY) @CreatedBy private String creator; - @Schema(title = "此条记录最新修改者", example = "tom", accessMode = READ_ONLY) + @Schema(title = "The modifier of this record", example = "tom", accessMode = READ_ONLY) @LastModifiedBy private String modifier; - @Schema(title = "记录创建时间", example = "1612198922000", accessMode = READ_ONLY) + @Schema(title = "Record create time", example = "1612198922000", accessMode = READ_ONLY) @CreatedDate private LocalDateTime gmtCreate; - @Schema(title = "记录最新修改时间", example = "1612198444000", accessMode = READ_ONLY) + @Schema(title = "Record modify time", example = "1612198444000", accessMode = READ_ONLY) @LastModifiedDate private LocalDateTime gmtUpdate; diff --git a/common/src/main/java/org/dromara/hertzbeat/common/entity/manager/TagItem.java b/common/src/main/java/org/dromara/hertzbeat/common/entity/manager/TagItem.java index 5467bab7f2..876d5a7890 100644 --- a/common/src/main/java/org/dromara/hertzbeat/common/entity/manager/TagItem.java +++ b/common/src/main/java/org/dromara/hertzbeat/common/entity/manager/TagItem.java @@ -10,7 +10,6 @@ import javax.validation.constraints.NotBlank; /** * tag item * - * */ @AllArgsConstructor @NoArgsConstructor diff --git a/common/src/main/java/org/dromara/hertzbeat/common/entity/manager/TagMonitorBind.java b/common/src/main/java/org/dromara/hertzbeat/common/entity/manager/TagMonitorBind.java index 43a9e8e5b1..53e3640f49 100644 --- a/common/src/main/java/org/dromara/hertzbeat/common/entity/manager/TagMonitorBind.java +++ b/common/src/main/java/org/dromara/hertzbeat/common/entity/manager/TagMonitorBind.java @@ -35,7 +35,6 @@ import static io.swagger.v3.oas.annotations.media.Schema.AccessMode.READ_WRITE; * Tag Bind Monitor * 标签与监控关联实体 * - * */ @Entity @Table(name = "hzb_tag_monitor_bind", indexes = { @@ -63,11 +62,11 @@ public class TagMonitorBind { @Column(name = "monitor_id") private Long monitorId; - @Schema(title = "记录创建时间", example = "1612198922000", accessMode = READ_ONLY) + @Schema(title = "Record create time", example = "1612198922000", accessMode = READ_ONLY) @CreatedDate private LocalDateTime gmtCreate; - @Schema(title = "记录最新修改时间", example = "1612198444000", accessMode = READ_ONLY) + @Schema(title = "Record modify time", example = "1612198444000", accessMode = READ_ONLY) @LastModifiedDate private LocalDateTime gmtUpdate; diff --git a/common/src/main/java/org/dromara/hertzbeat/common/entity/warehouse/History.java b/common/src/main/java/org/dromara/hertzbeat/common/entity/warehouse/History.java index 4b96f7a036..843bc661d4 100644 --- a/common/src/main/java/org/dromara/hertzbeat/common/entity/warehouse/History.java +++ b/common/src/main/java/org/dromara/hertzbeat/common/entity/warehouse/History.java @@ -12,9 +12,7 @@ import static io.swagger.v3.oas.annotations.media.Schema.AccessMode.READ_ONLY; import static io.swagger.v3.oas.annotations.media.Schema.AccessMode.READ_WRITE; /** - * metrics history - * - * + * metrics history data entity * */ @Entity @@ -28,7 +26,7 @@ import static io.swagger.v3.oas.annotations.media.Schema.AccessMode.READ_WRITE; @Builder @AllArgsConstructor @NoArgsConstructor -@Schema(description = "Metrics data history entity | 指标数据历史实体") +@Schema(description = "Metrics History Data Entity | 指标数据历史实体") public class History { @Id @@ -36,33 +34,32 @@ public class History { @Schema(description = "指标数据历史实体主键索引ID", example = "87584674384", accessMode = READ_ONLY) private Long id; - @Schema(title = "监控任务ID", example = "87432674336", accessMode = READ_WRITE) + @Schema(title = "Monitoring Id", example = "87432674336", accessMode = READ_WRITE) private Long monitorId; - @Schema(title = "监控类型 mysql oracle db2") + @Schema(title = "Monitoring Type mysql oracle db2") private String app; - @Schema(title = "指标集合名称 innodb disk cpu") + @Schema(title = "Monitoring Metrics innodb disk cpu") private String metrics; - @Schema(title = "指标名称 usage speed count") + @Schema(title = "Monitoring Metric usage speed count") private String metric; - - @Schema(title = "实例") + @Column(length = 2048) private String instance; - @Schema(title = "字段类型 0: 数值 1:字符串") + @Schema(title = "Metric Type 0: Number 1:String") private Byte metricType; - @Schema(title = "字符值") + @Schema(title = "Metric String Value") @Column(length = 2048) private String str; - @Schema(title = "数值") + @Schema(title = "Metric Number Value") private Double dou; - @Schema(title = "采集时间戳") + @Schema(title = "Collect Time") private Long time; } diff --git a/common/src/main/java/org/dromara/hertzbeat/common/queue/impl/InMemoryCommonDataQueue.java b/common/src/main/java/org/dromara/hertzbeat/common/queue/impl/InMemoryCommonDataQueue.java index 2f9fa22cf4..b138b8808b 100644 --- a/common/src/main/java/org/dromara/hertzbeat/common/queue/impl/InMemoryCommonDataQueue.java +++ b/common/src/main/java/org/dromara/hertzbeat/common/queue/impl/InMemoryCommonDataQueue.java @@ -32,8 +32,7 @@ import java.util.concurrent.LinkedBlockingQueue; import java.util.concurrent.TimeUnit; /** - * 内存采集数据队列实现 - * + * common data queue implement memory * */ @Configuration diff --git a/common/src/main/java/org/dromara/hertzbeat/common/queue/impl/KafkaCommonDataQueue.java b/common/src/main/java/org/dromara/hertzbeat/common/queue/impl/KafkaCommonDataQueue.java index 58a4666b66..3432a5d72b 100644 --- a/common/src/main/java/org/dromara/hertzbeat/common/queue/impl/KafkaCommonDataQueue.java +++ b/common/src/main/java/org/dromara/hertzbeat/common/queue/impl/KafkaCommonDataQueue.java @@ -29,7 +29,7 @@ import java.util.concurrent.locks.ReentrantLock; /** - * kafka采集数据队列实现 + * common data queue implement kafka * * */ diff --git a/common/src/main/java/org/dromara/hertzbeat/common/serialize/AlertDeserializer.java b/common/src/main/java/org/dromara/hertzbeat/common/serialize/AlertDeserializer.java index af7a788c3e..adc490f0f1 100644 --- a/common/src/main/java/org/dromara/hertzbeat/common/serialize/AlertDeserializer.java +++ b/common/src/main/java/org/dromara/hertzbeat/common/serialize/AlertDeserializer.java @@ -8,7 +8,7 @@ import org.dromara.hertzbeat.common.util.JsonUtil; import java.util.Map; /** - * kafka告警记录反序列化类 + * kafka alert deserializer * */ public class AlertDeserializer implements Deserializer { diff --git a/common/src/main/java/org/dromara/hertzbeat/common/serialize/AlertSerializer.java b/common/src/main/java/org/dromara/hertzbeat/common/serialize/AlertSerializer.java index 44628ec4ad..ee82532169 100644 --- a/common/src/main/java/org/dromara/hertzbeat/common/serialize/AlertSerializer.java +++ b/common/src/main/java/org/dromara/hertzbeat/common/serialize/AlertSerializer.java @@ -9,7 +9,7 @@ import org.dromara.hertzbeat.common.util.JsonUtil; import java.util.Map; /** - * kafka告警记录序列化类 + * kafka alert entity serializer * */ public class AlertSerializer implements Serializer { diff --git a/common/src/main/java/org/dromara/hertzbeat/common/serialize/KafkaMetricsDataDeserializer.java b/common/src/main/java/org/dromara/hertzbeat/common/serialize/KafkaMetricsDataDeserializer.java index b2de55c35a..695f959360 100644 --- a/common/src/main/java/org/dromara/hertzbeat/common/serialize/KafkaMetricsDataDeserializer.java +++ b/common/src/main/java/org/dromara/hertzbeat/common/serialize/KafkaMetricsDataDeserializer.java @@ -8,7 +8,7 @@ import org.dromara.hertzbeat.common.entity.message.CollectRep; import java.util.Map; /** - * kafka指标组监控数据反序列化类 + * kafka metrics data deserializer * */ public class KafkaMetricsDataDeserializer implements Deserializer { diff --git a/common/src/main/java/org/dromara/hertzbeat/common/serialize/KafkaMetricsDataSerializer.java b/common/src/main/java/org/dromara/hertzbeat/common/serialize/KafkaMetricsDataSerializer.java index 751e09168e..0481933773 100644 --- a/common/src/main/java/org/dromara/hertzbeat/common/serialize/KafkaMetricsDataSerializer.java +++ b/common/src/main/java/org/dromara/hertzbeat/common/serialize/KafkaMetricsDataSerializer.java @@ -9,7 +9,7 @@ import java.util.Map; /** - * kafka指标组监控数据序列化类 + * kafka metrics data serializer * */ public class KafkaMetricsDataSerializer implements Serializer { diff --git a/common/src/main/java/org/dromara/hertzbeat/common/service/TencentSmsClient.java b/common/src/main/java/org/dromara/hertzbeat/common/service/TencentSmsClient.java index b5dd2a2aff..9903f97ecc 100644 --- a/common/src/main/java/org/dromara/hertzbeat/common/service/TencentSmsClient.java +++ b/common/src/main/java/org/dromara/hertzbeat/common/service/TencentSmsClient.java @@ -14,7 +14,6 @@ import org.springframework.stereotype.Component; /** * sms service client for tencent cloud * - * */ @Component @ConditionalOnProperty("common.sms.tencent.app-id") diff --git a/common/src/main/java/org/dromara/hertzbeat/common/support/SpringContextHolder.java b/common/src/main/java/org/dromara/hertzbeat/common/support/SpringContextHolder.java index 5a82c091ea..5243a6420c 100644 --- a/common/src/main/java/org/dromara/hertzbeat/common/support/SpringContextHolder.java +++ b/common/src/main/java/org/dromara/hertzbeat/common/support/SpringContextHolder.java @@ -24,8 +24,7 @@ import org.springframework.context.ConfigurableApplicationContext; import org.springframework.stereotype.Component; /** - * Spring的ApplicationContext的持有者,可以用静态方法的方式获取spring容器中的bean - * + * Spring ApplicationContext Holder * */ @Component diff --git a/common/src/main/java/org/dromara/hertzbeat/common/support/exception/SendMessageException.java b/common/src/main/java/org/dromara/hertzbeat/common/support/exception/SendMessageException.java index 226c0450e4..faac0c3f5c 100644 --- a/common/src/main/java/org/dromara/hertzbeat/common/support/exception/SendMessageException.java +++ b/common/src/main/java/org/dromara/hertzbeat/common/support/exception/SendMessageException.java @@ -3,7 +3,6 @@ package org.dromara.hertzbeat.common.support.exception; /** * send message exception * - * */ public class SendMessageException extends RuntimeException { public SendMessageException(String message) { diff --git a/common/src/main/java/org/dromara/hertzbeat/common/support/valid/EmailParamValidator.java b/common/src/main/java/org/dromara/hertzbeat/common/support/valid/EmailParamValidator.java index c6292c1bf1..588d6f71d3 100644 --- a/common/src/main/java/org/dromara/hertzbeat/common/support/valid/EmailParamValidator.java +++ b/common/src/main/java/org/dromara/hertzbeat/common/support/valid/EmailParamValidator.java @@ -23,15 +23,14 @@ import javax.validation.ConstraintValidator; import javax.validation.ConstraintValidatorContext; /** - * email注解数据自定义校验器 - * + * email validator * */ public class EmailParamValidator implements ConstraintValidator { @Override public boolean isValid(String value, ConstraintValidatorContext context) { - // 判断value是否满足ipv4 ipv5 域名 格式 + // validate email return CommonUtil.validateEmail(value); } } diff --git a/common/src/main/java/org/dromara/hertzbeat/common/support/valid/EmailValid.java b/common/src/main/java/org/dromara/hertzbeat/common/support/valid/EmailValid.java index 89c4b75cc8..91c0beb28d 100644 --- a/common/src/main/java/org/dromara/hertzbeat/common/support/valid/EmailValid.java +++ b/common/src/main/java/org/dromara/hertzbeat/common/support/valid/EmailValid.java @@ -28,8 +28,7 @@ import static java.lang.annotation.ElementType.PARAMETER; import static java.lang.annotation.RetentionPolicy.RUNTIME; /** - * email注解数据自定义校验器注解 - * + * EmailValid * */ @Target({ FIELD, PARAMETER }) diff --git a/common/src/main/java/org/dromara/hertzbeat/common/support/valid/HostParamValidator.java b/common/src/main/java/org/dromara/hertzbeat/common/support/valid/HostParamValidator.java index adb24eeb3d..d8ca349f24 100644 --- a/common/src/main/java/org/dromara/hertzbeat/common/support/valid/HostParamValidator.java +++ b/common/src/main/java/org/dromara/hertzbeat/common/support/valid/HostParamValidator.java @@ -23,7 +23,7 @@ import javax.validation.ConstraintValidator; import javax.validation.ConstraintValidatorContext; /** - * host注解数据自定义校验器 + * Host Param Validator * * */ @@ -36,7 +36,6 @@ public class HostParamValidator implements ConstraintValidatorEX:127.0.0.1 或者 hertzbeat.com"; + String message() default "Host need ipv4,ipv6 or domain,
EG:127.0.0.1 hertzbeat.com"; Class[] groups() default {}; diff --git a/common/src/main/java/org/dromara/hertzbeat/common/support/valid/PhoneNumParamValidator.java b/common/src/main/java/org/dromara/hertzbeat/common/support/valid/PhoneNumParamValidator.java index d3685abfa7..039591fd24 100644 --- a/common/src/main/java/org/dromara/hertzbeat/common/support/valid/PhoneNumParamValidator.java +++ b/common/src/main/java/org/dromara/hertzbeat/common/support/valid/PhoneNumParamValidator.java @@ -23,7 +23,7 @@ import javax.validation.ConstraintValidator; import javax.validation.ConstraintValidatorContext; /** - * PhoneNum注解数据自定义校验器 + * PhoneNum Param Validator * * */ @@ -31,7 +31,6 @@ public class PhoneNumParamValidator implements ConstraintValidator { diff --git a/common/src/main/java/org/dromara/hertzbeat/common/util/ProtoJsonUtil.java b/common/src/main/java/org/dromara/hertzbeat/common/util/ProtoJsonUtil.java index 9181072f9f..4068f63c6a 100644 --- a/common/src/main/java/org/dromara/hertzbeat/common/util/ProtoJsonUtil.java +++ b/common/src/main/java/org/dromara/hertzbeat/common/util/ProtoJsonUtil.java @@ -22,8 +22,7 @@ import com.google.protobuf.util.JsonFormat; import lombok.extern.slf4j.Slf4j; /** - * protobuf json相互转换工具类 - * + * protobuf json convert util * */ @Slf4j @@ -33,7 +32,7 @@ public class ProtoJsonUtil { private static final JsonFormat.Parser PARSER = JsonFormat.parser(); /** - * protobuf 转 json + * protobuf to json * @param proto protobuf * @return json */ @@ -47,7 +46,7 @@ public class ProtoJsonUtil { } /** - * json转protobuf + * json to protobuf * @param json json str * @param builder proto instance builder * @return protobuf diff --git a/common/src/main/java/org/dromara/hertzbeat/common/util/ResourceBundleUtil.java b/common/src/main/java/org/dromara/hertzbeat/common/util/ResourceBundleUtil.java index fa3dd8cbd6..7045e8a752 100644 --- a/common/src/main/java/org/dromara/hertzbeat/common/util/ResourceBundleUtil.java +++ b/common/src/main/java/org/dromara/hertzbeat/common/util/ResourceBundleUtil.java @@ -27,7 +27,6 @@ import java.util.ResourceBundle; /** * i18n ResourceBundle util * - * */ @Slf4j public class ResourceBundleUtil { diff --git a/common/src/main/java/org/dromara/hertzbeat/common/util/SnowFlakeIdGenerator.java b/common/src/main/java/org/dromara/hertzbeat/common/util/SnowFlakeIdGenerator.java index 8d8189c187..bef0b498e2 100644 --- a/common/src/main/java/org/dromara/hertzbeat/common/util/SnowFlakeIdGenerator.java +++ b/common/src/main/java/org/dromara/hertzbeat/common/util/SnowFlakeIdGenerator.java @@ -19,9 +19,6 @@ package org.dromara.hertzbeat.common.util; /** * Snowflake Algorithm Generator Tool - * 雪花算法生成器工具 - * - * * */ public class SnowFlakeIdGenerator { diff --git a/common/src/main/java/org/dromara/hertzbeat/common/util/SnowFlakeIdWorker.java b/common/src/main/java/org/dromara/hertzbeat/common/util/SnowFlakeIdWorker.java index 8cc114119a..2c3d85382f 100644 --- a/common/src/main/java/org/dromara/hertzbeat/common/util/SnowFlakeIdWorker.java +++ b/common/src/main/java/org/dromara/hertzbeat/common/util/SnowFlakeIdWorker.java @@ -22,7 +22,7 @@ import lombok.extern.slf4j.Slf4j; import java.util.Random; /** - * 雪花算法生成器实例 + * SnowFlakeId Instance * 注意 由于前端JS TS 在json解析大数会造成精度丢失 UUID 不能超过 9007199254740991(10进制)16进制为 0x1FFFFFFFFFFFFF (小于53bit) * 1位符号位+41位时间戳+4位机器ID+8位序列号 = 53位 * Note that because the front-end JS TS parses large numbers in json, the precision will be lost. @@ -116,9 +116,9 @@ public class SnowFlakeIdWorker { } /** - * 获得下一个 ID(该方法是线程安全的) - * - * @return 返回一个长度位15的 long类型的数字 + * get next id + * thread safe + * @return id with 15 length */ public synchronized long nextId() { long timestamp = timeGen(); diff --git a/common/src/main/java/org/dromara/hertzbeat/common/util/TimePeriodUtil.java b/common/src/main/java/org/dromara/hertzbeat/common/util/TimePeriodUtil.java index 7a9d4e7191..6d5b0516e8 100644 --- a/common/src/main/java/org/dromara/hertzbeat/common/util/TimePeriodUtil.java +++ b/common/src/main/java/org/dromara/hertzbeat/common/util/TimePeriodUtil.java @@ -7,8 +7,6 @@ import java.time.temporal.TemporalAmount; /** * time util * - * - * */ public class TimePeriodUtil { diff --git a/home/blog/2022-07-10-hertzbeat-v1.1.1.md b/home/blog/2022-07-10-hertzbeat-v1.1.1.md index 6be22d733d..8e829b6a19 100644 --- a/home/blog/2022-07-10-hertzbeat-v1.1.1.md +++ b/home/blog/2022-07-10-hertzbeat-v1.1.1.md @@ -11,7 +11,7 @@ tags: [opensource] **Home: [hertzbeat.com](https://hertzbeat.com)** -Hi guys! HertzBeat v1.1.1 is coming. This version brings custom monitoring enhancements, and the collected indicator data can be assigned as a variable to the next collection. Fixed several bugs and improved the overall stable usability. +Hi guys! HertzBeat v1.1.1 is coming. This version brings custom monitoring enhancements, and the collected metric data can be assigned as a variable to the next collection. Fixed several bugs and improved the overall stable usability. Only one docker command is needed to install and experience hertzbeat: `docker run -d -p 1157:1157 --name hertzbeat tancloud/hertzbeat` diff --git a/home/blog/2023-01-05-monitor-iotdb.md b/home/blog/2023-01-05-monitor-iotdb.md index 9a957c1ac6..48c2cd69d1 100644 --- a/home/blog/2023-01-05-monitor-iotdb.md +++ b/home/blog/2023-01-05-monitor-iotdb.md @@ -61,11 +61,11 @@ For other parameters such as **collection interval**, **timeout period**, etc., ![hertzbeat](/img/blog/monitor-iotdb-3.png) -4. Click **Operation**->**Monitoring Details Icon** of the monitoring list item to browse the real-time monitoring indicator data of IoTDB. +4. Click **Operation**->**Monitoring Details Icon** of the monitoring list item to browse the real-time monitoring metric data of IoTDB. ![hertzbeat](/img/blog/monitor-iotdb-4.png) -5. Click **Monitoring History Details TAB** to browse IoTDB's historical monitoring indicator data chart📈. +5. Click **Monitoring History Details TAB** to browse IoTDB's historical monitoring metric data chart📈. ![hertzbeat](/img/blog/monitor-iotdb-5.png) @@ -74,18 +74,18 @@ For other parameters such as **collection interval**, **timeout period**, etc., - **Another step is to configure the IP port on the HertzBeat monitoring page to add monitoring** -**In this way, we have completed the monitoring of IoTDB. We can view the monitoring details and indicators at any time to observe its service status, but people cannot always watch it. When there is always a time to rest, monitoring is often accompanied by alarms. When monitoring When the indicators are abnormal, the monitoring tool needs to be able to notify the person in charge in time** +**In this way, we have completed the monitoring of IoTDB. We can view the monitoring details and metrics at any time to observe its service status, but people cannot always watch it. When there is always a time to rest, monitoring is often accompanied by alarms. When monitoring When the metrics are abnormal, the monitoring tool needs to be able to notify the person in charge in time** **Next, we will teach you step by step to configure the threshold alarm notification in the HertzBeat system** -#### 3. Add IoTDB indicator threshold alarm in HertzBeat system +#### 3. Add IoTDB metric threshold alarm in HertzBeat system -1. Configure a threshold alarm for an important indicator +1. Configure a threshold alarm for an important metric Path: Menu -> Alarm Threshold -> Add Threshold -- Select the configured indicator object. IotDB monitors many indicators, one of which is related to the status of the node `cluster_node_status` -> `status` (node status, 1=online 2=offline). -- Here we configure to send an alarm when the indicator `status==2`, the alarm level is **Critical Alarm**, which is triggered once, as shown in the figure below. +- Select the configured metric object. IotDB monitors many metrics, one of which is related to the status of the node `cluster_node_status` -> `status` (node status, 1=online 2=offline). +- Here we configure to send an alarm when the metric `status==2`, the alarm level is **Critical Alarm**, which is triggered once, as shown in the figure below. ![hertzbeat](/img/blog/monitor-iotdb-6.png) @@ -122,7 +122,7 @@ Content details: The status of IOTDB node 127.0.0.1 is monitored as OFFLINE, ple ## Summary -This practical article took us to experience that if HertzBeat is used to monitor the IoTDB database indicator data, we can find that HertzBeat, which integrates monitoring-alarm-notification, is more convenient in operation and use, and IoTDB can be included in the monitoring with a simple click on the page, it is no longer necessary to deploy multiple components and write multiple YML configuration files with thresholds. +This practical article took us to experience that if HertzBeat is used to monitor the IoTDB database metric data, we can find that HertzBeat, which integrates monitoring-alarm-notification, is more convenient in operation and use, and IoTDB can be included in the monitoring with a simple click on the page, it is no longer necessary to deploy multiple components and write multiple YML configuration files with thresholds. IoTDB Github: https://github.com/apache/iotdb HertzBeat Github: https://github.com/dromara/hertzbeat @@ -132,4 +132,4 @@ HertzBeat Github: https://github.com/dromara/hertzbeat Only one docker command is needed to install and experience heartbeat: `docker run -d -p 1157:1157 --name hertzbeat tancloud/hertzbeat` -Note ⚠️HertzBeat v1.2.3 version supports IoTDB v0.12 v0.13. Since its v1.0 has just been released, all indicators of this version are not yet compatible. +Note ⚠️HertzBeat v1.2.3 version supports IoTDB v0.12 v0.13. Since its v1.0 has just been released, all metrics of this version are not yet compatible. diff --git a/home/blog/2023-02-10-new-committer.md b/home/blog/2023-02-10-new-committer.md index 6957d1bc5f..acaae02fa8 100644 --- a/home/blog/2023-02-10-new-committer.md +++ b/home/blog/2023-02-10-new-committer.md @@ -38,7 +38,7 @@ The first PR was submitted on April 17, 2022, mainly for the problem of TDEngine So far, I have participated in the hertzbeat open source project for more than half a year, contributed a lot, and grown and gained a lot. details as follows: * Refactored the alarm module based on the strategy mode -* Implemented indicator monitoring for `Redis` database +* Implemented metric monitoring for `Redis` database * Optimize `spring.factories` configuration items * Implemented message notification channels supporting `Telegram`, `Discord`, `Slack` * Use `Thymeleaf` to restructure the alarm text, and the alarm notification template is more standardized @@ -112,7 +112,7 @@ First of all, I am also a newcomer to Novice Village, but I can share some of my > [HertzBeat Hertz Beat](https://github.com/dromara/hertzbeat) is a real-time monitoring and alarm system with powerful custom monitoring capabilities and no Agent required. Monitoring of application services, databases, operating systems, middleware, cloud native, etc., threshold alarms, and alarm notifications (email, WeChat, Dingding, Feishu, SMS, Discord, Slack, Telegram). -> We make protocol specifications such as `Http, Jmx, Ssh, Snmp, Jdbc, Prometheus` configurable, and you only need to configure YML to use these protocols to customize and collect any indicators you want to collect. +> We make protocol specifications such as `Http, Jmx, Ssh, Snmp, Jdbc, Prometheus` configurable, and you only need to configure YML to use these protocols to customize and collect any metrics you want to collect. > Do you believe that you can immediately adapt to a new monitoring type such as K8s or Docker just by configuring YML? > The powerful customization of `HertzBeat`, multi-type support, easy expansion, and low coupling, hope to help developers and small and medium-sized teams quickly build their own monitoring tools. diff --git a/home/blog/2023-02-11-monitor-mysql.md b/home/blog/2023-02-11-monitor-mysql.md index 418069b61d..da1f946e60 100644 --- a/home/blog/2023-02-11-monitor-mysql.md +++ b/home/blog/2023-02-11-monitor-mysql.md @@ -20,7 +20,7 @@ Keywords: [Open source monitoring tool, open source database monitoring, Mysql d > HertzBeat is an open source, easy-to-use and friendly real-time monitoring tool that does not require Agent and has powerful custom monitoring capabilities. - Integrate **monitoring-alarm-notification**, support monitoring of application services, databases, operating systems, middleware, cloud native, etc., threshold alarms, alarm notifications (email WeChat Dingding Feishu SMS Slack Discord Telegram). -- It configurable protocol specifications such as Http, Jmx, Ssh, Snmp, Jdbc, Prometheus, etc. You only need to configure YML to use these protocols to customize and collect any indicators you want to collect. Do you believe that you can immediately adapt to a new monitoring type such as K8s or Docker just by configuring YML? +- It configurable protocol specifications such as Http, Jmx, Ssh, Snmp, Jdbc, Prometheus, etc. You only need to configure YML to use these protocols to customize and collect any metrics you want to collect. Do you believe that you can immediately adapt to a new monitoring type such as K8s or Docker just by configuring YML? - HertzBeat's powerful customization, multi-type support, easy expansion, and low coupling, hope to help developers and small and medium teams quickly build their own monitoring tools. ### Get the Mysql database monitoring in HertzBeat in 5 minutes @@ -49,11 +49,11 @@ For other parameters such as **collection interval**, **timeout period**, etc., ![hertzbeat](/img/blog/monitor-mysql-1.png) -4. Click **Operation**->**Monitoring Details Icon** of the monitoring list item to browse the real-time monitoring indicator data of the Mysql database. +4. Click **Operation**->**Monitoring Details Icon** of the monitoring list item to browse the real-time monitoring metric data of the Mysql database. ![hertzbeat](/img/blog/monitor-mysql-3.png) -5. Click **Monitoring History Details TAB** to browse the historical monitoring indicator data chart of Mysql database📈. +5. Click **Monitoring History Details TAB** to browse the historical monitoring metric data chart of Mysql database📈. ![hertzbeat](/img/blog/monitor-mysql-4.png) @@ -61,20 +61,20 @@ For other parameters such as **collection interval**, **timeout period**, etc., - **On the HertzBeat monitoring page, configure the IP port account password and add Mysql monitoring** :::tip -Through the above two steps, we have completed the monitoring of the Mysql database. We can view the monitoring details and indicators in HertzBeat at any time to observe its service status. -Of course, just looking at it is definitely not perfect. Monitoring is often accompanied by alarm thresholds. When the indicators of the Mysql database exceed our expectations or are abnormal, we can promptly notify our corresponding person in charge. The person in charge receives the notification and handles the problem. It is a complete monitoring and alarm process. +Through the above two steps, we have completed the monitoring of the Mysql database. We can view the monitoring details and metrics in HertzBeat at any time to observe its service status. +Of course, just looking at it is definitely not perfect. Monitoring is often accompanied by alarm thresholds. When the metrics of the Mysql database exceed our expectations or are abnormal, we can promptly notify our corresponding person in charge. The person in charge receives the notification and handles the problem. It is a complete monitoring and alarm process. ::: -**Next, we will demonstrate step by step how to configure the threshold alarm notification in the HertzBeat system, so that when the indicators of the Mysql database are found to be abnormal, they will be notified to us in time** +**Next, we will demonstrate step by step how to configure the threshold alarm notification in the HertzBeat system, so that when the metrics of the Mysql database are found to be abnormal, they will be notified to us in time** #### 3. Add Mysql database index threshold alarm in HertzBeat system -1. Configure an alarm threshold for an important indicator +1. Configure an alarm threshold for an important metric Path: Menu -> Threshold Rules -> Add Threshold -- Select the configured indicator object. Mysql database monitoring is mainly about database performance and other related indicators. For example, we set the threshold for the indicator `query cache hit rate` `cache` -> `query_cache_hit_rate`. When the query cache hit rate of Mysql is very low An alarm is issued when it is less than 30%. -- Here we configure to send an alarm when the `query_cache_hit_rate<30` of this indicator `cache`, the alarm level is **serious alarm**, and it will be triggered after three times, as shown in the figure below. +- Select the configured metric object. Mysql database monitoring is mainly about database performance and other related metrics. For example, we set the threshold for the metric `query cache hit rate` `cache` -> `query_cache_hit_rate`. When the query cache hit rate of Mysql is very low An alarm is issued when it is less than 30%. +- Here we configure to send an alarm when the `query_cache_hit_rate<30` of this metric `cache`, the alarm level is **serious alarm**, and it will be triggered after three times, as shown in the figure below. ![hertzbeat](/img/blog/monitor-mysql-5.png) @@ -118,7 +118,7 @@ Content details: mysql db query_cache_hit_rate is too low, now is 20. ## Summary :::tip -This practical article took us to experience how to use the open source real-time monitoring tool HertzBeat to monitor Mysql database indicator data. We can find that HertzBeat, which integrates `monitoring-alarm-notification`, is more convenient in operation and use, just click on the page The Mysql database can be included in the monitoring and alarm notification, and the tedious operations of deploying multiple components and writing configuration files are no longer needed. +This practical article took us to experience how to use the open source real-time monitoring tool HertzBeat to monitor Mysql database metric data. We can find that HertzBeat, which integrates `monitoring-alarm-notification`, is more convenient in operation and use, just click on the page The Mysql database can be included in the monitoring and alarm notification, and the tedious operations of deploying multiple components and writing configuration files are no longer needed. ::: Mysql Github: https://github.com/mysql/mysql-server diff --git a/home/blog/2023-02-15-monitor-linux.md b/home/blog/2023-02-15-monitor-linux.md index 606699eecd..17eff98dbf 100644 --- a/home/blog/2023-02-15-monitor-linux.md +++ b/home/blog/2023-02-15-monitor-linux.md @@ -15,7 +15,7 @@ keywords: [Open source monitoring tool, operating system monitoring, Linux monit > HertzBeat is an open source, easy-to-use and friendly real-time monitoring tool that does not require Agent and has powerful custom monitoring capabilities. - Integrate **monitoring-alarm-notification**, support monitoring of application services, databases, operating systems, middleware, cloud native, etc., threshold alarms, alarm notifications (email WeChat Dingding Feishu SMS Slack Discord Telegram). -- It configurable protocol specifications such as Http, Jmx, Ssh, Snmp, Jdbc, Prometheus, etc. You only need to configure YML to use these protocols to customize and collect any indicators you want to collect. Do you believe that you can immediately adapt to a new monitoring type such as K8s or Docker just by configuring YML? +- It configurable protocol specifications such as Http, Jmx, Ssh, Snmp, Jdbc, Prometheus, etc. You only need to configure YML to use these protocols to customize and collect any metrics you want to collect. Do you believe that you can immediately adapt to a new monitoring type such as K8s or Docker just by configuring YML? - HertzBeat's powerful customization, multi-type support, easy expansion, and low coupling, hope to help developers and small and medium teams quickly build their own monitoring tools. Github: https://github.com/dromara/hertzbeat @@ -45,13 +45,13 @@ For other parameters such as **collection interval**, **timeout period**, etc., ![hertzbeat](/img/blog/monitor-linux-3.png) -4. Click **Operation**->**Monitoring Details Icon** of the monitoring list item to browse the real-time monitoring indicator data of Linux. +4. Click **Operation**->**Monitoring Details Icon** of the monitoring list item to browse the real-time monitoring metric data of Linux. ![hertzbeat](/img/blog/monitor-linux-4.png) ![hertzbeat](/img/blog/monitor-linux-7.png) -5. Click **Monitoring History Details TAB** to browse the historical monitoring indicator data chart of Linux📈. +5. Click **Monitoring History Details TAB** to browse the historical monitoring metric data chart of Linux📈. ![hertzbeat](/img/blog/monitor-linux-5.png) @@ -62,20 +62,20 @@ For other parameters such as **collection interval**, **timeout period**, etc., - **On the HertzBeat monitoring page, configure the IP port account password and add Linux monitoring** :::tip -Through the above two steps, we have completed the monitoring of Linux. We can view the monitoring details and indicators in HertzBeat at any time to observe its service status. -Of course, just looking at it is definitely not perfect. Monitoring is often accompanied by alarm thresholds. When Linux performance indicators exceed our expectations or are abnormal, we can promptly notify our corresponding person in charge. The person in charge receives the notification and handles the problem. It is a complete monitoring and alarm process. +Through the above two steps, we have completed the monitoring of Linux. We can view the monitoring details and metrics in HertzBeat at any time to observe its service status. +Of course, just looking at it is definitely not perfect. Monitoring is often accompanied by alarm thresholds. When Linux performance metrics exceed our expectations or are abnormal, we can promptly notify our corresponding person in charge. The person in charge receives the notification and handles the problem. It is a complete monitoring and alarm process. ::: -**Next, we will demonstrate step by step how to configure threshold alarm notifications in the HertzBeat system, so that when Linux indicators are found to be abnormal, they will be notified to us in time** +**Next, we will demonstrate step by step how to configure threshold alarm notifications in the HertzBeat system, so that when Linux metrics are found to be abnormal, they will be notified to us in time** -#### 3. Add Linux indicator threshold alarm in HertzBeat system +#### 3. Add Linux metric threshold alarm in HertzBeat system -1. Configure an alarm threshold for an important indicator +1. Configure an alarm threshold for an important metric Path: Menu -> Threshold Rules -> Add Threshold -- Select the configured indicator object. Linux monitors mainly related indicators such as cpu, memory, disk, network performance, etc. For example, we set the threshold for the indicator `CPU utilization` `cpu` -> `usage`. When the Linux cpu utilization is greater than 90% When a warning is issued. -- Here we configure to send an alarm when the `usage>90` of this indicator `cpu`, the alarm level is **Warning Alarm**, which will be triggered after three times, as shown in the figure below. +- Select the configured metric object. Linux monitors mainly related metrics such as cpu, memory, disk, network performance, etc. For example, we set the threshold for the metric `CPU utilization` `cpu` -> `usage`. When the Linux cpu utilization is greater than 90% When a warning is issued. +- Here we configure to send an alarm when the `usage>90` of this metric `cpu`, the alarm level is **Warning Alarm**, which will be triggered after three times, as shown in the figure below. ![hertzbeat](/img/blog/monitor-linux-8.png) @@ -119,7 +119,7 @@ Content details: The linux cpu usage is too high. now is 95. ## Summary :::tip -This practical article took us to experience how to use the open source real-time monitoring tool HertzBeat to monitor Linux indicator data. We can find that HertzBeat, which integrates `monitoring-alarm-notification`, is more convenient in operation and use. Linux can be included in the monitoring and alarm notification, and there is no need to deploy multiple components and write configuration files. +This practical article took us to experience how to use the open source real-time monitoring tool HertzBeat to monitor Linux metric data. We can find that HertzBeat, which integrates `monitoring-alarm-notification`, is more convenient in operation and use. Linux can be included in the monitoring and alarm notification, and there is no need to deploy multiple components and write configuration files. ::: > Only one docker command is needed to install and experience heartbeat: @@ -130,7 +130,7 @@ This practical article took us to experience how to use the open source real-tim > [HertzBeat Hertz Beat](https://github.com/dromara/hertzbeat) is a real-time monitoring and alarm system with powerful custom monitoring capabilities and no Agent required. Monitoring of application services, databases, operating systems, middleware, cloud native, etc., threshold alarms, and alarm notifications (email, WeChat, Dingding, Feishu, SMS, Discord, Slack, Telegram). -> We make protocol specifications such as `Http, Jmx, Ssh, Snmp, Jdbc, Prometheus` configurable, and you only need to configure YML to use these protocols to customize and collect any indicators you want to collect. +> We make protocol specifications such as `Http, Jmx, Ssh, Snmp, Jdbc, Prometheus` configurable, and you only need to configure YML to use these protocols to customize and collect any metrics you want to collect. > Do you believe that you can immediately adapt to a new monitoring type such as K8s or Docker just by configuring YML? > The powerful customization of `HertzBeat`, multi-type support, easy expansion, and low coupling, hope to help developers and small and medium-sized teams quickly build their own monitoring tools. diff --git a/home/blog/2023-03-22-monitor-springboot2.md b/home/blog/2023-03-22-monitor-springboot2.md index 1ca06422ff..8ec0fdfe32 100644 --- a/home/blog/2023-03-22-monitor-springboot2.md +++ b/home/blog/2023-03-22-monitor-springboot2.md @@ -30,9 +30,9 @@ Github: https://github.com/dromara/hertzbeat - HertzBeat [Installation and deployment documentation](https://hertzbeat.com/docs/start/docker-deploy) -#### 1. The `actuator` indicator endpoint is exposed on the SpringBoot2 application side, which will provide metrics endpoints data. +#### 1. The `actuator` metric endpoint is exposed on the SpringBoot2 application side, which will provide metrics endpoints data. -1. Open SpringBoot Actuator Endpoint to expose `metrics health env` indicator interface +1. Open SpringBoot Actuator Endpoint to expose `metrics health env` metric interface ```yaml management: @@ -46,7 +46,7 @@ management: enabled-by-default: on ``` -2. After restarting, test whether the access indicator interface `ip:port/actuator` has response json data as follows: +2. After restarting, test whether the access metric interface `ip:port/actuator` has response json data as follows: ```json { @@ -102,11 +102,11 @@ For other parameters such as **collection interval**, **timeout period**, etc., ![hertzbeat](/img/blog/monitor-springboot2-3.png) -4. Click **Operation**->**Monitoring Details Icon** of the monitoring list item to browse the real-time monitoring indicator data of the SpringBoot2 application. +4. Click **Operation**->**Monitoring Details Icon** of the monitoring list item to browse the real-time monitoring metric data of the SpringBoot2 application. ![hertzbeat](/img/blog/monitor-springboot2-4.png) -5. Click **Monitoring History Details TAB** to browse the historical monitoring indicator data chart of the SpringBoot2 application📈. +5. Click **Monitoring History Details TAB** to browse the historical monitoring metric data chart of the SpringBoot2 application📈. ![hertzbeat](/img/blog/monitor-springboot2-5.png) @@ -116,20 +116,20 @@ For other parameters such as **collection interval**, **timeout period**, etc., :::tip -Through the above, we have completed the monitoring of the SpringBoot2 application. We can check the status and availability of various indicators of the SpringBoot2 application at any time in HertzBeat. -Of course, it is impossible to manually check the indicators in real time. Monitoring is often accompanied by alarm thresholds. When the performance indicators of the SpringBoot2 application exceed our threshold or the SpringBoot2 application itself is abnormal, we can promptly notify our corresponding person in charge. The person in charge receives the notification and handles it. , this is a complete monitoring and alarm process. +Through the above, we have completed the monitoring of the SpringBoot2 application. We can check the status and availability of various metrics of the SpringBoot2 application at any time in HertzBeat. +Of course, it is impossible to manually check the metrics in real time. Monitoring is often accompanied by alarm thresholds. When the performance metrics of the SpringBoot2 application exceed our threshold or the SpringBoot2 application itself is abnormal, we can promptly notify our corresponding person in charge. The person in charge receives the notification and handles it. , this is a complete monitoring and alarm process. ::: -**Next, we will demonstrate step by step how to configure the threshold alarm notification in the HertzBeat system. When the indicators of the SpringBoot2 application are abnormal, we will be notified in time** +**Next, we will demonstrate step by step how to configure the threshold alarm notification in the HertzBeat system. When the metrics of the SpringBoot2 application are abnormal, we will be notified in time** -#### 3. Add SpringBoot2 application indicator threshold alarm in HertzBeat system +#### 3. Add SpringBoot2 application metric threshold alarm in HertzBeat system -1. Configure an alarm threshold for an important indicator +1. Configure an alarm threshold for an important metric Path: Menu -> Threshold Rules -> Add Threshold -- Select the configured indicator object. SpringBoot2 application monitoring mainly focuses on stack memory threads and other related indicators. For example, we set the threshold for the indicator `threads` -> `threads`. When the number of threads in the `runnable` state is greater than At 300 an alert is issued. -- Here we configure to send an alarm when `size`, `state` of `equals(state, "runnable"") && size>300` of this indicator, the alarm level is **warning alarm**, which will be triggered three times, specifically As shown below. +- Select the configured metric object. SpringBoot2 application monitoring mainly focuses on stack memory threads and other related metrics. For example, we set the threshold for the metric `threads` -> `threads`. When the number of threads in the `runnable` state is greater than At 300 an alert is issued. +- Here we configure to send an alarm when `size`, `state` of `equals(state, "runnable"") && size>300` of this metric, the alarm level is **warning alarm**, which will be triggered three times, specifically As shown below. ![hertzbeat](/img/blog/monitor-springboot2-6.png) @@ -173,7 +173,7 @@ Content details: The springboot2 service's runnable state threads num is over 30 ## Summary :::tip -This practical article took us to experience how to use the open source real-time monitoring tool HertzBeat to monitor SpringBoot2 application indicator data. We can find that HertzBeat, which integrates `monitoring-alarm-notification`, is more convenient in operation and use, just click a little on the page The SpringBoot2 application can be included in the monitoring and alarm notification, and the tedious operations of deploying multiple components and writing configuration files are no longer needed. +This practical article took us to experience how to use the open source real-time monitoring tool HertzBeat to monitor SpringBoot2 application metric data. We can find that HertzBeat, which integrates `monitoring-alarm-notification`, is more convenient in operation and use, just click a little on the page The SpringBoot2 application can be included in the monitoring and alarm notification, and the tedious operations of deploying multiple components and writing configuration files are no longer needed. ::: > Only one docker command is needed to install and experience heartbeat: @@ -182,7 +182,7 @@ This practical article took us to experience how to use the open source real-tim ## More powerful -> Through the simple steps above, we have realized the monitoring of SpringBoot2, but the built-in indicators in it do not meet the needs. Can we customize and monitor more indicators of SpringBoot2? The answer is of course yes, through **Monitoring Definition**->**SpringBoot2** on the page, you can customize and modify the performance indicators you want to monitor by editing the following YML configuration file at any time. +> Through the simple steps above, we have realized the monitoring of SpringBoot2, but the built-in metrics in it do not meet the needs. Can we customize and monitor more metrics of SpringBoot2? The answer is of course yes, through **Monitoring Definition**->**SpringBoot2** on the page, you can customize and modify the performance metrics you want to monitor by editing the following YML configuration file at any time. ![hertzbeat](/img/blog/monitor-springboot2-8.png) diff --git a/home/blog/2023-07-05-hertzbeat-v1.3.2.md b/home/blog/2023-07-05-hertzbeat-v1.3.2.md index 0713c96c32..8ab5a9abbc 100644 --- a/home/blog/2023-07-05-hertzbeat-v1.3.2.md +++ b/home/blog/2023-07-05-hertzbeat-v1.3.2.md @@ -40,7 +40,7 @@ Hi guys! Major release. HertzBeat v1.3.2 has published. **This delightful version came out of the hard work of 27 friends. Thank them! Love 💗** -In this version, we support new monitoring types and indicators for **freebsd, debian, opensuse, redhat, apache doris**, etc. +In this version, we support new monitoring types and metrics for **freebsd, debian, opensuse, redhat, apache doris**, etc. - Support WEB page configuration mail server, replace the previous file configuration - Supports alarm convergence. If repeated alarms are frequently sent, it will be resolved immediately with alarm convergence diff --git a/home/docs/advanced/extend-http-default.md b/home/docs/advanced/extend-http-default.md index 210422964a..6e267a00e4 100644 --- a/home/docs/advanced/extend-http-default.md +++ b/home/docs/advanced/extend-http-default.md @@ -117,7 +117,7 @@ metrics: # The smaller Metric group scheduling priority(0-127), the higher the priority. After completion of the high priority Metric group collection,the low priority Metric group will then be scheduled. Metric groups with the same priority will be scheduled in parallel. # Metric group with a priority of 0 is an availability group which will be scheduled first. If the collection succeeds, the scheduling will continue otherwise interrupt scheduling. priority: 0 - # Specific monitoring Metrics in the Metric group + # metrics fields list fields: # Metric information include field: name type: field type(0-number: number, 1-string: string) nstance: primary key of instance or not unit: Metric unit - field: hostname diff --git a/home/docs/advanced/extend-http-example-hertzbeat.md b/home/docs/advanced/extend-http-example-hertzbeat.md index d1df47e4b5..1251fa6ec7 100644 --- a/home/docs/advanced/extend-http-example-hertzbeat.md +++ b/home/docs/advanced/extend-http-example-hertzbeat.md @@ -9,9 +9,9 @@ Through this tutorial, we describe step by step how to add a monitoring type bas Before reading this tutorial, we hope that you are familiar with how to customize types, metrics, protocols, etc. from [Custom Monitoring](extend-point) and [http Protocol Customization](extend-http). -### HTTP protocol parses the general response structure to obtain indicator data +### HTTP protocol parses the general response structure to obtain metric data -> In many scenarios, we need to monitor the provided HTTP API interface and obtain the index value returned by the interface. In this article, we use the http custom protocol to parse our common http interface response structure, and obtain the fields in the returned body as indicator data. +> In many scenarios, we need to monitor the provided HTTP API interface and obtain the index value returned by the interface. In this article, we use the http custom protocol to parse our common http interface response structure, and obtain the fields in the returned body as metric data. ``` @@ -56,7 +56,7 @@ As above, usually our background API interface will design such a general return } ``` -**This time we get the indicator data such as `category`, `app`, `status`, `size`, `availableSize` under the app. ** +**This time we get the metric data such as `category`, `app`, `status`, `size`, `availableSize` under the app. ** ### Add custom monitoring template `hertzbeat` @@ -152,12 +152,12 @@ metrics: # the first metrics summary # attention: Built-in monitoring metrics contains (responseTime - Response time) - name: summary - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue priority: 0 # collect metrics content fields: - # metrics content contains field-metric name, type-metric type:0-number,1-string, instance-if is metrics group, unit-metric unit('%','ms','MB') + # metrics content contains field-metric name, type-metric type:0-number,1-string, instance-if is metrics, unit-metric unit('%','ms','MB') - field: app type: 1 label: true @@ -214,7 +214,7 @@ metrics: ![](/img/docs/advanced/extend-http-example-3.png) -> After a certain period of time (depending on the collection cycle), we can see the specific indicator data and historical charts in the monitoring details! +> After a certain period of time (depending on the collection cycle), we can see the specific metric data and historical charts in the monitoring details! ![](/img/docs/advanced/extend-http-example-4.png) diff --git a/home/docs/advanced/extend-http-example-token.md b/home/docs/advanced/extend-http-example-token.md index fb5e7f4594..f81a8d13e9 100644 --- a/home/docs/advanced/extend-http-example-token.md +++ b/home/docs/advanced/extend-http-example-token.md @@ -4,13 +4,13 @@ title: Tutorial 2 Obtain TOKEN index value based on HTTP protocol for subsequent sidebar_label: Tutorial 2 Get TOKEN for subsequent authentication --- -Through this tutorial, we will describe step by step how to modify on the basis of tutorial 1, add an metrics group, first call the authentication interface to obtain the TOKEN, and use the TOKEN as a parameter for the subsequent indicator group collection and authentication. +Through this tutorial, we will describe step by step how to modify on the basis of tutorial 1, add an metrics, first call the authentication interface to obtain the TOKEN, and use the TOKEN as a parameter for the subsequent metrics collection and authentication. -Before reading this tutorial, we hope that you are familiar with how to customize types, indicators, protocols, etc. from [Custom Monitoring](extend-point) and [http Protocol Customization](extend-http). +Before reading this tutorial, we hope that you are familiar with how to customize types, metrics, protocols, etc. from [Custom Monitoring](extend-point) and [http Protocol Customization](extend-http). ### Request process -【**Authentication information indicator group (highest priority)**】【**HTTP interface carries account password call**】->【**Response data analysis**】->【**Analysis and issuance of TOKEN-accessToken as an indicator **] -> [**Assign accessToken as a variable parameter to other collection index groups**] +【**Authentication information metrics (highest priority)**】【**HTTP interface carries account password call**】->【**Response data analysis**】->【**Analysis and issuance of TOKEN-accessToken as an metric **] -> [**Assign accessToken as a variable parameter to other collection index groups**] > Here we still use the hertzbeat monitoring example of Tutorial 1! The hertzbeat background interface not only supports the basic direct account password authentication used in Tutorial 1, but also supports token authentication. @@ -108,7 +108,7 @@ metrics: .... ``` -### Define metrics group `auth` login request to get `token` +### Define metrics `auth` login request to get `token` 1. Add an index group definition `auth` in `hertzbeat_token`, set the collection priority to the highest 0, and collect the index `token`. @@ -165,17 +165,17 @@ params: type: textarea placeholder: 'Available When POST PUT' required: false -# List of indicator groups +# List of metricss metrics: # The first monitoring index group auth - # Note: Built-in monitoring indicators have (responseTime - response time) + # Note: Built-in monitoring metrics have (responseTime - response time) - name: auth # The smaller the index group scheduling priority (0-127), the higher the priority, and the index group with low priority will not be scheduled until the collection of index groups with high priority is completed, and the index groups with the same priority will be scheduled and collected in parallel - # The indicator group with priority 0 is the availability indicator group, that is, it will be scheduled first, and other indicator groups will continue to be scheduled if the collection is successful, and the scheduling will be interrupted if the collection fails + # The metrics with priority 0 is the availability metrics, that is, it will be scheduled first, and other metricss will continue to be scheduled if the collection is successful, and the scheduling will be interrupted if the collection fails priority: 0 - # Specific monitoring indicators in the indicator group + # Specific monitoring metrics in the metrics fields: - # Indicator information includes field name type field type: 0-number, 1-string whether instance is the primary key of the instance unit: indicator unit + # metric information includes field name type field type: 0-number, 1-string whether instance is the primary key of the instance unit: metric unit - field: token type: 1 - field: refreshToken @@ -197,7 +197,7 @@ metrics: # request header content headers: content-type: ^_^contentType^_^ - # Response data analysis method: default-system rules, jsonPath-jsonPath script, website-website usability indicator monitoring + # Response data analysis method: default-system rules, jsonPath-jsonPath script, website-website usability metric monitoring parseType: jsonPath parseScript: '$.data' @@ -215,7 +215,7 @@ metrics: ![](/img/docs/advanced/extend-http-example-5.png) -** After the addition is successful, we can see the `token`, `refreshToken` indicator data we collected on the details page. ** +** After the addition is successful, we can see the `token`, `refreshToken` metric data we collected on the details page. ** ![](/img/docs/advanced/extend-http-example-6.png) @@ -223,7 +223,7 @@ metrics: -### Use `token` as a variable parameter to collect and use the following indicator groups +### Use `token` as a variable parameter to collect and use the following metricss **Add an index group definition `summary` in `app-hertzbeat_token.yml`, which is the same as `summary` in Tutorial 1, and set the collection priority to 1** @@ -295,17 +295,17 @@ params: type: textarea placeholder: 'Available When POST PUT' required: false -# List of indicator groups +# List of metricss metrics: # The first monitoring index group cpu -# Note: Built-in monitoring indicators have (responseTime - response time) +# Note: Built-in monitoring metrics have (responseTime - response time) - name: auth # The smaller the index group scheduling priority (0-127), the higher the priority, and the index group with low priority will not be scheduled until the collection of index groups with high priority is completed, and the index groups with the same priority will be scheduled and collected in parallel - # The indicator group with priority 0 is the availability indicator group, that is, it will be scheduled first, and other indicator groups will continue to be scheduled if the collection is successful, and the scheduling will be interrupted if the collection fails + # The metrics with priority 0 is the availability metrics, that is, it will be scheduled first, and other metricss will continue to be scheduled if the collection is successful, and the scheduling will be interrupted if the collection fails priority: 0 - # Specific monitoring indicators in the indicator group + # Specific monitoring metrics in the metrics fields: - # Indicator information includes field name type field type: 0-number, 1-string whether instance is the primary key of the instance unit: indicator unit + # metric information includes field name type field type: 0-number, 1-string whether instance is the primary key of the instance unit: metric unit - field: token type: 1 - field: refreshToken @@ -331,18 +331,18 @@ metrics: # Request parameter content params: ^_^params^_^: ^_^params^_^ - # Response data analysis method: default-system rules, jsonPath-jsonPath script, website-website usability indicator monitoring + # Response data analysis method: default-system rules, jsonPath-jsonPath script, website-website usability metric monitoring parseType: jsonPath parseScript: '$.data' - name: summary # The smaller the index group scheduling priority (0-127), the higher the priority, and the index group with low priority will not be scheduled until the collection of index groups with high priority is completed, and the index groups with the same priority will be scheduled and collected in parallel - # The indicator group with priority 0 is the availability indicator group, that is, it will be scheduled first, and other indicator groups will continue to be scheduled if the collection is successful, and the scheduling will be interrupted if the collection fails + # The metrics with priority 0 is the availability metrics, that is, it will be scheduled first, and other metricss will continue to be scheduled if the collection is successful, and the scheduling will be interrupted if the collection fails priority: 1 - # Specific monitoring indicators in the indicator group + # Specific monitoring metrics in the metrics fields: - # Indicator information includes field name type field type: 0-number, 1-string whether instance is the primary key of the instance unit: indicator unit + # metric information includes field name type field type: 0-number, 1-string whether instance is the primary key of the instance unit: metric unit - field: category type: 1 - field: app @@ -369,7 +369,7 @@ metrics: # Authentication methods: Basic Auth, Digest Auth, Bearer Token type: Bearer Token bearerTokenToken: ^o^token^o^ - # Response data analysis method: default-system rules, jsonPath-jsonPath script, website-website usability indicator monitoring + # Response data analysis method: default-system rules, jsonPath-jsonPath script, website-website usability metric monitoring parseType: jsonPath parseScript: '$.data.apps.*' diff --git a/home/docs/advanced/extend-http-jsonpath.md b/home/docs/advanced/extend-http-jsonpath.md index c39190fd97..8ae3faec29 100644 --- a/home/docs/advanced/extend-http-jsonpath.md +++ b/home/docs/advanced/extend-http-jsonpath.md @@ -136,7 +136,7 @@ metrics: # The smaller Metric group scheduling priority(0-127), the higher the priority. After completion of the high priority Metric group collection,the low priority Metric group will then be scheduled. Metric groups with the same priority will be scheduled in parallel. # Metric group with a priority of 0 is an availability group which will be scheduled first. If the collection succeeds, the scheduling will continue otherwise interrupt scheduling. priority: 0 - # Specific monitoring Metrics in the Metric group + # metrics fields list fields: # Metric information include field: name type: field type(0-number: number, 1-string: string) nstance: primary key of instance or not unit: Metric unit - field: type diff --git a/home/docs/advanced/extend-http.md b/home/docs/advanced/extend-http.md index 039f239ca4..a3b44c22bc 100644 --- a/home/docs/advanced/extend-http.md +++ b/home/docs/advanced/extend-http.md @@ -112,7 +112,7 @@ metrics: # The smaller Metric group scheduling priority(0-127), the higher the priority. After completion of the high priority Metric group collection,the low priority Metric group will then be scheduled. Metric groups with the same priority will be scheduled in parallel. # Metric group with a priority of 0 is an availability group which will be scheduled first. If the collection succeeds, the scheduling will continue otherwise interrupt scheduling. priority: 0 - # Specific monitoring Metrics in the Metric group + # metrics fields list fields: # Metric information include field: name type: field type(0-number: number, 1-string: string) nstance: primary key of instance or not unit: Metric unit - field: hostname diff --git a/home/docs/advanced/extend-jdbc.md b/home/docs/advanced/extend-jdbc.md index 25d30ae2c8..3c930c8075 100644 --- a/home/docs/advanced/extend-jdbc.md +++ b/home/docs/advanced/extend-jdbc.md @@ -120,7 +120,7 @@ metrics: # The smaller Metric group scheduling priority(0-127), the higher the priority. After completion of the high priority Metric group collection,the low priority Metric group will then be scheduled. Metric groups with the same priority will be scheduled in parallel. # Metric group with a priority of 0 is an availability group which will be scheduled first. If the collection succeeds, the scheduling will continue otherwise interrupt scheduling. priority: 0 - # Specific monitoring Metrics in the Metric group + # metrics fields list fields: # Metric information include field: name type: field type(0-number: number, 1-string: string) instance: primary key of instance or not unit: Metric unit - field: version diff --git a/home/docs/advanced/extend-jmx.md b/home/docs/advanced/extend-jmx.md index 3fec909213..c557e2577f 100644 --- a/home/docs/advanced/extend-jmx.md +++ b/home/docs/advanced/extend-jmx.md @@ -113,12 +113,12 @@ params: metrics: # metrics - basic - name: basic - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue priority: 0 # collect metrics content fields: - # field-metric name, type-metric type(0-number,1-string), unit-metric unit('%','ms','MB'), instance-if is metrics group unique identifier + # field-metric name, type-metric type(0-number,1-string), unit-metric unit('%','ms','MB'), instance-if is metrics unique identifier - field: VmName type: 1 - field: VmVendor diff --git a/home/docs/advanced/extend-point.md b/home/docs/advanced/extend-point.md index 3b1176015e..2d0e4a12e5 100644 --- a/home/docs/advanced/extend-point.md +++ b/home/docs/advanced/extend-point.md @@ -102,12 +102,12 @@ params: metrics: # metrics - summary, inner monitoring metrics (responseTime - response time, keyword - number of keywords) - name: summary - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue priority: 0 # collect metrics content fields: - # field-metric name, type-metric type(0-number,1-string), unit-metric unit('%','ms','MB'), instance-if is metrics group unique identifier + # field-metric name, type-metric type(0-number,1-string), unit-metric unit('%','ms','MB'), instance-if is metrics unique identifier - field: responseTime type: 0 unit: ms diff --git a/home/docs/advanced/extend-snmp.md b/home/docs/advanced/extend-snmp.md index 5be5939320..dac0dfe1b1 100644 --- a/home/docs/advanced/extend-snmp.md +++ b/home/docs/advanced/extend-snmp.md @@ -122,12 +122,12 @@ params: metrics: # metrics - system - name: system - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue priority: 0 # collect metrics content fields: - # field-metric name, type-metric type(0-number,1-string), unit-metric unit('%','ms','MB'), instance-if is metrics group unique identifier + # field-metric name, type-metric type(0-number,1-string), unit-metric unit('%','ms','MB'), instance-if is metrics unique identifier - field: name type: 1 - field: descr diff --git a/home/docs/advanced/extend-ssh.md b/home/docs/advanced/extend-ssh.md index 245156a0b1..530974ea4d 100644 --- a/home/docs/advanced/extend-ssh.md +++ b/home/docs/advanced/extend-ssh.md @@ -117,7 +117,7 @@ metrics: # The smaller Metric group scheduling priority(0-127), the higher the priority. After completion of the high priority Metric group collection,the low priority Metric group will then be scheduled. Metric groups with the same priority will be scheduled in parallel. # Metric group with a priority of 0 is an availability group which will be scheduled first. If the collection succeeds, the scheduling will continue otherwise interrupt scheduling. priority: 0 - # Specific monitoring Metrics in the Metric group + # metrics fields list fields: # Metric information include field: name type: field type(0-number: number, 1-string: string) instance: primary key of instance or not unit: Metric unit - field: hostname diff --git a/home/docs/advanced/extend-tutorial.md b/home/docs/advanced/extend-tutorial.md index 9caabcd423..f31a6c99ac 100644 --- a/home/docs/advanced/extend-tutorial.md +++ b/home/docs/advanced/extend-tutorial.md @@ -11,7 +11,7 @@ Before reading this tutorial, we hope that you are familiar with how to customiz ### HTTP protocol parses the general response structure to obtain metrics data -> In many scenarios, we need to monitor the provided HTTP API interface and obtain the index value returned by the interface. In this article, we use the http custom protocol to parse our common http interface response structure, and obtain the fields in the returned body as indicator data. +> In many scenarios, we need to monitor the provided HTTP API interface and obtain the index value returned by the interface. In this article, we use the http custom protocol to parse our common http interface response structure, and obtain the fields in the returned body as metric data. ``` @@ -152,12 +152,12 @@ metrics: # the first metrics summary # attention: Built-in monitoring metrics contains (responseTime - Response time) - name: summary - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue priority: 0 # collect metrics content fields: - # metrics content contains field-metric name, type-metric type:0-number,1-string, instance-if is metrics group, unit-metric unit('%','ms','MB') + # metrics content contains field-metric name, type-metric type:0-number,1-string, instance-if is metrics, unit-metric unit('%','ms','MB') - field: app type: 1 label: true @@ -213,7 +213,7 @@ metrics: ![](/img/docs/advanced/extend-http-example-3.png) -> After a certain period of time (depending on the collection cycle), we can see the specific indicator data and historical charts in the monitoring details! +> After a certain period of time (depending on the collection cycle), we can see the specific metric data and historical charts in the monitoring details! ![](/img/docs/advanced/extend-http-example-4.png) diff --git a/home/docs/help/activemq.md b/home/docs/help/activemq.md index 1bf72231df..52e3090fde 100644 --- a/home/docs/help/activemq.md +++ b/home/docs/help/activemq.md @@ -66,7 +66,7 @@ ACTIVEMQ_SUNJMX_START="$ACTIVEMQ_SUNJMX_START -Dcom.sun.management.jmxremote" ### Collect Metrics -#### Metrics Group: broker +#### metrics: broker | Metric Name | Unit | Description | |-------------------------|------|-----------------------------------------------------------------------| @@ -89,7 +89,7 @@ ACTIVEMQ_SUNJMX_START="$ACTIVEMQ_SUNJMX_START -Dcom.sun.management.jmxremote" | MaxMessageSize | None | Max message size on this broker | | MinMessageSize | None | Min message size on this broker | -#### Metrics Group: topic +#### metrics: topic | Metric Name | Unit | Description | |-------------------------|------|-------------------------------------------------------------------------------------------| @@ -114,7 +114,7 @@ ACTIVEMQ_SUNJMX_START="$ACTIVEMQ_SUNJMX_START -Dcom.sun.management.jmxremote" | MinMessageSize | B | Min message size on this destination | -#### Metrics Group: memory_pool +#### metrics: memory_pool | Metric Name | Unit | Description | |-------------| ----------- |----------------| @@ -124,7 +124,7 @@ ACTIVEMQ_SUNJMX_START="$ACTIVEMQ_SUNJMX_START -Dcom.sun.management.jmxremote" | max | kb | max size | | used | kb | used size | -#### Metrics Group: class_loading +#### metrics: class_loading | Metric Name | Unit | Description | |-----------------------| ----------- | ----------- | @@ -133,7 +133,7 @@ ACTIVEMQ_SUNJMX_START="$ACTIVEMQ_SUNJMX_START -Dcom.sun.management.jmxremote" | UnloadedClassCount | | Unloaded Class Count | -#### Metrics Group: thread +#### metrics: thread | Metric Name | Unit | Description | |-------------------------| ----------- | ----------- | diff --git a/home/docs/help/rabbitmq.md b/home/docs/help/rabbitmq.md index fd06687369..1bcd3ea585 100644 --- a/home/docs/help/rabbitmq.md +++ b/home/docs/help/rabbitmq.md @@ -9,7 +9,7 @@ keywords: [open source monitoring tool, open source rabbitmq monitoring tool, mo ### Pre-monitoring Operations -> HertzBeat uses RabbitMQ Management's Rest Api to collect RabbitMQ indicator data. +> HertzBeat uses RabbitMQ Management's Rest Api to collect RabbitMQ metric data. > Therefore, you need to enable the Management plug-in in your RabbitMQ environment 1. Open the Management plugin, or use the self-opening version @@ -38,7 +38,7 @@ rabbitmq-plugins enable rabbitmq_management ### Collect Metrics -#### Metrics Group: overview +#### metrics: overview | Metric Name | Metric Unit | Metric Description | |--------------------|-------------|------------------------------------| @@ -50,7 +50,7 @@ rabbitmq-plugins enable rabbitmq_management | cluster_name | None | Cluster name | | rates_mode | None | rates mode | -#### Metrics Group: object_totals +#### metrics: object_totals | Metric Name | Metric Unit | Metric Description | |-------------|-------------|-----------------------------| @@ -60,7 +60,7 @@ rabbitmq-plugins enable rabbitmq_management | exchanges | none | total number of exchanges | | queues | none | total number of queues | -#### Metrics Group: nodes +#### metrics: nodes | Metric Name | Metric Unit | Metric Description | |--------------------|-------------|-----------------------------------------------------------| @@ -101,7 +101,7 @@ rabbitmq-plugins enable rabbitmq_management | connection_closed | None | connection closed num | -#### Metrics Group: queues +#### metrics: queues | Metric Name | Metric Unit | Metric Description | |------------------------------|-------------|--------------------------------------------------------------------------------------------------------------------------------------| diff --git a/home/docs/start/custom-config.md b/home/docs/start/custom-config.md index c8d616396d..91282bf505 100644 --- a/home/docs/start/custom-config.md +++ b/home/docs/start/custom-config.md @@ -39,9 +39,9 @@ alerter: console-url: https://console.tancloud.cn ``` -3. Use external redis instead of memory to store real-time indicator data +3. Use external redis instead of memory to store real-time metric data -> By default, the real-time data of our indicators is stored in memory, which can be configured as follows to use redis instead of memory storage. +> By default, the real-time data of our metrics is stored in memory, which can be configured as follows to use redis instead of memory storage. Note ⚠️ `memory.enabled: false, redis.enabled: true` ```yaml diff --git a/home/docs/start/docker-deploy.md b/home/docs/start/docker-deploy.md index 2cd15d7f12..20276a5aea 100644 --- a/home/docs/start/docker-deploy.md +++ b/home/docs/start/docker-deploy.md @@ -34,8 +34,8 @@ sidebar_label: Install via Docker You can modify the configuration yml file according to your needs. - If you need to use email to send alarms, you need to replace the email server parameters `spring.mail` in `application.yml` - **Recommended** If you need to use an external Mysql database to replace the built-in H2 database, you need to replace the `spring.datasource` parameter in `application.yml` For specific steps, see [Using Mysql to replace H2 database](mysql-change) - - **Recommended** If you need to use the time series database TDengine to store indicator data, you need to replace the `warehouse.store.td-engine` parameter in `application.yml` for specific steps, see [Using TDengine to store metrics data](tdengine-init) - - **Recommended** If you need to use the time series database IotDB to store the indicator database, you need to replace the `warehouse.storeiot-db` parameter in `application.yml` For specific steps, see [Use IotDB to store metrics data](iotdb-init) + - **Recommended** If you need to use the time series database TDengine to store metric data, you need to replace the `warehouse.store.td-engine` parameter in `application.yml` for specific steps, see [Using TDengine to store metrics data](tdengine-init) + - **Recommended** If you need to use the time series database IotDB to store the metric database, you need to replace the `warehouse.storeiot-db` parameter in `application.yml` For specific steps, see [Use IotDB to store metrics data](iotdb-init) 4. Mounted the account file(optional) HertzBeat default built-in three user accounts, respectively `admin/hertzbeat tom/hertzbeat guest/hertzbeat` diff --git a/home/docs/start/iotdb-init.md b/home/docs/start/iotdb-init.md index 885ef4e082..52950a7b4d 100644 --- a/home/docs/start/iotdb-init.md +++ b/home/docs/start/iotdb-init.md @@ -6,7 +6,7 @@ sidebar_label: Use IoTDB Store Metrics HertzBeat's historical data storage relies on the time series database IoTDB or TDengine, you can choose one of them to install and initialize, or not to install (note ⚠️ but it is strongly recommended to configure in the production environment) -Apache IoTDB is a software system that integrates the collection, storage, management and analysis of time series data of the Internet of Things. We use it to store and analyze the historical data of monitoring indicators collected. Support V0.13+ version and V1.0.+ version. +Apache IoTDB is a software system that integrates the collection, storage, management and analysis of time series data of the Internet of Things. We use it to store and analyze the historical data of monitoring metrics collected. Support V0.13+ version and V1.0.+ version. **Note⚠️ Time series database is optional, but production environment configuration is strongly recommended to provide more complete historical chart functions and high performance** **⚠️ If you do not configure a time series database, only the last hour of historical data is retained.** diff --git a/home/docs/start/package-deploy.md b/home/docs/start/package-deploy.md index 60ef163c0a..38dc6301ff 100644 --- a/home/docs/start/package-deploy.md +++ b/home/docs/start/package-deploy.md @@ -20,8 +20,8 @@ sidebar_label: Install via Package Modify the configuration file `hertzbeat/config/application.yml` params according to your needs. - If you need to use email to send alarms, you need to replace the email server parameters `spring.mail` in `application.yml` - **Recommended** If you need to use an external Mysql database to replace the built-in H2 database, you need to replace the `spring.datasource` parameter in `application.yml` For specific steps, see [Using Mysql to replace H2 database](mysql-change) - - **Recommended** If you need to use the time series database TDengine to store indicator data, you need to replace the `warehouse.store.td-engine` parameter in `application.yml` for specific steps, see [Using TDengine to store metrics data](tdengine-init) - - **Recommended** If you need to use the time series database IotDB to store the indicator database, you need to replace the `warehouse.storeiot-db` parameter in `application.yml` For specific steps, see [Use IotDB to store metrics data](iotdb-init) + - **Recommended** If you need to use the time series database TDengine to store metric data, you need to replace the `warehouse.store.td-engine` parameter in `application.yml` for specific steps, see [Using TDengine to store metrics data](tdengine-init) + - **Recommended** If you need to use the time series database IotDB to store the metric database, you need to replace the `warehouse.storeiot-db` parameter in `application.yml` For specific steps, see [Use IotDB to store metrics data](iotdb-init) 3. Configure the account file(optional) HertzBeat default built-in three user accounts, respectively `admin/hertzbeat tom/hertzbeat guest/hertzbeat` diff --git a/home/docs/start/sslcert-practice.md b/home/docs/start/sslcert-practice.md index 70728f8fe3..0bf0fcb419 100644 --- a/home/docs/start/sslcert-practice.md +++ b/home/docs/start/sslcert-practice.md @@ -45,7 +45,7 @@ gitee: https://gitee.com/dromara/hertzbeat 3. View the detection index data -> In the monitoring list, you can view the monitoring status, and in the monitoring details, you can view the indicator data chart, etc. +> In the monitoring list, you can view the monitoring status, and in the monitoring details, you can view the metric data chart, etc. ![](/img/docs/start/ssl_3.png) @@ -60,7 +60,7 @@ gitee: https://gitee.com/dromara/hertzbeat ![](/img/docs/start/ssl_4.png) -> Configure the threshold, select the SSL certificate indicator object, configure the alarm expression-triggered when the indicator `expired` is `true`, that is, `equals(expired,"true")`, set the alarm level notification template information, etc. +> Configure the threshold, select the SSL certificate metric object, configure the alarm expression-triggered when the metric `expired` is `true`, that is, `equals(expired,"true")`, set the alarm level notification template information, etc. ![](/img/docs/start/ssl_5.png) @@ -73,7 +73,7 @@ gitee: https://gitee.com/dromara/hertzbeat 5. Set the threshold (triggered one week before the certificate expires) -> In the same way, add a new configuration threshold and configure an alarm expression - when the indicator expires timestamp `end_timestamp`, the `now()` function is the current timestamp, if the configuration triggers an alarm one week in advance: `end_timestamp <= (now( ) + 604800000)` , where `604800000` is the 7-day total time difference in milliseconds. +> In the same way, add a new configuration threshold and configure an alarm expression - when the metric expires timestamp `end_timestamp`, the `now()` function is the current timestamp, if the configuration triggers an alarm one week in advance: `end_timestamp <= (now( ) + 604800000)` , where `604800000` is the 7-day total time difference in milliseconds. ![](/img/docs/start/ssl_7.png) diff --git a/home/docs/start/tdengine-init.md b/home/docs/start/tdengine-init.md index 1a851fea3c..c190f9eae1 100644 --- a/home/docs/start/tdengine-init.md +++ b/home/docs/start/tdengine-init.md @@ -6,7 +6,7 @@ sidebar_label: Use TDengine Store Metrics HertzBeat's historical data storage depends on the time series database TDengine or IoTDB, choose one of them to install and initialize, or not to install (note ⚠️ but it is strongly recommended to configure in the production environment) -TDengine is an open-source IoT time-series database, which we use to store the collected historical data of monitoring indicators. Pay attention to support ⚠️ 3.x version. +TDengine is an open-source IoT time-series database, which we use to store the collected historical data of monitoring metrics. Pay attention to support ⚠️ 3.x version. **Note⚠️ Time series database is optional, but production environment configuration is strongly recommended to provide more complete historical chart functions and high performance** **⚠️ If you do not configure a time series database, only the last hour of historical data is retained.** diff --git a/home/docs/start/upgrade.md b/home/docs/start/upgrade.md index 99fd2cb740..f8e020f905 100644 --- a/home/docs/start/upgrade.md +++ b/home/docs/start/upgrade.md @@ -11,7 +11,7 @@ sidebar_label: Version Upgrade Guide - [DockerHub Release](https://hub.docker.com/r/tancloud/hertzbeat/tags) - [Docker quay.io Release](https://quay.io/repository/tancloud/hertzbeat?tab=tags) -HertzBeat's metadata information is stored in H2 or Mysql, PostgreSQL relational databases, and the collected indicator data is stored in time series databases such as TDengine and IotDB. +HertzBeat's metadata information is stored in H2 or Mysql, PostgreSQL relational databases, and the collected metric data is stored in time series databases such as TDengine and IotDB. **You need to save and back up the data files of the database and monitoring templates yml files before upgrading** diff --git a/home/i18n/en/docusaurus-plugin-content-docs/version-v1.1.x/advanced/extend-http-default.md b/home/i18n/en/docusaurus-plugin-content-docs/version-v1.1.x/advanced/extend-http-default.md index 30843c8d8a..f335d3e68a 100644 --- a/home/i18n/en/docusaurus-plugin-content-docs/version-v1.1.x/advanced/extend-http-default.md +++ b/home/i18n/en/docusaurus-plugin-content-docs/version-v1.1.x/advanced/extend-http-default.md @@ -117,7 +117,7 @@ metrics: # The smaller Metric group scheduling priority(0-127), the higher the priority. After completion of the high priority Metric group collection,the low priority Metric group will then be scheduled. Metric groups with the same priority will be scheduled in parallel. # Metric group with a priority of 0 is an availability group which will be scheduled first. If the collection succeeds, the scheduling will continue otherwise interrupt scheduling. priority: 0 - # Specific monitoring Metrics in the Metric group + # metrics fields list fields: # Metric information include field: name type: field type(0-number: number, 1-string: string) nstance: primary key of instance or not unit: Metric unit - field: hostname diff --git a/home/i18n/en/docusaurus-plugin-content-docs/version-v1.1.x/advanced/extend-http-example-hertzbeat.md b/home/i18n/en/docusaurus-plugin-content-docs/version-v1.1.x/advanced/extend-http-example-hertzbeat.md index a117631c4b..098ae64469 100644 --- a/home/i18n/en/docusaurus-plugin-content-docs/version-v1.1.x/advanced/extend-http-example-hertzbeat.md +++ b/home/i18n/en/docusaurus-plugin-content-docs/version-v1.1.x/advanced/extend-http-example-hertzbeat.md @@ -6,12 +6,12 @@ sidebar_label: Tutorial 1 Adapting an HTTP protocol monitoring Through this tutorial, we describe step by step how to add a monitoring type based on the http protocol under the hertzbeat monitoring tool. -Before reading this tutorial, we hope that you are familiar with how to customize types, indicators, protocols, etc. from [Custom Monitoring] (extend-point) and [http Protocol Customization] (extend-http). +Before reading this tutorial, we hope that you are familiar with how to customize types, metrics, protocols, etc. from [Custom Monitoring] (extend-point) and [http Protocol Customization] (extend-http). -### HTTP protocol parses the general response structure to obtain indicator data +### HTTP protocol parses the general response structure to obtain metric data -> In many scenarios, we need to monitor the provided HTTP API interface and obtain the index value returned by the interface. In this article, we use the http custom protocol to parse our common http interface response structure, and obtain the fields in the returned body as indicator data. +> In many scenarios, we need to monitor the provided HTTP API interface and obtain the index value returned by the interface. In this article, we use the http custom protocol to parse our common http interface response structure, and obtain the fields in the returned body as metric data. ``` @@ -56,7 +56,7 @@ As above, usually our background API interface will design such a general return } ``` -**This time we get the indicator data such as `category`, `app`, `status`, `size`, `availableSize` under the app. ** +**This time we get the metric data such as `category`, `app`, `status`, `size`, `availableSize` under the app. ** ### Add corresponding application definition YML and parameter definition YML @@ -67,7 +67,7 @@ A monitoring configuration definition file named after the monitoring type - for 2. Configure the monitoring configuration definition file app-hertzbeat.yml -The monitoring configuration definition file is used to define the collection type, which protocol collection method needs to be used, the collection indicators, protocol configuration parameters, etc. We directly reuse the definition content in app-api.yml and modify it to our current monitoring type `hertzbeat` configuration parameters, as follows: Note⚠️We get `category`, `app` in the interface response data this time, Fields such as `status`, `size`, `availableSize` are used as indicator data. +The monitoring configuration definition file is used to define the collection type, which protocol collection method needs to be used, the collection metrics, protocol configuration parameters, etc. We directly reuse the definition content in app-api.yml and modify it to our current monitoring type `hertzbeat` configuration parameters, as follows: Note⚠️We get `category`, `app` in the interface response data this time, Fields such as `status`, `size`, `availableSize` are used as metric data. ```yaml # This monitoring type belongs to the category: service-application service monitoring db-database monitoring custom-custom monitoring os-operating system monitoring @@ -132,14 +132,14 @@ params: type: password required: false hide: true -# List of indicator groups +# List of metricss metrics: - # The first monitoring indicator group summary - # Note: Built-in monitoring indicators have (responseTime - response time) + # The first monitoring metrics summary + # Note: Built-in monitoring metrics have (responseTime - response time) - name: summary priority: 0 fields: - # Indicator information includes field name type field type: 0-number, 1-string whether instance is the primary key of the instance unit: indicator unit + # metric information includes field name type field type: 0-number, 1-string whether instance is the primary key of the instance unit: metric unit - field: responseTime type: 0 unit: ms @@ -176,7 +176,7 @@ metrics: basicAuthPassword: ^_^password^_^ digestAuthUsername: ^_^username^_^ digestAuthPassword: ^_^password^_^ - # Response data parsing method: default-system rules, jsonPath-jsonPath script, website-website usability indicator monitoring, we use jsonpath here to parse the response data + # Response data parsing method: default-system rules, jsonPath-jsonPath script, website-website usability metric monitoring, we use jsonpath here to parse the response data parseType: jsonPath parseScript: '$.data.apps.*' @@ -198,7 +198,7 @@ metrics: ![](/img/docs/advanced/extend-http-example-3.png) -> After a certain period of time (depending on the collection cycle), we can see the specific indicator data and historical charts in the monitoring details! +> After a certain period of time (depending on the collection cycle), we can see the specific metric data and historical charts in the monitoring details! ![](/img/docs/advanced/extend-http-example-4.png) diff --git a/home/i18n/en/docusaurus-plugin-content-docs/version-v1.1.x/advanced/extend-http-example-token.md b/home/i18n/en/docusaurus-plugin-content-docs/version-v1.1.x/advanced/extend-http-example-token.md index 2db8d7a4e3..376cb6f618 100644 --- a/home/i18n/en/docusaurus-plugin-content-docs/version-v1.1.x/advanced/extend-http-example-token.md +++ b/home/i18n/en/docusaurus-plugin-content-docs/version-v1.1.x/advanced/extend-http-example-token.md @@ -4,13 +4,13 @@ title: Tutorial 2 Obtain TOKEN index value based on HTTP protocol for subsequent sidebar_label: Tutorial 2 Get TOKEN for subsequent authentication --- -Through this tutorial, we will describe step by step how to modify on the basis of tutorial 1, add an indicator group, first call the authentication interface to obtain the TOKEN, and use the TOKEN as a parameter for the subsequent indicator group collection and authentication. +Through this tutorial, we will describe step by step how to modify on the basis of tutorial 1, add an metrics, first call the authentication interface to obtain the TOKEN, and use the TOKEN as a parameter for the subsequent metrics collection and authentication. -Before reading this tutorial, we hope that you are familiar with how to customize types, indicators, protocols, etc. from [Custom Monitoring] (extend-point) and [http Protocol Customization] (extend-http). +Before reading this tutorial, we hope that you are familiar with how to customize types, metrics, protocols, etc. from [Custom Monitoring] (extend-point) and [http Protocol Customization] (extend-http). ### Request process -【**Authentication information indicator group (highest priority)**】【**HTTP interface carries account password call**】->【**Response data analysis**】->【**Analysis and issuance of TOKEN-accessToken as an indicator **] -> [**Assign accessToken as a variable parameter to other collection index groups**] +【**Authentication information metrics (highest priority)**】【**HTTP interface carries account password call**】->【**Response data analysis**】->【**Analysis and issuance of TOKEN-accessToken as an metric **] -> [**Assign accessToken as a variable parameter to other collection index groups**] > Here we still use the hertzbeat monitoring example of Tutorial 1! The hertzbeat background interface not only supports the basic direct account password authentication used in Tutorial 1, but also supports token authentication. @@ -41,7 +41,7 @@ Before reading this tutorial, we hope that you are familiar with how to customiz A monitoring configuration definition file named after the monitoring type - app-hertzbeat_token.yml needs to be located in the installation directory /hertzbeat/define/ -The monitoring configuration definition file is used to define the collection type, which protocol collection method needs to be used, the collection indicators, protocol configuration parameters, etc. +The monitoring configuration definition file is used to define the collection type, which protocol collection method needs to be used, the collection metrics, protocol configuration parameters, etc. We directly reuse the definition content in app-hertzbeat.yml and modify it to our current monitoring type `hertzbeat_auth` configuration parameters, such as `app, category, etc`. ```yaml @@ -101,7 +101,7 @@ metrics: .... ``` -### Define indicator group `auth` login request to get `token` +### Define metrics `auth` login request to get `token` 1. Add an index group definition `auth` in `app-hertzbeat_token.yml`, set the collection priority to the highest 0, and collect the index `token`. @@ -158,17 +158,17 @@ params: type: textarea placeholder: 'Available When POST PUT' required: false -# List of indicator groups +# List of metricss metrics: # The first monitoring index group auth - # Note: Built-in monitoring indicators have (responseTime - response time) + # Note: Built-in monitoring metrics have (responseTime - response time) - name: auth # The smaller the index group scheduling priority (0-127), the higher the priority, and the index group with low priority will not be scheduled until the collection of index groups with high priority is completed, and the index groups with the same priority will be scheduled and collected in parallel - # The indicator group with priority 0 is the availability indicator group, that is, it will be scheduled first, and other indicator groups will continue to be scheduled if the collection is successful, and the scheduling will be interrupted if the collection fails + # The metrics with priority 0 is the availability metrics, that is, it will be scheduled first, and other metricss will continue to be scheduled if the collection is successful, and the scheduling will be interrupted if the collection fails priority: 0 - # Specific monitoring indicators in the indicator group + # Specific monitoring metrics in the metrics fields: - # Indicator information includes field name type field type: 0-number, 1-string whether instance is the primary key of the instance unit: indicator unit + # metric information includes field name type field type: 0-number, 1-string whether instance is the primary key of the instance unit: metric unit - field: token type: 1 - field: refreshToken @@ -190,7 +190,7 @@ metrics: # request header content headers: content-type: ^_^contentType^_^ - # Response data analysis method: default-system rules, jsonPath-jsonPath script, website-website usability indicator monitoring + # Response data analysis method: default-system rules, jsonPath-jsonPath script, website-website usability metric monitoring parseType: jsonPath parseScript: '$.data' @@ -208,7 +208,7 @@ metrics: ![](/img/docs/advanced/extend-http-example-5.png) -** After the addition is successful, we can see the `token`, `refreshToken` indicator data we collected on the details page. ** +** After the addition is successful, we can see the `token`, `refreshToken` metric data we collected on the details page. ** ![](/img/docs/advanced/extend-http-example-6.png) @@ -216,7 +216,7 @@ metrics: -### Use `token` as a variable parameter to collect and use the following indicator groups +### Use `token` as a variable parameter to collect and use the following metricss **Add an index group definition `summary` in `app-hertzbeat_token.yml`, which is the same as `summary` in Tutorial 1, and set the collection priority to 1** @@ -288,17 +288,17 @@ params: type: textarea placeholder: 'Available When POST PUT' required: false -# List of indicator groups +# List of metricss metrics: # The first monitoring index group cpu -# Note: Built-in monitoring indicators have (responseTime - response time) +# Note: Built-in monitoring metrics have (responseTime - response time) - name: auth # The smaller the index group scheduling priority (0-127), the higher the priority, and the index group with low priority will not be scheduled until the collection of index groups with high priority is completed, and the index groups with the same priority will be scheduled and collected in parallel - # The indicator group with priority 0 is the availability indicator group, that is, it will be scheduled first, and other indicator groups will continue to be scheduled if the collection is successful, and the scheduling will be interrupted if the collection fails + # The metrics with priority 0 is the availability metrics, that is, it will be scheduled first, and other metricss will continue to be scheduled if the collection is successful, and the scheduling will be interrupted if the collection fails priority: 0 - # Specific monitoring indicators in the indicator group + # Specific monitoring metrics in the metrics fields: - # Indicator information includes field name type field type: 0-number, 1-string whether instance is the primary key of the instance unit: indicator unit + # metric information includes field name type field type: 0-number, 1-string whether instance is the primary key of the instance unit: metric unit - field: token type: 1 - field: refreshToken @@ -324,18 +324,18 @@ metrics: # Request parameter content params: ^_^params^_^: ^_^params^_^ - # Response data analysis method: default-system rules, jsonPath-jsonPath script, website-website usability indicator monitoring + # Response data analysis method: default-system rules, jsonPath-jsonPath script, website-website usability metric monitoring parseType: jsonPath parseScript: '$.data' - name: summary # The smaller the index group scheduling priority (0-127), the higher the priority, and the index group with low priority will not be scheduled until the collection of index groups with high priority is completed, and the index groups with the same priority will be scheduled and collected in parallel - # The indicator group with priority 0 is the availability indicator group, that is, it will be scheduled first, and other indicator groups will continue to be scheduled if the collection is successful, and the scheduling will be interrupted if the collection fails + # The metrics with priority 0 is the availability metrics, that is, it will be scheduled first, and other metricss will continue to be scheduled if the collection is successful, and the scheduling will be interrupted if the collection fails priority: 1 - # Specific monitoring indicators in the indicator group + # Specific monitoring metrics in the metrics fields: - # Indicator information includes field name type field type: 0-number, 1-string whether instance is the primary key of the instance unit: indicator unit + # metric information includes field name type field type: 0-number, 1-string whether instance is the primary key of the instance unit: metric unit - field: category type: 1 - field: app @@ -362,7 +362,7 @@ metrics: # Authentication methods: Basic Auth, Digest Auth, Bearer Token type: Bearer Token bearerTokenToken: ^o^token^o^ - # Response data analysis method: default-system rules, jsonPath-jsonPath script, website-website usability indicator monitoring + # Response data analysis method: default-system rules, jsonPath-jsonPath script, website-website usability metric monitoring parseType: jsonPath parseScript: '$.data.apps.*' diff --git a/home/i18n/en/docusaurus-plugin-content-docs/version-v1.1.x/advanced/extend-http-jsonpath.md b/home/i18n/en/docusaurus-plugin-content-docs/version-v1.1.x/advanced/extend-http-jsonpath.md index f963537d03..44fbab3fe4 100644 --- a/home/i18n/en/docusaurus-plugin-content-docs/version-v1.1.x/advanced/extend-http-jsonpath.md +++ b/home/i18n/en/docusaurus-plugin-content-docs/version-v1.1.x/advanced/extend-http-jsonpath.md @@ -136,7 +136,7 @@ metrics: # The smaller Metric group scheduling priority(0-127), the higher the priority. After completion of the high priority Metric group collection,the low priority Metric group will then be scheduled. Metric groups with the same priority will be scheduled in parallel. # Metric group with a priority of 0 is an availability group which will be scheduled first. If the collection succeeds, the scheduling will continue otherwise interrupt scheduling. priority: 0 - # Specific monitoring Metrics in the Metric group + # metrics fields list fields: # Metric information include field: name type: field type(0-number: number, 1-string: string) nstance: primary key of instance or not unit: Metric unit - field: type diff --git a/home/i18n/en/docusaurus-plugin-content-docs/version-v1.1.x/advanced/extend-http.md b/home/i18n/en/docusaurus-plugin-content-docs/version-v1.1.x/advanced/extend-http.md index e257c65ac2..2d9f147f19 100644 --- a/home/i18n/en/docusaurus-plugin-content-docs/version-v1.1.x/advanced/extend-http.md +++ b/home/i18n/en/docusaurus-plugin-content-docs/version-v1.1.x/advanced/extend-http.md @@ -108,7 +108,7 @@ metrics: # The smaller Metric group scheduling priority(0-127), the higher the priority. After completion of the high priority Metric group collection,the low priority Metric group will then be scheduled. Metric groups with the same priority will be scheduled in parallel. # Metric group with a priority of 0 is an availability group which will be scheduled first. If the collection succeeds, the scheduling will continue otherwise interrupt scheduling. priority: 0 - # Specific monitoring Metrics in the Metric group + # metrics fields list fields: # Metric information include field: name type: field type(0-number: number, 1-string: string) nstance: primary key of instance or not unit: Metric unit - field: hostname diff --git a/home/i18n/en/docusaurus-plugin-content-docs/version-v1.1.x/advanced/extend-jdbc.md b/home/i18n/en/docusaurus-plugin-content-docs/version-v1.1.x/advanced/extend-jdbc.md index 49a461309c..ed9f692eb4 100644 --- a/home/i18n/en/docusaurus-plugin-content-docs/version-v1.1.x/advanced/extend-jdbc.md +++ b/home/i18n/en/docusaurus-plugin-content-docs/version-v1.1.x/advanced/extend-jdbc.md @@ -119,7 +119,7 @@ metrics: # The smaller Metric group scheduling priority(0-127), the higher the priority. After completion of the high priority Metric group collection,the low priority Metric group will then be scheduled. Metric groups with the same priority will be scheduled in parallel. # Metric group with a priority of 0 is an availability group which will be scheduled first. If the collection succeeds, the scheduling will continue otherwise interrupt scheduling. priority: 0 - # Specific monitoring Metrics in the Metric group + # metrics fields list fields: # Metric information include field: name type: field type(0-number: number, 1-string: string) instance: primary key of instance or not unit: Metric unit - field: version diff --git a/home/i18n/en/docusaurus-plugin-content-docs/version-v1.1.x/advanced/extend-point.md b/home/i18n/en/docusaurus-plugin-content-docs/version-v1.1.x/advanced/extend-point.md index 345688b743..28c3d7bb3c 100644 --- a/home/i18n/en/docusaurus-plugin-content-docs/version-v1.1.x/advanced/extend-point.md +++ b/home/i18n/en/docusaurus-plugin-content-docs/version-v1.1.x/advanced/extend-point.md @@ -98,7 +98,7 @@ metrics: # The smaller Metric group scheduling priority(0-127), the higher the priority. After completion of the high priority Metric group collection,the low priority Metric group will then be scheduled. Metric groups with the same priority will be scheduled in parallel. # Metric group with a priority of 0 is an availability group which will be scheduled first. If the collection succeeds, the scheduling will continue otherwise interrupt scheduling. priority: 0 - # Specific monitoring Metrics in the Metric group + # metrics fields list fields: # Metric information include field: name type: field type(0-number: number, 1-string: string) instance: primary key of instance or not unit: Metric unit - field: hostname diff --git a/home/i18n/en/docusaurus-plugin-content-docs/version-v1.1.x/advanced/extend-ssh.md b/home/i18n/en/docusaurus-plugin-content-docs/version-v1.1.x/advanced/extend-ssh.md index c99841889b..ee68649377 100644 --- a/home/i18n/en/docusaurus-plugin-content-docs/version-v1.1.x/advanced/extend-ssh.md +++ b/home/i18n/en/docusaurus-plugin-content-docs/version-v1.1.x/advanced/extend-ssh.md @@ -116,7 +116,7 @@ metrics: # The smaller Metric group scheduling priority(0-127), the higher the priority. After completion of the high priority Metric group collection,the low priority Metric group will then be scheduled. Metric groups with the same priority will be scheduled in parallel. # Metric group with a priority of 0 is an availability group which will be scheduled first. If the collection succeeds, the scheduling will continue otherwise interrupt scheduling. priority: 0 - # Specific monitoring Metrics in the Metric group + # metrics fields list fields: # Metric information include field: name type: field type(0-number: number, 1-string: string) instance: primary key of instance or not unit: Metric unit - field: hostname diff --git a/home/i18n/en/docusaurus-plugin-content-docs/version-v1.1.x/advanced/extend-tutorial.md b/home/i18n/en/docusaurus-plugin-content-docs/version-v1.1.x/advanced/extend-tutorial.md index d0c21e6c8c..5855b38a3c 100644 --- a/home/i18n/en/docusaurus-plugin-content-docs/version-v1.1.x/advanced/extend-tutorial.md +++ b/home/i18n/en/docusaurus-plugin-content-docs/version-v1.1.x/advanced/extend-tutorial.md @@ -6,12 +6,12 @@ sidebar_label: Quick Tutorial Through this tutorial, we describe step by step how to customize and adapt a monitoring type based on the http protocol under the hertzbeat monitoring tool. -Before reading this tutorial, we hope that you are familiar with how to customize types, indicators, protocols, etc. from [Custom Monitoring] (extend-point) and [http Protocol Customization] (extend-http). +Before reading this tutorial, we hope that you are familiar with how to customize types, metrics, protocols, etc. from [Custom Monitoring] (extend-point) and [http Protocol Customization] (extend-http). -### HTTP protocol parses the general response structure to obtain indicator data +### HTTP protocol parses the general response structure to obtain metric data -> In many scenarios, we need to monitor the provided HTTP API interface and obtain the index value returned by the interface. In this article, we use the http custom protocol to parse our common http interface response structure, and obtain the fields in the returned body as indicator data. +> In many scenarios, we need to monitor the provided HTTP API interface and obtain the index value returned by the interface. In this article, we use the http custom protocol to parse our common http interface response structure, and obtain the fields in the returned body as metric data. ``` @@ -56,7 +56,7 @@ As above, usually our background API interface will design such a general return } ``` -**This time we get the indicator data such as `category`, `app`, `status`, `size`, `availableSize` under the app. ** +**This time we get the metric data such as `category`, `app`, `status`, `size`, `availableSize` under the app. ** ### Add corresponding application definition YML and parameter definition YML @@ -67,7 +67,7 @@ A monitoring configuration definition file named after the monitoring type - for Define which parameters we need to enter on the page. The general HTTP protocol parameters mainly include ip, port, headers, params, uri, account password, etc. We directly reuse the parameter definition content in param-api.yml and delete our No need to enter parameters such as uri parameters and keyword keywords. -Define what type of collection is, which protocol collection method needs to be used, what indicators are collected, protocol configuration parameters, etc. We directly reuse the definition content in app-api.yml and modify it to our current monitoring type `hertzbeat` configuration parameters, as follows: Note⚠️We get `category`, `app` in the interface response data this time, Fields such as `status`, `size`, `availableSize` are used as indicator data. +Define what type of collection is, which protocol collection method needs to be used, what metrics are collected, protocol configuration parameters, etc. We directly reuse the definition content in app-api.yml and modify it to our current monitoring type `hertzbeat` configuration parameters, as follows: Note⚠️We get `category`, `app` in the interface response data this time, Fields such as `status`, `size`, `availableSize` are used as metric data. ```yaml # This monitoring type belongs to the category: service-application service monitoring db-database monitoring custom-custom monitoring os-operating system monitoring @@ -132,17 +132,17 @@ params: type: password required: false hide: true -# List of indicator groups +# List of metricss metrics: - # The first monitoring indicator group summary - # Note: Built-in monitoring indicators have (responseTime - response time) + # The first monitoring metrics summary + # Note: Built-in monitoring metrics have (responseTime - response time) - name: summary # The smaller the index group scheduling priority (0-127), the higher the priority, and the index group with low priority will not be scheduled until the collection of index groups with high priority is completed, and the index groups with the same priority will be scheduled and collected in parallel - # The indicator group with priority 0 is the availability indicator group, that is, it will be scheduled first, and other indicator groups will continue to be scheduled if the collection is successful, and the scheduling will be interrupted if the collection fails + # The metrics with priority 0 is the availability metrics, that is, it will be scheduled first, and other metricss will continue to be scheduled if the collection is successful, and the scheduling will be interrupted if the collection fails priority: 0 - # Specific monitoring indicators in the indicator group + # Specific monitoring metrics in the metrics fields: - # Indicator information includes field name type field type: 0-number, 1-string whether instance is the primary key of the instance unit: indicator unit + # metric information includes field name type field type: 0-number, 1-string whether instance is the primary key of the instance unit: metric unit - field: responseTime type: 0 unit: ms @@ -179,7 +179,7 @@ metrics: basicAuthPassword: ^_^password^_^ digestAuthUsername: ^_^username^_^ digestAuthPassword: ^_^password^_^ - # Response data parsing method: default-system rules, jsonPath-jsonPath script, website-website usability indicator monitoring, we use jsonpath here to parse the response data + # Response data parsing method: default-system rules, jsonPath-jsonPath script, website-website usability metric monitoring, we use jsonpath here to parse the response data parseType: jsonPath parseScript: '$.data.apps.*' @@ -201,7 +201,7 @@ metrics: ![](/img/docs/advanced/extend-http-example-3.png) -> After a certain period of time (depending on the collection cycle), we can see the specific indicator data and historical charts in the monitoring details! +> After a certain period of time (depending on the collection cycle), we can see the specific metric data and historical charts in the monitoring details! ![](/img/docs/advanced/extend-http-example-4.png) diff --git a/home/i18n/en/docusaurus-plugin-content-docs/version-v1.1.x/help/activemq.md b/home/i18n/en/docusaurus-plugin-content-docs/version-v1.1.x/help/activemq.md index 1bf72231df..52e3090fde 100644 --- a/home/i18n/en/docusaurus-plugin-content-docs/version-v1.1.x/help/activemq.md +++ b/home/i18n/en/docusaurus-plugin-content-docs/version-v1.1.x/help/activemq.md @@ -66,7 +66,7 @@ ACTIVEMQ_SUNJMX_START="$ACTIVEMQ_SUNJMX_START -Dcom.sun.management.jmxremote" ### Collect Metrics -#### Metrics Group: broker +#### metrics: broker | Metric Name | Unit | Description | |-------------------------|------|-----------------------------------------------------------------------| @@ -89,7 +89,7 @@ ACTIVEMQ_SUNJMX_START="$ACTIVEMQ_SUNJMX_START -Dcom.sun.management.jmxremote" | MaxMessageSize | None | Max message size on this broker | | MinMessageSize | None | Min message size on this broker | -#### Metrics Group: topic +#### metrics: topic | Metric Name | Unit | Description | |-------------------------|------|-------------------------------------------------------------------------------------------| @@ -114,7 +114,7 @@ ACTIVEMQ_SUNJMX_START="$ACTIVEMQ_SUNJMX_START -Dcom.sun.management.jmxremote" | MinMessageSize | B | Min message size on this destination | -#### Metrics Group: memory_pool +#### metrics: memory_pool | Metric Name | Unit | Description | |-------------| ----------- |----------------| @@ -124,7 +124,7 @@ ACTIVEMQ_SUNJMX_START="$ACTIVEMQ_SUNJMX_START -Dcom.sun.management.jmxremote" | max | kb | max size | | used | kb | used size | -#### Metrics Group: class_loading +#### metrics: class_loading | Metric Name | Unit | Description | |-----------------------| ----------- | ----------- | @@ -133,7 +133,7 @@ ACTIVEMQ_SUNJMX_START="$ACTIVEMQ_SUNJMX_START -Dcom.sun.management.jmxremote" | UnloadedClassCount | | Unloaded Class Count | -#### Metrics Group: thread +#### metrics: thread | Metric Name | Unit | Description | |-------------------------| ----------- | ----------- | diff --git a/home/i18n/en/docusaurus-plugin-content-docs/version-v1.1.x/help/rabbitmq.md b/home/i18n/en/docusaurus-plugin-content-docs/version-v1.1.x/help/rabbitmq.md index fd06687369..1bcd3ea585 100644 --- a/home/i18n/en/docusaurus-plugin-content-docs/version-v1.1.x/help/rabbitmq.md +++ b/home/i18n/en/docusaurus-plugin-content-docs/version-v1.1.x/help/rabbitmq.md @@ -9,7 +9,7 @@ keywords: [open source monitoring tool, open source rabbitmq monitoring tool, mo ### Pre-monitoring Operations -> HertzBeat uses RabbitMQ Management's Rest Api to collect RabbitMQ indicator data. +> HertzBeat uses RabbitMQ Management's Rest Api to collect RabbitMQ metric data. > Therefore, you need to enable the Management plug-in in your RabbitMQ environment 1. Open the Management plugin, or use the self-opening version @@ -38,7 +38,7 @@ rabbitmq-plugins enable rabbitmq_management ### Collect Metrics -#### Metrics Group: overview +#### metrics: overview | Metric Name | Metric Unit | Metric Description | |--------------------|-------------|------------------------------------| @@ -50,7 +50,7 @@ rabbitmq-plugins enable rabbitmq_management | cluster_name | None | Cluster name | | rates_mode | None | rates mode | -#### Metrics Group: object_totals +#### metrics: object_totals | Metric Name | Metric Unit | Metric Description | |-------------|-------------|-----------------------------| @@ -60,7 +60,7 @@ rabbitmq-plugins enable rabbitmq_management | exchanges | none | total number of exchanges | | queues | none | total number of queues | -#### Metrics Group: nodes +#### metrics: nodes | Metric Name | Metric Unit | Metric Description | |--------------------|-------------|-----------------------------------------------------------| @@ -101,7 +101,7 @@ rabbitmq-plugins enable rabbitmq_management | connection_closed | None | connection closed num | -#### Metrics Group: queues +#### metrics: queues | Metric Name | Metric Unit | Metric Description | |------------------------------|-------------|--------------------------------------------------------------------------------------------------------------------------------------| diff --git a/home/i18n/en/docusaurus-plugin-content-docs/version-v1.1.x/start/custom-config.md b/home/i18n/en/docusaurus-plugin-content-docs/version-v1.1.x/start/custom-config.md index 34268ca450..5f7837c4e5 100644 --- a/home/i18n/en/docusaurus-plugin-content-docs/version-v1.1.x/start/custom-config.md +++ b/home/i18n/en/docusaurus-plugin-content-docs/version-v1.1.x/start/custom-config.md @@ -46,9 +46,9 @@ alerter: system-alert-trigger-times: 1 ``` -3. Use external redis instead of memory to store real-time indicator data +3. Use external redis instead of memory to store real-time metric data -> By default, the real-time data of our indicators is stored in memory, which can be configured as follows to use redis instead of memory storage. +> By default, the real-time data of our metrics is stored in memory, which can be configured as follows to use redis instead of memory storage. Note ⚠️ `memory.enabled: false, redis.enabled: true` ```yaml diff --git a/home/i18n/en/docusaurus-plugin-content-docs/version-v1.1.x/start/iotdb-init.md b/home/i18n/en/docusaurus-plugin-content-docs/version-v1.1.x/start/iotdb-init.md index 18682a705b..b776767ab4 100644 --- a/home/i18n/en/docusaurus-plugin-content-docs/version-v1.1.x/start/iotdb-init.md +++ b/home/i18n/en/docusaurus-plugin-content-docs/version-v1.1.x/start/iotdb-init.md @@ -6,7 +6,7 @@ sidebar_label: IoTDB init (optional) HertzBeat's historical data storage relies on the time series database IoTDB or TDengine, you can choose one of them to initialize, or not to install (note ⚠️If you don't install it, there will be no historical chart data) -Apache IoTDB is a software system that integrates the collection, storage, management and analysis of IoT time series data. We use it to store and analyze the collected historical data of monitoring indicators. +Apache IoTDB is a software system that integrates the collection, storage, management and analysis of IoT time series data. We use it to store and analyze the collected historical data of monitoring metrics. Note ⚠️ IoTDB is optional, if not configured, there will be no historical chart data. Support V0.12 - V0.13 version, recommend to use V0.13.* version diff --git a/home/i18n/en/docusaurus-plugin-content-docs/version-v1.1.x/start/sslcert-practice.md b/home/i18n/en/docusaurus-plugin-content-docs/version-v1.1.x/start/sslcert-practice.md index 48ef6347f7..aefa594160 100644 --- a/home/i18n/en/docusaurus-plugin-content-docs/version-v1.1.x/start/sslcert-practice.md +++ b/home/i18n/en/docusaurus-plugin-content-docs/version-v1.1.x/start/sslcert-practice.md @@ -45,7 +45,7 @@ gitee: https://gitee.com/dromara/hertzbeat 3. View the detection index data -> In the monitoring list, you can view the monitoring status, and in the monitoring details, you can view the indicator data chart, etc. +> In the monitoring list, you can view the monitoring status, and in the monitoring details, you can view the metric data chart, etc. ![](https://p3-juejin.byteimg.com/tos-cn-i-k3u1fbpfcp/f874b45e909c4bb0acdd28b3fb034a61~tplv-k3u1fbpfcp-zoom-1.image) @@ -62,7 +62,7 @@ gitee: https://gitee.com/dromara/hertzbeat ![](https://p3-juejin.byteimg.com/tos-cn-i-k3u1fbpfcp/8d6205172d43463aa34e534477f132f1~tplv-k3u1fbpfcp-zoom-1.image) -> Configure the threshold, select the SSL certificate indicator object, configure the alarm expression-triggered when the indicator `expired` is `true`, that is, `equals(expired,"true")`, set the alarm level notification template information, etc. +> Configure the threshold, select the SSL certificate metric object, configure the alarm expression-triggered when the metric `expired` is `true`, that is, `equals(expired,"true")`, set the alarm level notification template information, etc. ![](https://p3-juejin.byteimg.com/tos-cn-i-k3u1fbpfcp/83d17b381d994f26a6240e01915b2001~tplv-k3u1fbpfcp-zoom-1.image) @@ -77,7 +77,7 @@ gitee: https://gitee.com/dromara/hertzbeat 5. Set the threshold (triggered one week before the certificate expires) -> In the same way, add a new configuration threshold and configure an alarm expression - when the indicator expires timestamp `end_timestamp`, the `now()` function is the current timestamp, if the configuration triggers an alarm one week in advance: `end_timestamp <= (now( ) + 604800000)` , where `604800000` is the 7-day total time difference in milliseconds. +> In the same way, add a new configuration threshold and configure an alarm expression - when the metric expires timestamp `end_timestamp`, the `now()` function is the current timestamp, if the configuration triggers an alarm one week in advance: `end_timestamp <= (now( ) + 604800000)` , where `604800000` is the 7-day total time difference in milliseconds. ![](https://p3-juejin.byteimg.com/tos-cn-i-k3u1fbpfcp/0d6f837f57c247e09f668f60eff4a0ff~tplv-k3u1fbpfcp-zoom-1.image) diff --git a/home/i18n/zh-cn/docusaurus-plugin-content-docs/current/advanced/extend-http-default.md b/home/i18n/zh-cn/docusaurus-plugin-content-docs/current/advanced/extend-http-default.md index fa01a96f79..97ec1be4c6 100644 --- a/home/i18n/zh-cn/docusaurus-plugin-content-docs/current/advanced/extend-http-default.md +++ b/home/i18n/zh-cn/docusaurus-plugin-content-docs/current/advanced/extend-http-default.md @@ -110,15 +110,16 @@ params: defaultValue: 80 # 参数输入框提示信息 placeholder: '请输入端口' -# 指标组列表 +# collect metrics config list +# 采集指标配置列表 metrics: -# 第一个监控指标组 cpu -# 注意:内置监控指标有 (responseTime - 响应时间) + # First monitoring metric group cpu + # Note: The built-in monitoring metrics include (responseTime - response time) - name: cpu - # 指标组调度优先级(0-127)越小优先级越高,优先级低的指标组会等优先级高的指标组采集完成后才会被调度,相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # 指标调度优先级(0-127)越小优先级越高,优先级低的指标会等优先级高的指标采集完成后才会被调度,相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 0 - # 指标组中的具体监控指标 + # 具体监控指标列表 fields: # 指标信息 包括 field名称 type字段类型:0-number数字,1-string字符串 instance是否为实例主键 unit:指标单位 - field: hostname diff --git a/home/i18n/zh-cn/docusaurus-plugin-content-docs/current/advanced/extend-http-example-hertzbeat.md b/home/i18n/zh-cn/docusaurus-plugin-content-docs/current/advanced/extend-http-example-hertzbeat.md index b867ba3d04..ad350dd53d 100644 --- a/home/i18n/zh-cn/docusaurus-plugin-content-docs/current/advanced/extend-http-example-hertzbeat.md +++ b/home/i18n/zh-cn/docusaurus-plugin-content-docs/current/advanced/extend-http-example-hertzbeat.md @@ -131,15 +131,16 @@ params: type: password required: false hide: true -# 指标组列表 +# collect metrics config list +# 采集指标配置列表 metrics: - # 第一个监控指标组 summary - # 注意:内置监控指标有 (responseTime - 响应时间) + # metrics - summary + # 监控指标 - summary - name: summary - # 指标组调度优先级(0-127)越小优先级越高,优先级低的指标组会等优先级高的指标组采集完成后才会被调度,相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # 指标调度优先级(0-127)越小优先级越高,优先级低的指标会等优先级高的指标采集完成后才会被调度,相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 0 - # 指标组中的具体监控指标 + # 具体监控指标列表 fields: # 指标信息 包括 field名称 type字段类型:0-number数字,1-string字符串 instance是否为实例主键 unit:指标单位 - field: responseTime diff --git a/home/i18n/zh-cn/docusaurus-plugin-content-docs/current/advanced/extend-http-example-token.md b/home/i18n/zh-cn/docusaurus-plugin-content-docs/current/advanced/extend-http-example-token.md index c674c25350..5a8b7a9c1f 100644 --- a/home/i18n/zh-cn/docusaurus-plugin-content-docs/current/advanced/extend-http-example-token.md +++ b/home/i18n/zh-cn/docusaurus-plugin-content-docs/current/advanced/extend-http-example-token.md @@ -4,13 +4,13 @@ title: 教程二:基于HTTP协议获取TOKEN指标值,给后续采集认证使 sidebar_label: 教程二:获取TOKEN后续认证使用 --- -通过此教程我们一步一步描述如何在教程一的基础上改造,新增一个指标组,先调用认证接口获取TOKEN后,使用TOKEN作为参数供后面的指标组采集认证使用。 +通过此教程我们一步一步描述如何在教程一的基础上改造,新增一个监控指标,先调用认证接口获取TOKEN后,使用TOKEN作为参数供后面的监控指标采集认证使用。 阅读此教程前我们希望您已经从[自定义监控](extend-point)和[http协议自定义](extend-http)了解熟悉了怎么自定义类型,指标,协议等。 ### 请求流程 -【**认证信息指标组(优先级最高)**】【**HTTP接口携带账户密码调用**】->【**响应数据解析**】->【**解析签发TOKEN-accessToken作为指标**】->【**将accessToken作为变量参数赋值给其他采集指标组**】 +【**认证信息监控指标(优先级最高)**】【**HTTP接口携带账户密码调用**】->【**响应数据解析**】->【**解析签发TOKEN-accessToken作为指标**】->【**将accessToken作为变量参数赋值给其他采集监控指标**】 > 这里我们依然用教程一的hertzbeat监控举例!hertzbeat后台接口不仅仅支持教程一使用的basic直接账户密码认证,也支持token认证。 @@ -94,14 +94,14 @@ params: type: textarea placeholder: 'Available When POST PUT' required: false -# 指标组列表 todo 下方配置 +# 采集指标配置列表 todo 下方配置 metrics: ...... ``` -### 定义指标组`auth`登录请求获取`token` +### 定义监控指标`auth`登录请求获取`token` -1. 在`app-hertzbeat_token.yml`新增一个指标组定义 `auth`, 设置采集优先级为最高0,采集指标 `token`. +1. 在`app-hertzbeat_token.yml`新增一个监控指标定义 `auth`, 设置采集优先级为最高0,采集指标 `token`. ```yaml @@ -156,15 +156,15 @@ params: type: textarea placeholder: 'Available When POST PUT' required: false -# 指标组列表 +# 采集指标配置列表 metrics: - # 第一个监控指标组 auth + # 第一个监控指标 auth # 注意:内置监控指标有 (responseTime - 响应时间) - name: auth - # 指标组调度优先级(0-127)越小优先级越高,优先级低的指标组会等优先级高的指标组采集完成后才会被调度,相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # 指标调度优先级(0-127)越小优先级越高,优先级低的指标会等优先级高的指标采集完成后才会被调度,相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 0 - # 指标组中的具体监控指标 + # 具体监控指标列表 fields: # 指标信息 包括 field名称 type字段类型:0-number数字,1-string字符串 instance是否为实例主键 unit:指标单位 - field: token @@ -215,10 +215,10 @@ metrics: -### 将`token`作为变量参数给后面的指标组采集使用 +### 将`token`作为变量参数给后面的监控指标采集使用 -**在`app-hertzbeat_token.yml`新增一个指标组定义 `summary` 同教程一中的`summary`相同, 设置采集优先级为1** -**设置此指标组的HTTP协议配置中认证方式为 `Bearer Token` 将上一个指标组`auth`采集的指标`token`作为参数给其赋值,使用`^o^`作为内部替换符标识,即`^o^token^o^`。如下:** +**在`app-hertzbeat_token.yml`新增一个监控指标定义 `summary` 同教程一中的`summary`相同, 设置采集优先级为1** +**设置此监控指标的HTTP协议配置中认证方式为 `Bearer Token` 将上一个监控指标`auth`采集的指标`token`作为参数给其赋值,使用`^o^`作为内部替换符标识,即`^o^token^o^`。如下:** ```yaml - name: summary @@ -286,15 +286,15 @@ params: type: textarea placeholder: 'Available When POST PUT' required: false -# 指标组列表 +# 采集指标配置列表 metrics: -# 第一个监控指标组 cpu +# 第一个监控指标 cpu # 注意:内置监控指标有 (responseTime - 响应时间) - name: auth - # 指标组调度优先级(0-127)越小优先级越高,优先级低的指标组会等优先级高的指标组采集完成后才会被调度,相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # 指标调度优先级(0-127)越小优先级越高,优先级低的指标会等优先级高的指标采集完成后才会被调度,相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 0 - # 指标组中的具体监控指标 + # 具体监控指标列表 fields: # 指标信息 包括 field名称 type字段类型:0-number数字,1-string字符串 instance是否为实例主键 unit:指标单位 - field: token @@ -329,10 +329,10 @@ metrics: - name: summary - # 指标组调度优先级(0-127)越小优先级越高,优先级低的指标组会等优先级高的指标组采集完成后才会被调度,相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # 指标调度优先级(0-127)越小优先级越高,优先级低的指标会等优先级高的指标采集完成后才会被调度,相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 1 - # 指标组中的具体监控指标 + # 具体监控指标列表 fields: # 指标信息 包括 field名称 type字段类型:0-number数字,1-string字符串 instance是否为实例主键 unit:指标单位 - field: category diff --git a/home/i18n/zh-cn/docusaurus-plugin-content-docs/current/advanced/extend-http-jsonpath.md b/home/i18n/zh-cn/docusaurus-plugin-content-docs/current/advanced/extend-http-jsonpath.md index 0dcc86dfbd..257ff55eda 100644 --- a/home/i18n/zh-cn/docusaurus-plugin-content-docs/current/advanced/extend-http-jsonpath.md +++ b/home/i18n/zh-cn/docusaurus-plugin-content-docs/current/advanced/extend-http-jsonpath.md @@ -130,15 +130,16 @@ params: defaultValue: 80 # 参数输入框提示信息 placeholder: '请输入端口' -# 指标组列表 +# collect metrics config list +# 采集指标配置列表 metrics: -# 第一个监控指标组 person -# 注意:内置监控指标有 (responseTime - 响应时间) + # metrics - cpu + # 监控指标 - cpu - name: cpu - # 指标组调度优先级(0-127)越小优先级越高,优先级低的指标组会等优先级高的指标组采集完成后才会被调度,相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # 指标调度优先级(0-127)越小优先级越高,优先级低的指标会等优先级高的指标采集完成后才会被调度,相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 0 - # 指标组中的具体监控指标 + # 具体监控指标列表 fields: # 指标信息 包括 field名称 type字段类型:0-number数字,1-string字符串 instance是否为实例主键 unit:指标单位 - field: type diff --git a/home/i18n/zh-cn/docusaurus-plugin-content-docs/current/advanced/extend-http.md b/home/i18n/zh-cn/docusaurus-plugin-content-docs/current/advanced/extend-http.md index 380a001c63..7741f1d601 100644 --- a/home/i18n/zh-cn/docusaurus-plugin-content-docs/current/advanced/extend-http.md +++ b/home/i18n/zh-cn/docusaurus-plugin-content-docs/current/advanced/extend-http.md @@ -103,15 +103,15 @@ params: value: PUT - label: DELETE请求 value: DELETE -# 指标组列表 +# 采集指标配置列表 metrics: -# 第一个监控指标组 cpu +# 第一个监控指标 cpu # 注意:内置监控指标有 (responseTime - 响应时间) - name: cpu - # 指标组调度优先级(0-127)越小优先级越高,优先级低的指标组会等优先级高的指标组采集完成后才会被调度,相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # 指标调度优先级(0-127)越小优先级越高,优先级低的指标会等优先级高的指标采集完成后才会被调度,相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 0 - # 指标组中的具体监控指标 + # 具体监控指标列表 fields: # 指标信息 包括 field名称 type字段类型:0-number数字,1-string字符串 instance是否为实例主键 unit:指标单位 - field: hostname diff --git a/home/i18n/zh-cn/docusaurus-plugin-content-docs/current/advanced/extend-jdbc.md b/home/i18n/zh-cn/docusaurus-plugin-content-docs/current/advanced/extend-jdbc.md index 5f29eb7d3d..e521f31f2f 100644 --- a/home/i18n/zh-cn/docusaurus-plugin-content-docs/current/advanced/extend-jdbc.md +++ b/home/i18n/zh-cn/docusaurus-plugin-content-docs/current/advanced/extend-jdbc.md @@ -115,13 +115,13 @@ params: en-US: Url type: text required: false -# 指标组列表 +# 采集指标配置列表 metrics: - name: basic - # 指标组调度优先级(0-127)越小优先级越高,优先级低的指标组会等优先级高的指标组采集完成后才会被调度,相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # 指标调度优先级(0-127)越小优先级越高,优先级低的指标会等优先级高的指标采集完成后才会被调度,相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 0 - # 指标组中的具体监控指标 + # 具体监控指标列表 fields: # 指标信息 包括 field名称 type字段类型:0-number数字,1-string字符串 instance是否为实例主键 unit:指标单位 - field: version diff --git a/home/i18n/zh-cn/docusaurus-plugin-content-docs/current/advanced/extend-jmx.md b/home/i18n/zh-cn/docusaurus-plugin-content-docs/current/advanced/extend-jmx.md index 418cc0ac23..e7f059844b 100644 --- a/home/i18n/zh-cn/docusaurus-plugin-content-docs/current/advanced/extend-jmx.md +++ b/home/i18n/zh-cn/docusaurus-plugin-content-docs/current/advanced/extend-jmx.md @@ -141,20 +141,20 @@ params: # 是否隐藏字段 true or false hide: true # collect metrics config list -# 采集指标组配置列表 +# 采集指标配置列表 metrics: # metrics - basic - # 监控指标组 - basic + # 监控指标 - basic - name: basic - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue - # 指标组调度优先级(0->127)->(优先级高->低) 优先级低的指标组会等优先级高的指标组采集完成后才会被调度, 相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # 指标采集调度优先级(0->127)->(优先级高->低) 优先级低的指标会等优先级高的指标采集完成后才会被调度, 相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 0 # collect metrics content # 具体监控指标列表 fields: - # field-metric name, type-metric type(0-number,1-string), unit-metric unit('%','ms','MB'), instance-if is metrics group unique identifier + # field-metric name, type-metric type(0-number,1-string), unit-metric unit('%','ms','MB'), instance-if is metrics unique identifier # field-指标名称, type-指标类型(0-number数字,1-string字符串), unit-指标单位('%','ms','MB'), instance-是否是指标集合唯一标识符字段 - field: VmName type: 1 diff --git a/home/i18n/zh-cn/docusaurus-plugin-content-docs/current/advanced/extend-point.md b/home/i18n/zh-cn/docusaurus-plugin-content-docs/current/advanced/extend-point.md index 92ab49b1b3..482dc583ab 100644 --- a/home/i18n/zh-cn/docusaurus-plugin-content-docs/current/advanced/extend-point.md +++ b/home/i18n/zh-cn/docusaurus-plugin-content-docs/current/advanced/extend-point.md @@ -129,18 +129,18 @@ params: metrics: # metrics - summary, inner monitoring metrics (responseTime - response time, keyword - number of keywords) - # 监控指标组 - summary, 内置监控指标有 (responseTime - 响应时间, keyword - 关键字数量) + # 监控指标 - summary, 内置监控指标有 (responseTime - 响应时间, keyword - 关键字数量) - name: summary - # 指标组调度优先级(0-127)越小优先级越高,优先级低的指标组会等优先级高的指标组采集完成后才会被调度,相同优先级的指标组会并行调度采集 - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue - # 指标组调度优先级(0->127)->(优先级高->低) 优先级低的指标组会等优先级高的指标组采集完成后才会被调度, 相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # 指标调度优先级(0-127)越小优先级越高,优先级低的指标会等优先级高的指标采集完成后才会被调度,相同优先级的指标会并行调度采集 + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # 指标采集调度优先级(0->127)->(优先级高->低) 优先级低的指标会等优先级高的指标采集完成后才会被调度, 相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 0 # collect metrics content # 具体监控指标列表 fields: - # field-metric name, type-metric type(0-number,1-string), unit-metric unit('%','ms','MB'), instance-if is metrics group unique identifier + # field-metric name, type-metric type(0-number,1-string), unit-metric unit('%','ms','MB'), instance-if is metrics unique identifier # field-指标名称, type-指标类型(0-number数字,1-string字符串), unit-指标单位('%','ms','MB'), instance-是否是指标集合唯一标识符字段 - field: responseTime type: 0 diff --git a/home/i18n/zh-cn/docusaurus-plugin-content-docs/current/advanced/extend-snmp.md b/home/i18n/zh-cn/docusaurus-plugin-content-docs/current/advanced/extend-snmp.md index ad7f9cfb95..89f94376c3 100644 --- a/home/i18n/zh-cn/docusaurus-plugin-content-docs/current/advanced/extend-snmp.md +++ b/home/i18n/zh-cn/docusaurus-plugin-content-docs/current/advanced/extend-snmp.md @@ -148,20 +148,20 @@ params: # 默认值 defaultValue: 6000 # collect metrics config list -# 采集指标组配置列表 +# 采集指标配置列表 metrics: # metrics - system - # 监控指标组 - system + # 监控指标 - system - name: system - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue - # 指标组调度优先级(0->127)->(优先级高->低) 优先级低的指标组会等优先级高的指标组采集完成后才会被调度, 相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # 指标采集调度优先级(0->127)->(优先级高->低) 优先级低的指标会等优先级高的指标采集完成后才会被调度, 相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 0 # collect metrics content # 具体监控指标列表 fields: - # field-metric name, type-metric type(0-number,1-string), unit-metric unit('%','ms','MB'), instance-if is metrics group unique identifier + # field-metric name, type-metric type(0-number,1-string), unit-metric unit('%','ms','MB'), instance-if is metrics unique identifier # field-指标名称, type-指标类型(0-number数字,1-string字符串), unit-指标单位('%','ms','MB'), instance-是否是指标集合唯一标识符字段 - field: name type: 1 diff --git a/home/i18n/zh-cn/docusaurus-plugin-content-docs/current/advanced/extend-ssh.md b/home/i18n/zh-cn/docusaurus-plugin-content-docs/current/advanced/extend-ssh.md index 72f4c541de..cc5ca9a5ef 100644 --- a/home/i18n/zh-cn/docusaurus-plugin-content-docs/current/advanced/extend-ssh.md +++ b/home/i18n/zh-cn/docusaurus-plugin-content-docs/current/advanced/extend-ssh.md @@ -111,15 +111,16 @@ params: en-US: Password type: password required: true -# 指标组列表 +# collect metrics config list +# 采集指标配置列表 metrics: - # 第一个监控指标组 basic + # 第一个监控指标 basic # 注意:内置监控指标有 (responseTime - 响应时间) - name: basic - # 指标组调度优先级(0-127)越小优先级越高,优先级低的指标组会等优先级高的指标组采集完成后才会被调度,相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # 指标调度优先级(0-127)越小优先级越高,优先级低的指标会等优先级高的指标采集完成后才会被调度,相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 0 - # 指标组中的具体监控指标 + # 具体监控指标列表 fields: # 指标信息 包括 field名称 type字段类型:0-number数字,1-string字符串 instance是否为实例主键 unit:指标单位 - field: hostname diff --git a/home/i18n/zh-cn/docusaurus-plugin-content-docs/current/advanced/extend-tutorial.md b/home/i18n/zh-cn/docusaurus-plugin-content-docs/current/advanced/extend-tutorial.md index 9d89f184f6..c19d1cad5a 100644 --- a/home/i18n/zh-cn/docusaurus-plugin-content-docs/current/advanced/extend-tutorial.md +++ b/home/i18n/zh-cn/docusaurus-plugin-content-docs/current/advanced/extend-tutorial.md @@ -159,18 +159,16 @@ params: metrics: # the first metrics summary # attention: Built-in monitoring metrics contains (responseTime - Response time) - # 第一个监控指标组 summary - # 注意:内置监控指标有 (responseTime - 响应时间) - name: summary - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue - # 指标组调度优先级(0-127)越小优先级越高,优先级低的指标组会等优先级高的指标组采集完成后才会被调度,相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # 指标调度优先级(0-127)越小优先级越高,优先级低的指标会等优先级高的指标采集完成后才会被调度,相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 0 # collect metrics content - # 指标组中的具体监控指标 + # 具体监控指标列表 fields: - # metrics content contains field-metric name, type-metric type:0-number,1-string, instance-if is metrics group, unit-metric unit('%','ms','MB') + # metrics content contains field-metric name, type-metric type:0-number,1-string, instance-if is metrics, unit-metric unit('%','ms','MB') # 指标信息 包括 field名称 type字段类型:0-number数字,1-string字符串 instance是否为实例主键 unit:指标单位 - field: app type: 1 diff --git a/home/i18n/zh-cn/docusaurus-plugin-content-docs/current/help/alert_threshold_expr.md b/home/i18n/zh-cn/docusaurus-plugin-content-docs/current/help/alert_threshold_expr.md index 6e4911b843..14fbcdb13d 100644 --- a/home/i18n/zh-cn/docusaurus-plugin-content-docs/current/help/alert_threshold_expr.md +++ b/home/i18n/zh-cn/docusaurus-plugin-content-docs/current/help/alert_threshold_expr.md @@ -47,7 +47,7 @@ equals(str1,str2) `responseTime>3000` 3. 全站监控->URL(instance)路径为 `https://baidu.com/book/3` 的响应时间大于200ms时触发告警 `equals(instance,"https://baidu.com/book/3")&&responseTime>200` -4. MYSQL监控->status指标组->threads_running(运行线程数)指标大于7时触发告警 +4. MYSQL监控->status指标->threads_running(运行线程数)指标大于7时触发告警 `threads_running>7` 若遇到问题可以通过交流群ISSUE交流反馈哦! diff --git a/home/i18n/zh-cn/docusaurus-plugin-content-docs/version-v1.3.x/advanced/extend-http-default.md b/home/i18n/zh-cn/docusaurus-plugin-content-docs/version-v1.3.x/advanced/extend-http-default.md index 75b3386f5b..46b4db2cc8 100644 --- a/home/i18n/zh-cn/docusaurus-plugin-content-docs/version-v1.3.x/advanced/extend-http-default.md +++ b/home/i18n/zh-cn/docusaurus-plugin-content-docs/version-v1.3.x/advanced/extend-http-default.md @@ -110,15 +110,16 @@ params: defaultValue: 80 # 参数输入框提示信息 placeholder: '请输入端口' -# 指标组列表 +# collect metrics config list +# 采集指标配置列表 metrics: -# 第一个监控指标组 cpu -# 注意:内置监控指标有 (responseTime - 响应时间) + # metrics - cpu + # 监控指标 - cpu - name: cpu - # 指标组调度优先级(0-127)越小优先级越高,优先级低的指标组会等优先级高的指标组采集完成后才会被调度,相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # 指标调度优先级(0-127)越小优先级越高,优先级低的指标会等优先级高的指标采集完成后才会被调度,相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 0 - # 指标组中的具体监控指标 + # 具体监控指标列表 fields: # 指标信息 包括 field名称 type字段类型:0-number数字,1-string字符串 instance是否为实例主键 unit:指标单位 - field: hostname diff --git a/home/i18n/zh-cn/docusaurus-plugin-content-docs/version-v1.3.x/advanced/extend-http-example-hertzbeat.md b/home/i18n/zh-cn/docusaurus-plugin-content-docs/version-v1.3.x/advanced/extend-http-example-hertzbeat.md index 0f9b1592bf..e28c428b97 100644 --- a/home/i18n/zh-cn/docusaurus-plugin-content-docs/version-v1.3.x/advanced/extend-http-example-hertzbeat.md +++ b/home/i18n/zh-cn/docusaurus-plugin-content-docs/version-v1.3.x/advanced/extend-http-example-hertzbeat.md @@ -131,15 +131,16 @@ params: type: password required: false hide: true -# 指标组列表 +# collect metrics config list +# 采集指标配置列表 metrics: - # 第一个监控指标组 summary - # 注意:内置监控指标有 (responseTime - 响应时间) + # metrics - summary + # 监控指标 - summary - name: summary - # 指标组调度优先级(0-127)越小优先级越高,优先级低的指标组会等优先级高的指标组采集完成后才会被调度,相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # 指标调度优先级(0-127)越小优先级越高,优先级低的指标会等优先级高的指标采集完成后才会被调度,相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 0 - # 指标组中的具体监控指标 + # 具体监控指标列表 fields: # 指标信息 包括 field名称 type字段类型:0-number数字,1-string字符串 instance是否为实例主键 unit:指标单位 - field: responseTime diff --git a/home/i18n/zh-cn/docusaurus-plugin-content-docs/version-v1.3.x/advanced/extend-http-example-token.md b/home/i18n/zh-cn/docusaurus-plugin-content-docs/version-v1.3.x/advanced/extend-http-example-token.md index c674c25350..5a8b7a9c1f 100644 --- a/home/i18n/zh-cn/docusaurus-plugin-content-docs/version-v1.3.x/advanced/extend-http-example-token.md +++ b/home/i18n/zh-cn/docusaurus-plugin-content-docs/version-v1.3.x/advanced/extend-http-example-token.md @@ -4,13 +4,13 @@ title: 教程二:基于HTTP协议获取TOKEN指标值,给后续采集认证使 sidebar_label: 教程二:获取TOKEN后续认证使用 --- -通过此教程我们一步一步描述如何在教程一的基础上改造,新增一个指标组,先调用认证接口获取TOKEN后,使用TOKEN作为参数供后面的指标组采集认证使用。 +通过此教程我们一步一步描述如何在教程一的基础上改造,新增一个监控指标,先调用认证接口获取TOKEN后,使用TOKEN作为参数供后面的监控指标采集认证使用。 阅读此教程前我们希望您已经从[自定义监控](extend-point)和[http协议自定义](extend-http)了解熟悉了怎么自定义类型,指标,协议等。 ### 请求流程 -【**认证信息指标组(优先级最高)**】【**HTTP接口携带账户密码调用**】->【**响应数据解析**】->【**解析签发TOKEN-accessToken作为指标**】->【**将accessToken作为变量参数赋值给其他采集指标组**】 +【**认证信息监控指标(优先级最高)**】【**HTTP接口携带账户密码调用**】->【**响应数据解析**】->【**解析签发TOKEN-accessToken作为指标**】->【**将accessToken作为变量参数赋值给其他采集监控指标**】 > 这里我们依然用教程一的hertzbeat监控举例!hertzbeat后台接口不仅仅支持教程一使用的basic直接账户密码认证,也支持token认证。 @@ -94,14 +94,14 @@ params: type: textarea placeholder: 'Available When POST PUT' required: false -# 指标组列表 todo 下方配置 +# 采集指标配置列表 todo 下方配置 metrics: ...... ``` -### 定义指标组`auth`登录请求获取`token` +### 定义监控指标`auth`登录请求获取`token` -1. 在`app-hertzbeat_token.yml`新增一个指标组定义 `auth`, 设置采集优先级为最高0,采集指标 `token`. +1. 在`app-hertzbeat_token.yml`新增一个监控指标定义 `auth`, 设置采集优先级为最高0,采集指标 `token`. ```yaml @@ -156,15 +156,15 @@ params: type: textarea placeholder: 'Available When POST PUT' required: false -# 指标组列表 +# 采集指标配置列表 metrics: - # 第一个监控指标组 auth + # 第一个监控指标 auth # 注意:内置监控指标有 (responseTime - 响应时间) - name: auth - # 指标组调度优先级(0-127)越小优先级越高,优先级低的指标组会等优先级高的指标组采集完成后才会被调度,相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # 指标调度优先级(0-127)越小优先级越高,优先级低的指标会等优先级高的指标采集完成后才会被调度,相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 0 - # 指标组中的具体监控指标 + # 具体监控指标列表 fields: # 指标信息 包括 field名称 type字段类型:0-number数字,1-string字符串 instance是否为实例主键 unit:指标单位 - field: token @@ -215,10 +215,10 @@ metrics: -### 将`token`作为变量参数给后面的指标组采集使用 +### 将`token`作为变量参数给后面的监控指标采集使用 -**在`app-hertzbeat_token.yml`新增一个指标组定义 `summary` 同教程一中的`summary`相同, 设置采集优先级为1** -**设置此指标组的HTTP协议配置中认证方式为 `Bearer Token` 将上一个指标组`auth`采集的指标`token`作为参数给其赋值,使用`^o^`作为内部替换符标识,即`^o^token^o^`。如下:** +**在`app-hertzbeat_token.yml`新增一个监控指标定义 `summary` 同教程一中的`summary`相同, 设置采集优先级为1** +**设置此监控指标的HTTP协议配置中认证方式为 `Bearer Token` 将上一个监控指标`auth`采集的指标`token`作为参数给其赋值,使用`^o^`作为内部替换符标识,即`^o^token^o^`。如下:** ```yaml - name: summary @@ -286,15 +286,15 @@ params: type: textarea placeholder: 'Available When POST PUT' required: false -# 指标组列表 +# 采集指标配置列表 metrics: -# 第一个监控指标组 cpu +# 第一个监控指标 cpu # 注意:内置监控指标有 (responseTime - 响应时间) - name: auth - # 指标组调度优先级(0-127)越小优先级越高,优先级低的指标组会等优先级高的指标组采集完成后才会被调度,相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # 指标调度优先级(0-127)越小优先级越高,优先级低的指标会等优先级高的指标采集完成后才会被调度,相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 0 - # 指标组中的具体监控指标 + # 具体监控指标列表 fields: # 指标信息 包括 field名称 type字段类型:0-number数字,1-string字符串 instance是否为实例主键 unit:指标单位 - field: token @@ -329,10 +329,10 @@ metrics: - name: summary - # 指标组调度优先级(0-127)越小优先级越高,优先级低的指标组会等优先级高的指标组采集完成后才会被调度,相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # 指标调度优先级(0-127)越小优先级越高,优先级低的指标会等优先级高的指标采集完成后才会被调度,相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 1 - # 指标组中的具体监控指标 + # 具体监控指标列表 fields: # 指标信息 包括 field名称 type字段类型:0-number数字,1-string字符串 instance是否为实例主键 unit:指标单位 - field: category diff --git a/home/i18n/zh-cn/docusaurus-plugin-content-docs/version-v1.3.x/advanced/extend-http-jsonpath.md b/home/i18n/zh-cn/docusaurus-plugin-content-docs/version-v1.3.x/advanced/extend-http-jsonpath.md index 779479985a..b46f918f4e 100644 --- a/home/i18n/zh-cn/docusaurus-plugin-content-docs/version-v1.3.x/advanced/extend-http-jsonpath.md +++ b/home/i18n/zh-cn/docusaurus-plugin-content-docs/version-v1.3.x/advanced/extend-http-jsonpath.md @@ -130,15 +130,15 @@ params: defaultValue: 80 # 参数输入框提示信息 placeholder: '请输入端口' -# 指标组列表 +# 采集指标配置列表 metrics: -# 第一个监控指标组 person +# 第一个监控指标 person # 注意:内置监控指标有 (responseTime - 响应时间) - name: cpu - # 指标组调度优先级(0-127)越小优先级越高,优先级低的指标组会等优先级高的指标组采集完成后才会被调度,相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # 指标调度优先级(0-127)越小优先级越高,优先级低的指标会等优先级高的指标采集完成后才会被调度,相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 0 - # 指标组中的具体监控指标 + # 具体监控指标列表 fields: # 指标信息 包括 field名称 type字段类型:0-number数字,1-string字符串 instance是否为实例主键 unit:指标单位 - field: type diff --git a/home/i18n/zh-cn/docusaurus-plugin-content-docs/version-v1.3.x/advanced/extend-http.md b/home/i18n/zh-cn/docusaurus-plugin-content-docs/version-v1.3.x/advanced/extend-http.md index 82ffb8f6e5..8fffc30db0 100644 --- a/home/i18n/zh-cn/docusaurus-plugin-content-docs/version-v1.3.x/advanced/extend-http.md +++ b/home/i18n/zh-cn/docusaurus-plugin-content-docs/version-v1.3.x/advanced/extend-http.md @@ -103,15 +103,15 @@ params: value: PUT - label: DELETE请求 value: DELETE -# 指标组列表 +# 采集指标配置列表 metrics: -# 第一个监控指标组 cpu +# 第一个监控指标 cpu # 注意:内置监控指标有 (responseTime - 响应时间) - name: cpu - # 指标组调度优先级(0-127)越小优先级越高,优先级低的指标组会等优先级高的指标组采集完成后才会被调度,相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # 指标调度优先级(0-127)越小优先级越高,优先级低的指标会等优先级高的指标采集完成后才会被调度,相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 0 - # 指标组中的具体监控指标 + # 具体监控指标列表 fields: # 指标信息 包括 field名称 type字段类型:0-number数字,1-string字符串 instance是否为实例主键 unit:指标单位 - field: hostname diff --git a/home/i18n/zh-cn/docusaurus-plugin-content-docs/version-v1.3.x/advanced/extend-jdbc.md b/home/i18n/zh-cn/docusaurus-plugin-content-docs/version-v1.3.x/advanced/extend-jdbc.md index fbbee1f2d8..8e7cf154bb 100644 --- a/home/i18n/zh-cn/docusaurus-plugin-content-docs/version-v1.3.x/advanced/extend-jdbc.md +++ b/home/i18n/zh-cn/docusaurus-plugin-content-docs/version-v1.3.x/advanced/extend-jdbc.md @@ -115,13 +115,14 @@ params: en-US: Url type: text required: false -# 指标组列表 +# collect metrics config list +# 采集指标配置列表 metrics: - name: basic - # 指标组调度优先级(0-127)越小优先级越高,优先级低的指标组会等优先级高的指标组采集完成后才会被调度,相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # 指标调度优先级(0-127)越小优先级越高,优先级低的指标会等优先级高的指标采集完成后才会被调度,相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 0 - # 指标组中的具体监控指标 + # 具体监控指标列表 fields: # 指标信息 包括 field名称 type字段类型:0-number数字,1-string字符串 instance是否为实例主键 unit:指标单位 - field: version diff --git a/home/i18n/zh-cn/docusaurus-plugin-content-docs/version-v1.3.x/advanced/extend-jmx.md b/home/i18n/zh-cn/docusaurus-plugin-content-docs/version-v1.3.x/advanced/extend-jmx.md index 3f04462f00..4b1a2369e9 100644 --- a/home/i18n/zh-cn/docusaurus-plugin-content-docs/version-v1.3.x/advanced/extend-jmx.md +++ b/home/i18n/zh-cn/docusaurus-plugin-content-docs/version-v1.3.x/advanced/extend-jmx.md @@ -141,20 +141,20 @@ params: # 是否隐藏字段 true or false hide: true # collect metrics config list -# 采集指标组配置列表 +# 采集指标配置列表 metrics: # metrics - basic - # 监控指标组 - basic + # 监控指标 - basic - name: basic - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue - # 指标组调度优先级(0->127)->(优先级高->低) 优先级低的指标组会等优先级高的指标组采集完成后才会被调度, 相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # 指标采集调度优先级(0->127)->(优先级高->低) 优先级低的指标会等优先级高的指标采集完成后才会被调度, 相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 0 # collect metrics content # 具体监控指标列表 fields: - # field-metric name, type-metric type(0-number,1-string), unit-metric unit('%','ms','MB'), instance-if is metrics group unique identifier + # field-metric name, type-metric type(0-number,1-string), unit-metric unit('%','ms','MB'), instance-if is metrics unique identifier # field-指标名称, type-指标类型(0-number数字,1-string字符串), unit-指标单位('%','ms','MB'), instance-是否是指标集合唯一标识符字段 - field: VmName type: 1 diff --git a/home/i18n/zh-cn/docusaurus-plugin-content-docs/version-v1.3.x/advanced/extend-point.md b/home/i18n/zh-cn/docusaurus-plugin-content-docs/version-v1.3.x/advanced/extend-point.md index 92ab49b1b3..482dc583ab 100644 --- a/home/i18n/zh-cn/docusaurus-plugin-content-docs/version-v1.3.x/advanced/extend-point.md +++ b/home/i18n/zh-cn/docusaurus-plugin-content-docs/version-v1.3.x/advanced/extend-point.md @@ -129,18 +129,18 @@ params: metrics: # metrics - summary, inner monitoring metrics (responseTime - response time, keyword - number of keywords) - # 监控指标组 - summary, 内置监控指标有 (responseTime - 响应时间, keyword - 关键字数量) + # 监控指标 - summary, 内置监控指标有 (responseTime - 响应时间, keyword - 关键字数量) - name: summary - # 指标组调度优先级(0-127)越小优先级越高,优先级低的指标组会等优先级高的指标组采集完成后才会被调度,相同优先级的指标组会并行调度采集 - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue - # 指标组调度优先级(0->127)->(优先级高->低) 优先级低的指标组会等优先级高的指标组采集完成后才会被调度, 相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # 指标调度优先级(0-127)越小优先级越高,优先级低的指标会等优先级高的指标采集完成后才会被调度,相同优先级的指标会并行调度采集 + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # 指标采集调度优先级(0->127)->(优先级高->低) 优先级低的指标会等优先级高的指标采集完成后才会被调度, 相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 0 # collect metrics content # 具体监控指标列表 fields: - # field-metric name, type-metric type(0-number,1-string), unit-metric unit('%','ms','MB'), instance-if is metrics group unique identifier + # field-metric name, type-metric type(0-number,1-string), unit-metric unit('%','ms','MB'), instance-if is metrics unique identifier # field-指标名称, type-指标类型(0-number数字,1-string字符串), unit-指标单位('%','ms','MB'), instance-是否是指标集合唯一标识符字段 - field: responseTime type: 0 diff --git a/home/i18n/zh-cn/docusaurus-plugin-content-docs/version-v1.3.x/advanced/extend-snmp.md b/home/i18n/zh-cn/docusaurus-plugin-content-docs/version-v1.3.x/advanced/extend-snmp.md index ad7f9cfb95..89f94376c3 100644 --- a/home/i18n/zh-cn/docusaurus-plugin-content-docs/version-v1.3.x/advanced/extend-snmp.md +++ b/home/i18n/zh-cn/docusaurus-plugin-content-docs/version-v1.3.x/advanced/extend-snmp.md @@ -148,20 +148,20 @@ params: # 默认值 defaultValue: 6000 # collect metrics config list -# 采集指标组配置列表 +# 采集指标配置列表 metrics: # metrics - system - # 监控指标组 - system + # 监控指标 - system - name: system - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue - # 指标组调度优先级(0->127)->(优先级高->低) 优先级低的指标组会等优先级高的指标组采集完成后才会被调度, 相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # 指标采集调度优先级(0->127)->(优先级高->低) 优先级低的指标会等优先级高的指标采集完成后才会被调度, 相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 0 # collect metrics content # 具体监控指标列表 fields: - # field-metric name, type-metric type(0-number,1-string), unit-metric unit('%','ms','MB'), instance-if is metrics group unique identifier + # field-metric name, type-metric type(0-number,1-string), unit-metric unit('%','ms','MB'), instance-if is metrics unique identifier # field-指标名称, type-指标类型(0-number数字,1-string字符串), unit-指标单位('%','ms','MB'), instance-是否是指标集合唯一标识符字段 - field: name type: 1 diff --git a/home/i18n/zh-cn/docusaurus-plugin-content-docs/version-v1.3.x/advanced/extend-ssh.md b/home/i18n/zh-cn/docusaurus-plugin-content-docs/version-v1.3.x/advanced/extend-ssh.md index 650c7d51a5..65df406a76 100644 --- a/home/i18n/zh-cn/docusaurus-plugin-content-docs/version-v1.3.x/advanced/extend-ssh.md +++ b/home/i18n/zh-cn/docusaurus-plugin-content-docs/version-v1.3.x/advanced/extend-ssh.md @@ -111,15 +111,15 @@ params: en-US: Password type: password required: true -# 指标组列表 +# 采集指标配置列表 metrics: - # 第一个监控指标组 basic + # 第一个监控指标 basic # 注意:内置监控指标有 (responseTime - 响应时间) - name: basic - # 指标组调度优先级(0-127)越小优先级越高,优先级低的指标组会等优先级高的指标组采集完成后才会被调度,相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # 指标调度优先级(0-127)越小优先级越高,优先级低的指标会等优先级高的指标采集完成后才会被调度,相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 0 - # 指标组中的具体监控指标 + # 具体监控指标列表 fields: # 指标信息 包括 field名称 type字段类型:0-number数字,1-string字符串 instance是否为实例主键 unit:指标单位 - field: hostname diff --git a/home/i18n/zh-cn/docusaurus-plugin-content-docs/version-v1.3.x/advanced/extend-tutorial.md b/home/i18n/zh-cn/docusaurus-plugin-content-docs/version-v1.3.x/advanced/extend-tutorial.md index fabfa75806..e8e79620c9 100644 --- a/home/i18n/zh-cn/docusaurus-plugin-content-docs/version-v1.3.x/advanced/extend-tutorial.md +++ b/home/i18n/zh-cn/docusaurus-plugin-content-docs/version-v1.3.x/advanced/extend-tutorial.md @@ -159,18 +159,16 @@ params: metrics: # the first metrics summary # attention: Built-in monitoring metrics contains (responseTime - Response time) - # 第一个监控指标组 summary - # 注意:内置监控指标有 (responseTime - 响应时间) - name: summary - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue - # 指标组调度优先级(0-127)越小优先级越高,优先级低的指标组会等优先级高的指标组采集完成后才会被调度,相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # 指标调度优先级(0-127)越小优先级越高,优先级低的指标会等优先级高的指标采集完成后才会被调度,相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 0 # collect metrics content - # 指标组中的具体监控指标 + # 具体监控指标列表 fields: - # metrics content contains field-metric name, type-metric type:0-number,1-string, instance-if is metrics group, unit-metric unit('%','ms','MB') + # metrics content contains field-metric name, type-metric type:0-number,1-string, instance-if is metrics, unit-metric unit('%','ms','MB') # 指标信息 包括 field名称 type字段类型:0-number数字,1-string字符串 instance是否为实例主键 unit:指标单位 - field: app type: 1 diff --git a/home/i18n/zh-cn/docusaurus-plugin-content-docs/version-v1.3.x/help/alert_threshold_expr.md b/home/i18n/zh-cn/docusaurus-plugin-content-docs/version-v1.3.x/help/alert_threshold_expr.md index 6e4911b843..14fbcdb13d 100644 --- a/home/i18n/zh-cn/docusaurus-plugin-content-docs/version-v1.3.x/help/alert_threshold_expr.md +++ b/home/i18n/zh-cn/docusaurus-plugin-content-docs/version-v1.3.x/help/alert_threshold_expr.md @@ -47,7 +47,7 @@ equals(str1,str2) `responseTime>3000` 3. 全站监控->URL(instance)路径为 `https://baidu.com/book/3` 的响应时间大于200ms时触发告警 `equals(instance,"https://baidu.com/book/3")&&responseTime>200` -4. MYSQL监控->status指标组->threads_running(运行线程数)指标大于7时触发告警 +4. MYSQL监控->status指标->threads_running(运行线程数)指标大于7时触发告警 `threads_running>7` 若遇到问题可以通过交流群ISSUE交流反馈哦! diff --git a/home/i18n/zh-cn/docusaurus-plugin-content-docs/version-v1.3.x/help/alert_webhook.md b/home/i18n/zh-cn/docusaurus-plugin-content-docs/version-v1.3.x/help/alert_webhook.md index f02526bc2a..2f1b5ff36a 100644 --- a/home/i18n/zh-cn/docusaurus-plugin-content-docs/version-v1.3.x/help/alert_webhook.md +++ b/home/i18n/zh-cn/docusaurus-plugin-content-docs/version-v1.3.x/help/alert_webhook.md @@ -54,7 +54,7 @@ keywords: [告警 Webhook 回调通知, 开源告警系统, 开源监控告警 | nextEvalInterval | integer($int64) title: Alarm evaluation interval (milliseconds) 告警评估时间间隔(单位毫秒) | | tags | example: {key1:value1} | | gmtCreate | string($date-time) title: Record the latest creation time (timestamp in milliseconds) 记录最新创建时间(毫秒时间戳) | -| gmtUpdate |string($date-time) title: 记录最新修改时间(毫秒时间戳) | +| gmtUpdate |string($date-time) title: Record modify time(毫秒时间戳) | ### webhook通知常见问题 diff --git a/home/versioned_docs/version-v1.0.0/advanced/extend-http-default.md b/home/versioned_docs/version-v1.0.0/advanced/extend-http-default.md index a604330af8..86a621bf20 100644 --- a/home/versioned_docs/version-v1.0.0/advanced/extend-http-default.md +++ b/home/versioned_docs/version-v1.0.0/advanced/extend-http-default.md @@ -93,15 +93,15 @@ configmap: type: 1 - key: port type: 0 -# 指标组列表 +# 采集指标配置列表 metrics: -# 第一个监控指标组 cpu +# 第一个监控指标 cpu # 注意:内置监控指标有 (responseTime - 响应时间) - name: cpu - # 指标组调度优先级(0-127)越小优先级越高,优先级低的指标组会等优先级高的指标组采集完成后才会被调度,相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # 指标调度优先级(0-127)越小优先级越高,优先级低的指标会等优先级高的指标采集完成后才会被调度,相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 0 - # 指标组中的具体监控指标 + # 具体监控指标列表 fields: # 指标信息 包括 field名称 type字段类型:0-number数字,1-string字符串 instance是否为实例主键 unit:指标单位 - field: hostname diff --git a/home/versioned_docs/version-v1.0.0/advanced/extend-http-jsonpath.md b/home/versioned_docs/version-v1.0.0/advanced/extend-http-jsonpath.md index 78a9187642..3ce1f16f87 100644 --- a/home/versioned_docs/version-v1.0.0/advanced/extend-http-jsonpath.md +++ b/home/versioned_docs/version-v1.0.0/advanced/extend-http-jsonpath.md @@ -113,15 +113,15 @@ configmap: type: 1 - key: port type: 0 -# 指标组列表 +# 采集指标配置列表 metrics: -# 第一个监控指标组 person +# 第一个监控指标 person # 注意:内置监控指标有 (responseTime - 响应时间) - name: cpu - # 指标组调度优先级(0-127)越小优先级越高,优先级低的指标组会等优先级高的指标组采集完成后才会被调度,相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # 指标调度优先级(0-127)越小优先级越高,优先级低的指标会等优先级高的指标采集完成后才会被调度,相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 0 - # 指标组中的具体监控指标 + # 具体监控指标列表 fields: # 指标信息 包括 field名称 type字段类型:0-number数字,1-string字符串 instance是否为实例主键 unit:指标单位 - field: type diff --git a/home/versioned_docs/version-v1.0.0/advanced/extend-http.md b/home/versioned_docs/version-v1.0.0/advanced/extend-http.md index d457222ce5..dd95a9ff15 100644 --- a/home/versioned_docs/version-v1.0.0/advanced/extend-http.md +++ b/home/versioned_docs/version-v1.0.0/advanced/extend-http.md @@ -52,15 +52,15 @@ configmap: type: 1 - key: password type: 2 -# 指标组列表 +# 采集指标配置列表 metrics: -# 第一个监控指标组 cpu +# 第一个监控指标 cpu # 注意:内置监控指标有 (responseTime - 响应时间) - name: cpu - # 指标组调度优先级(0-127)越小优先级越高,优先级低的指标组会等优先级高的指标组采集完成后才会被调度,相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # 指标调度优先级(0-127)越小优先级越高,优先级低的指标会等优先级高的指标采集完成后才会被调度,相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 0 - # 指标组中的具体监控指标 + # 具体监控指标列表 fields: # 指标信息 包括 field名称 type字段类型:0-number数字,1-string字符串 instance是否为实例主键 unit:指标单位 - field: hostname diff --git a/home/versioned_docs/version-v1.0.0/advanced/extend-jdbc.md b/home/versioned_docs/version-v1.0.0/advanced/extend-jdbc.md index d0b348f0db..a6c376b381 100644 --- a/home/versioned_docs/version-v1.0.0/advanced/extend-jdbc.md +++ b/home/versioned_docs/version-v1.0.0/advanced/extend-jdbc.md @@ -88,13 +88,13 @@ configmap: type: 1 - key: url type: 1 -# 指标组列表 +# 采集指标配置列表 metrics: - name: basic - # 指标组调度优先级(0-127)越小优先级越高,优先级低的指标组会等优先级高的指标组采集完成后才会被调度,相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # 指标调度优先级(0-127)越小优先级越高,优先级低的指标会等优先级高的指标采集完成后才会被调度,相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 0 - # 指标组中的具体监控指标 + # 具体监控指标列表 fields: # 指标信息 包括 field名称 type字段类型:0-number数字,1-string字符串 instance是否为实例主键 unit:指标单位 - field: version diff --git a/home/versioned_docs/version-v1.0.0/advanced/extend-point.md b/home/versioned_docs/version-v1.0.0/advanced/extend-point.md index c31489e9fe..6d646de667 100644 --- a/home/versioned_docs/version-v1.0.0/advanced/extend-point.md +++ b/home/versioned_docs/version-v1.0.0/advanced/extend-point.md @@ -43,15 +43,15 @@ configmap: type: 1 - key: password type: 2 -# 指标组列表 +# 采集指标配置列表 metrics: -# 第一个监控指标组 cpu +# 第一个监控指标 cpu # 注意:内置监控指标有 (responseTime - 响应时间) - name: cpu - # 指标组调度优先级(0-127)越小优先级越高,优先级低的指标组会等优先级高的指标组采集完成后才会被调度,相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # 指标调度优先级(0-127)越小优先级越高,优先级低的指标会等优先级高的指标采集完成后才会被调度,相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 0 - # 指标组中的具体监控指标 + # 具体监控指标列表 fields: # 指标信息 包括 field名称 type字段类型:0-number数字,1-string字符串 instance是否为实例主键 unit:指标单位 - field: hostname diff --git a/home/versioned_docs/version-v1.0.0/advanced/extend-ssh.md b/home/versioned_docs/version-v1.0.0/advanced/extend-ssh.md index e5ce61bc7c..d1901cbfd8 100644 --- a/home/versioned_docs/version-v1.0.0/advanced/extend-ssh.md +++ b/home/versioned_docs/version-v1.0.0/advanced/extend-ssh.md @@ -92,15 +92,15 @@ configmap: type: 1 - key: password type: 2 -# 指标组列表 +# 采集指标配置列表 metrics: - # 第一个监控指标组 basic + # 第一个监控指标 basic # 注意:内置监控指标有 (responseTime - 响应时间) - name: basic - # 指标组调度优先级(0-127)越小优先级越高,优先级低的指标组会等优先级高的指标组采集完成后才会被调度,相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # 指标调度优先级(0-127)越小优先级越高,优先级低的指标会等优先级高的指标采集完成后才会被调度,相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 0 - # 指标组中的具体监控指标 + # 具体监控指标列表 fields: # 指标信息 包括 field名称 type字段类型:0-number数字,1-string字符串 instance是否为实例主键 unit:指标单位 - field: hostname diff --git a/home/versioned_docs/version-v1.0.0/help/alert_threshold_expr.md b/home/versioned_docs/version-v1.0.0/help/alert_threshold_expr.md index f6a167523b..fe0339507c 100644 --- a/home/versioned_docs/version-v1.0.0/help/alert_threshold_expr.md +++ b/home/versioned_docs/version-v1.0.0/help/alert_threshold_expr.md @@ -43,7 +43,7 @@ equals(str1,str2) `responseTime>3000` 3. 全站监控->URL(instance)路径为 `https://baidu.com/book/3` 的响应时间大于200ms时触发告警 `equals(instance,"https://baidu.com/book/3")&&responseTime>200` -4. MYSQL监控->status指标组->threads_running(运行线程数)指标大于7时触发告警 +4. MYSQL监控->status指标->threads_running(运行线程数)指标大于7时触发告警 `threads_running>7` 若遇到问题可以通过交流群ISSUE交流反馈哦! diff --git a/home/versioned_docs/version-v1.1.x/advanced/extend-http-default.md b/home/versioned_docs/version-v1.1.x/advanced/extend-http-default.md index f47b726c97..f86b6492f4 100644 --- a/home/versioned_docs/version-v1.1.x/advanced/extend-http-default.md +++ b/home/versioned_docs/version-v1.1.x/advanced/extend-http-default.md @@ -110,15 +110,15 @@ params: defaultValue: 80 # 参数输入框提示信息 placeholder: '请输入端口' -# 指标组列表 +# 采集指标配置列表 metrics: -# 第一个监控指标组 cpu +# 第一个监控指标 cpu # 注意:内置监控指标有 (responseTime - 响应时间) - name: cpu - # 指标组调度优先级(0-127)越小优先级越高,优先级低的指标组会等优先级高的指标组采集完成后才会被调度,相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # 指标调度优先级(0-127)越小优先级越高,优先级低的指标会等优先级高的指标采集完成后才会被调度,相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 0 - # 指标组中的具体监控指标 + # 具体监控指标列表 fields: # 指标信息 包括 field名称 type字段类型:0-number数字,1-string字符串 instance是否为实例主键 unit:指标单位 - field: hostname diff --git a/home/versioned_docs/version-v1.1.x/advanced/extend-http-example-hertzbeat.md b/home/versioned_docs/version-v1.1.x/advanced/extend-http-example-hertzbeat.md index 3d7ddfafa1..b9cefb384a 100644 --- a/home/versioned_docs/version-v1.1.x/advanced/extend-http-example-hertzbeat.md +++ b/home/versioned_docs/version-v1.1.x/advanced/extend-http-example-hertzbeat.md @@ -132,15 +132,15 @@ params: type: password required: false hide: true -# 指标组列表 +# 采集指标配置列表 metrics: - # 第一个监控指标组 summary + # 第一个监控指标 summary # 注意:内置监控指标有 (responseTime - 响应时间) - name: summary - # 指标组调度优先级(0-127)越小优先级越高,优先级低的指标组会等优先级高的指标组采集完成后才会被调度,相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # 指标调度优先级(0-127)越小优先级越高,优先级低的指标会等优先级高的指标采集完成后才会被调度,相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 0 - # 指标组中的具体监控指标 + # 具体监控指标列表 fields: # 指标信息 包括 field名称 type字段类型:0-number数字,1-string字符串 instance是否为实例主键 unit:指标单位 - field: responseTime diff --git a/home/versioned_docs/version-v1.1.x/advanced/extend-http-example-token.md b/home/versioned_docs/version-v1.1.x/advanced/extend-http-example-token.md index b3bde44aae..3a44750974 100644 --- a/home/versioned_docs/version-v1.1.x/advanced/extend-http-example-token.md +++ b/home/versioned_docs/version-v1.1.x/advanced/extend-http-example-token.md @@ -4,13 +4,13 @@ title: 教程二:基于HTTP协议获取TOKEN指标值,给后续采集认证使 sidebar_label: 教程二:获取TOKEN后续认证使用 --- -通过此教程我们一步一步描述如何在教程一的基础上改造,新增一个指标组,先调用认证接口获取TOKEN后,使用TOKEN作为参数供后面的指标组采集认证使用。 +通过此教程我们一步一步描述如何在教程一的基础上改造,新增一个监控指标,先调用认证接口获取TOKEN后,使用TOKEN作为参数供后面的监控指标采集认证使用。 阅读此教程前我们希望您已经从[自定义监控](extend-point)和[http协议自定义](extend-http)了解熟悉了怎么自定义类型,指标,协议等。 ### 请求流程 -【**认证信息指标组(优先级最高)**】【**HTTP接口携带账户密码调用**】->【**响应数据解析**】->【**解析签发TOKEN-accessToken作为指标**】->【**将accessToken作为变量参数赋值给其他采集指标组**】 +【**认证信息监控指标(优先级最高)**】【**HTTP接口携带账户密码调用**】->【**响应数据解析**】->【**解析签发TOKEN-accessToken作为指标**】->【**将accessToken作为变量参数赋值给其他采集监控指标**】 > 这里我们依然用教程一的hertzbeat监控举例!hertzbeat后台接口不仅仅支持教程一使用的basic直接账户密码认证,也支持token认证。 @@ -96,14 +96,14 @@ params: type: textarea placeholder: 'Available When POST PUT' required: false -# 指标组列表 todo 下方配置 +# 采集指标配置列表 todo 下方配置 metrics: ...... ``` -### 定义指标组`auth`登录请求获取`token` +### 定义监控指标`auth`登录请求获取`token` -1. 在`app-hertzbeat_token.yml`新增一个指标组定义 `auth`, 设置采集优先级为最高0,采集指标 `token`. +1. 在`app-hertzbeat_token.yml`新增一个监控指标定义 `auth`, 设置采集优先级为最高0,采集指标 `token`. ```yaml @@ -158,15 +158,15 @@ params: type: textarea placeholder: 'Available When POST PUT' required: false -# 指标组列表 +# 采集指标配置列表 metrics: - # 第一个监控指标组 auth + # 第一个监控指标 auth # 注意:内置监控指标有 (responseTime - 响应时间) - name: auth - # 指标组调度优先级(0-127)越小优先级越高,优先级低的指标组会等优先级高的指标组采集完成后才会被调度,相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # 指标调度优先级(0-127)越小优先级越高,优先级低的指标会等优先级高的指标采集完成后才会被调度,相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 0 - # 指标组中的具体监控指标 + # 具体监控指标列表 fields: # 指标信息 包括 field名称 type字段类型:0-number数字,1-string字符串 instance是否为实例主键 unit:指标单位 - field: token @@ -217,10 +217,10 @@ metrics: -### 将`token`作为变量参数给后面的指标组采集使用 +### 将`token`作为变量参数给后面的监控指标采集使用 -**在`app-hertzbeat_token.yml`新增一个指标组定义 `summary` 同教程一中的`summary`相同, 设置采集优先级为1** -**设置此指标组的HTTP协议配置中认证方式为 `Bearer Token` 将上一个指标组`auth`采集的指标`token`作为参数给其赋值,使用`^o^`作为内部替换符标识,即`^o^token^o^`。如下:** +**在`app-hertzbeat_token.yml`新增一个监控指标定义 `summary` 同教程一中的`summary`相同, 设置采集优先级为1** +**设置此监控指标的HTTP协议配置中认证方式为 `Bearer Token` 将上一个监控指标`auth`采集的指标`token`作为参数给其赋值,使用`^o^`作为内部替换符标识,即`^o^token^o^`。如下:** ```yaml - name: summary @@ -288,15 +288,15 @@ params: type: textarea placeholder: 'Available When POST PUT' required: false -# 指标组列表 +# 采集指标配置列表 metrics: -# 第一个监控指标组 cpu +# 第一个监控指标 cpu # 注意:内置监控指标有 (responseTime - 响应时间) - name: auth - # 指标组调度优先级(0-127)越小优先级越高,优先级低的指标组会等优先级高的指标组采集完成后才会被调度,相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # 指标调度优先级(0-127)越小优先级越高,优先级低的指标会等优先级高的指标采集完成后才会被调度,相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 0 - # 指标组中的具体监控指标 + # 具体监控指标列表 fields: # 指标信息 包括 field名称 type字段类型:0-number数字,1-string字符串 instance是否为实例主键 unit:指标单位 - field: token @@ -331,10 +331,10 @@ metrics: - name: summary - # 指标组调度优先级(0-127)越小优先级越高,优先级低的指标组会等优先级高的指标组采集完成后才会被调度,相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # 指标调度优先级(0-127)越小优先级越高,优先级低的指标会等优先级高的指标采集完成后才会被调度,相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 1 - # 指标组中的具体监控指标 + # 具体监控指标列表 fields: # 指标信息 包括 field名称 type字段类型:0-number数字,1-string字符串 instance是否为实例主键 unit:指标单位 - field: category diff --git a/home/versioned_docs/version-v1.1.x/advanced/extend-http-jsonpath.md b/home/versioned_docs/version-v1.1.x/advanced/extend-http-jsonpath.md index f78d977047..8395d0879a 100644 --- a/home/versioned_docs/version-v1.1.x/advanced/extend-http-jsonpath.md +++ b/home/versioned_docs/version-v1.1.x/advanced/extend-http-jsonpath.md @@ -130,15 +130,15 @@ params: defaultValue: 80 # 参数输入框提示信息 placeholder: '请输入端口' -# 指标组列表 +# 采集指标配置列表 metrics: -# 第一个监控指标组 person +# 第一个监控指标 person # 注意:内置监控指标有 (responseTime - 响应时间) - name: cpu - # 指标组调度优先级(0-127)越小优先级越高,优先级低的指标组会等优先级高的指标组采集完成后才会被调度,相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # 指标调度优先级(0-127)越小优先级越高,优先级低的指标会等优先级高的指标采集完成后才会被调度,相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 0 - # 指标组中的具体监控指标 + # 具体监控指标列表 fields: # 指标信息 包括 field名称 type字段类型:0-number数字,1-string字符串 instance是否为实例主键 unit:指标单位 - field: type diff --git a/home/versioned_docs/version-v1.1.x/advanced/extend-http.md b/home/versioned_docs/version-v1.1.x/advanced/extend-http.md index eb128edbd3..dcb7e03aa0 100644 --- a/home/versioned_docs/version-v1.1.x/advanced/extend-http.md +++ b/home/versioned_docs/version-v1.1.x/advanced/extend-http.md @@ -102,15 +102,15 @@ params: value: PUT - label: DELETE请求 value: DELETE -# 指标组列表 +# 采集指标配置列表 metrics: -# 第一个监控指标组 cpu +# 第一个监控指标 cpu # 注意:内置监控指标有 (responseTime - 响应时间) - name: cpu - # 指标组调度优先级(0-127)越小优先级越高,优先级低的指标组会等优先级高的指标组采集完成后才会被调度,相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # 指标调度优先级(0-127)越小优先级越高,优先级低的指标会等优先级高的指标采集完成后才会被调度,相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 0 - # 指标组中的具体监控指标 + # 具体监控指标列表 fields: # 指标信息 包括 field名称 type字段类型:0-number数字,1-string字符串 instance是否为实例主键 unit:指标单位 - field: hostname diff --git a/home/versioned_docs/version-v1.1.x/advanced/extend-jdbc.md b/home/versioned_docs/version-v1.1.x/advanced/extend-jdbc.md index 4a676abf0e..98b3ed0bf6 100644 --- a/home/versioned_docs/version-v1.1.x/advanced/extend-jdbc.md +++ b/home/versioned_docs/version-v1.1.x/advanced/extend-jdbc.md @@ -116,13 +116,13 @@ params: en-US: Url type: text required: false -# 指标组列表 +# 采集指标配置列表 metrics: - name: basic - # 指标组调度优先级(0-127)越小优先级越高,优先级低的指标组会等优先级高的指标组采集完成后才会被调度,相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # 指标调度优先级(0-127)越小优先级越高,优先级低的指标会等优先级高的指标采集完成后才会被调度,相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 0 - # 指标组中的具体监控指标 + # 具体监控指标列表 fields: # 指标信息 包括 field名称 type字段类型:0-number数字,1-string字符串 instance是否为实例主键 unit:指标单位 - field: version diff --git a/home/versioned_docs/version-v1.1.x/advanced/extend-point.md b/home/versioned_docs/version-v1.1.x/advanced/extend-point.md index 5f63151475..d48f60208e 100644 --- a/home/versioned_docs/version-v1.1.x/advanced/extend-point.md +++ b/home/versioned_docs/version-v1.1.x/advanced/extend-point.md @@ -92,15 +92,15 @@ params: value: PUT - label: DELETE请求 value: DELETE -# 指标组列表 +# 采集指标配置列表 metrics: -# 第一个监控指标组 cpu +# 第一个监控指标 cpu # 注意:内置监控指标有 (responseTime - 响应时间) - name: cpu - # 指标组调度优先级(0-127)越小优先级越高,优先级低的指标组会等优先级高的指标组采集完成后才会被调度,相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # 指标调度优先级(0-127)越小优先级越高,优先级低的指标会等优先级高的指标采集完成后才会被调度,相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 0 - # 指标组中的具体监控指标 + # 具体监控指标列表 fields: # 指标信息 包括 field名称 type字段类型:0-number数字,1-string字符串 instance是否为实例主键 unit:指标单位 - field: hostname diff --git a/home/versioned_docs/version-v1.1.x/advanced/extend-ssh.md b/home/versioned_docs/version-v1.1.x/advanced/extend-ssh.md index c1470f4612..12c1272cf1 100644 --- a/home/versioned_docs/version-v1.1.x/advanced/extend-ssh.md +++ b/home/versioned_docs/version-v1.1.x/advanced/extend-ssh.md @@ -111,15 +111,15 @@ params: en-US: Password type: password required: true -# 指标组列表 +# 采集指标配置列表 metrics: - # 第一个监控指标组 basic + # 第一个监控指标 basic # 注意:内置监控指标有 (responseTime - 响应时间) - name: basic - # 指标组调度优先级(0-127)越小优先级越高,优先级低的指标组会等优先级高的指标组采集完成后才会被调度,相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # 指标调度优先级(0-127)越小优先级越高,优先级低的指标会等优先级高的指标采集完成后才会被调度,相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 0 - # 指标组中的具体监控指标 + # 具体监控指标列表 fields: # 指标信息 包括 field名称 type字段类型:0-number数字,1-string字符串 instance是否为实例主键 unit:指标单位 - field: hostname diff --git a/home/versioned_docs/version-v1.1.x/advanced/extend-tutorial.md b/home/versioned_docs/version-v1.1.x/advanced/extend-tutorial.md index a91993ce04..bf47cb9426 100644 --- a/home/versioned_docs/version-v1.1.x/advanced/extend-tutorial.md +++ b/home/versioned_docs/version-v1.1.x/advanced/extend-tutorial.md @@ -132,15 +132,15 @@ params: type: password required: false hide: true -# 指标组列表 +# 采集指标配置列表 metrics: - # 第一个监控指标组 summary + # 第一个监控指标 summary # 注意:内置监控指标有 (responseTime - 响应时间) - name: summary - # 指标组调度优先级(0-127)越小优先级越高,优先级低的指标组会等优先级高的指标组采集完成后才会被调度,相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # 指标调度优先级(0-127)越小优先级越高,优先级低的指标会等优先级高的指标采集完成后才会被调度,相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 0 - # 指标组中的具体监控指标 + # 具体监控指标列表 fields: # 指标信息 包括 field名称 type字段类型:0-number数字,1-string字符串 instance是否为实例主键 unit:指标单位 - field: responseTime diff --git a/home/versioned_docs/version-v1.1.x/help/alert_threshold_expr.md b/home/versioned_docs/version-v1.1.x/help/alert_threshold_expr.md index 6e4911b843..14fbcdb13d 100644 --- a/home/versioned_docs/version-v1.1.x/help/alert_threshold_expr.md +++ b/home/versioned_docs/version-v1.1.x/help/alert_threshold_expr.md @@ -47,7 +47,7 @@ equals(str1,str2) `responseTime>3000` 3. 全站监控->URL(instance)路径为 `https://baidu.com/book/3` 的响应时间大于200ms时触发告警 `equals(instance,"https://baidu.com/book/3")&&responseTime>200` -4. MYSQL监控->status指标组->threads_running(运行线程数)指标大于7时触发告警 +4. MYSQL监控->status指标->threads_running(运行线程数)指标大于7时触发告警 `threads_running>7` 若遇到问题可以通过交流群ISSUE交流反馈哦! diff --git a/home/versioned_docs/version-v1.1.x/help/alert_webhook.md b/home/versioned_docs/version-v1.1.x/help/alert_webhook.md index f02526bc2a..2f1b5ff36a 100644 --- a/home/versioned_docs/version-v1.1.x/help/alert_webhook.md +++ b/home/versioned_docs/version-v1.1.x/help/alert_webhook.md @@ -54,7 +54,7 @@ keywords: [告警 Webhook 回调通知, 开源告警系统, 开源监控告警 | nextEvalInterval | integer($int64) title: Alarm evaluation interval (milliseconds) 告警评估时间间隔(单位毫秒) | | tags | example: {key1:value1} | | gmtCreate | string($date-time) title: Record the latest creation time (timestamp in milliseconds) 记录最新创建时间(毫秒时间戳) | -| gmtUpdate |string($date-time) title: 记录最新修改时间(毫秒时间戳) | +| gmtUpdate |string($date-time) title: Record modify time(毫秒时间戳) | ### webhook通知常见问题 diff --git a/home/versioned_docs/version-v1.3.x/advanced/extend-http-default.md b/home/versioned_docs/version-v1.3.x/advanced/extend-http-default.md index 06c49d3047..2cb001b848 100644 --- a/home/versioned_docs/version-v1.3.x/advanced/extend-http-default.md +++ b/home/versioned_docs/version-v1.3.x/advanced/extend-http-default.md @@ -117,7 +117,7 @@ metrics: # The smaller Metric group scheduling priority(0-127), the higher the priority. After completion of the high priority Metric group collection,the low priority Metric group will then be scheduled. Metric groups with the same priority will be scheduled in parallel. # Metric group with a priority of 0 is an availability group which will be scheduled first. If the collection succeeds, the scheduling will continue otherwise interrupt scheduling. priority: 0 - # Specific monitoring Metrics in the Metric group + # metrics fields list fields: # Metric information include field: name type: field type(0-number: number, 1-string: string) nstance: primary key of instance or not unit: Metric unit - field: hostname diff --git a/home/versioned_docs/version-v1.3.x/advanced/extend-http-example-hertzbeat.md b/home/versioned_docs/version-v1.3.x/advanced/extend-http-example-hertzbeat.md index 620891e441..1c80402149 100644 --- a/home/versioned_docs/version-v1.3.x/advanced/extend-http-example-hertzbeat.md +++ b/home/versioned_docs/version-v1.3.x/advanced/extend-http-example-hertzbeat.md @@ -9,9 +9,9 @@ Through this tutorial, we describe step by step how to add a monitoring type bas Before reading this tutorial, we hope that you are familiar with how to customize types, metrics, protocols, etc. from [Custom Monitoring](extend-point) and [http Protocol Customization](extend-http). -### HTTP protocol parses the general response structure to obtain indicator data +### HTTP protocol parses the general response structure to obtain metric data -> In many scenarios, we need to monitor the provided HTTP API interface and obtain the index value returned by the interface. In this article, we use the http custom protocol to parse our common http interface response structure, and obtain the fields in the returned body as indicator data. +> In many scenarios, we need to monitor the provided HTTP API interface and obtain the index value returned by the interface. In this article, we use the http custom protocol to parse our common http interface response structure, and obtain the fields in the returned body as metric data. ``` @@ -56,7 +56,7 @@ As above, usually our background API interface will design such a general return } ``` -**This time we get the indicator data such as `category`, `app`, `status`, `size`, `availableSize` under the app. ** +**This time we get the metric data such as `category`, `app`, `status`, `size`, `availableSize` under the app. ** ### Add custom monitoring template `hertzbeat` @@ -152,12 +152,12 @@ metrics: # the first metrics summary # attention: Built-in monitoring metrics contains (responseTime - Response time) - name: summary - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue priority: 0 # collect metrics content fields: - # metrics content contains field-metric name, type-metric type:0-number,1-string, instance-if is metrics group, unit-metric unit('%','ms','MB') + # metrics content contains field-metric name, type-metric type:0-number,1-string, instance-if is metrics, unit-metric unit('%','ms','MB') - field: app type: 1 instance: true @@ -214,7 +214,7 @@ metrics: ![](/img/docs/advanced/extend-http-example-3.png) -> After a certain period of time (depending on the collection cycle), we can see the specific indicator data and historical charts in the monitoring details! +> After a certain period of time (depending on the collection cycle), we can see the specific metric data and historical charts in the monitoring details! ![](/img/docs/advanced/extend-http-example-4.png) diff --git a/home/versioned_docs/version-v1.3.x/advanced/extend-http-example-token.md b/home/versioned_docs/version-v1.3.x/advanced/extend-http-example-token.md index fb5e7f4594..f81a8d13e9 100644 --- a/home/versioned_docs/version-v1.3.x/advanced/extend-http-example-token.md +++ b/home/versioned_docs/version-v1.3.x/advanced/extend-http-example-token.md @@ -4,13 +4,13 @@ title: Tutorial 2 Obtain TOKEN index value based on HTTP protocol for subsequent sidebar_label: Tutorial 2 Get TOKEN for subsequent authentication --- -Through this tutorial, we will describe step by step how to modify on the basis of tutorial 1, add an metrics group, first call the authentication interface to obtain the TOKEN, and use the TOKEN as a parameter for the subsequent indicator group collection and authentication. +Through this tutorial, we will describe step by step how to modify on the basis of tutorial 1, add an metrics, first call the authentication interface to obtain the TOKEN, and use the TOKEN as a parameter for the subsequent metrics collection and authentication. -Before reading this tutorial, we hope that you are familiar with how to customize types, indicators, protocols, etc. from [Custom Monitoring](extend-point) and [http Protocol Customization](extend-http). +Before reading this tutorial, we hope that you are familiar with how to customize types, metrics, protocols, etc. from [Custom Monitoring](extend-point) and [http Protocol Customization](extend-http). ### Request process -【**Authentication information indicator group (highest priority)**】【**HTTP interface carries account password call**】->【**Response data analysis**】->【**Analysis and issuance of TOKEN-accessToken as an indicator **] -> [**Assign accessToken as a variable parameter to other collection index groups**] +【**Authentication information metrics (highest priority)**】【**HTTP interface carries account password call**】->【**Response data analysis**】->【**Analysis and issuance of TOKEN-accessToken as an metric **] -> [**Assign accessToken as a variable parameter to other collection index groups**] > Here we still use the hertzbeat monitoring example of Tutorial 1! The hertzbeat background interface not only supports the basic direct account password authentication used in Tutorial 1, but also supports token authentication. @@ -108,7 +108,7 @@ metrics: .... ``` -### Define metrics group `auth` login request to get `token` +### Define metrics `auth` login request to get `token` 1. Add an index group definition `auth` in `hertzbeat_token`, set the collection priority to the highest 0, and collect the index `token`. @@ -165,17 +165,17 @@ params: type: textarea placeholder: 'Available When POST PUT' required: false -# List of indicator groups +# List of metricss metrics: # The first monitoring index group auth - # Note: Built-in monitoring indicators have (responseTime - response time) + # Note: Built-in monitoring metrics have (responseTime - response time) - name: auth # The smaller the index group scheduling priority (0-127), the higher the priority, and the index group with low priority will not be scheduled until the collection of index groups with high priority is completed, and the index groups with the same priority will be scheduled and collected in parallel - # The indicator group with priority 0 is the availability indicator group, that is, it will be scheduled first, and other indicator groups will continue to be scheduled if the collection is successful, and the scheduling will be interrupted if the collection fails + # The metrics with priority 0 is the availability metrics, that is, it will be scheduled first, and other metricss will continue to be scheduled if the collection is successful, and the scheduling will be interrupted if the collection fails priority: 0 - # Specific monitoring indicators in the indicator group + # Specific monitoring metrics in the metrics fields: - # Indicator information includes field name type field type: 0-number, 1-string whether instance is the primary key of the instance unit: indicator unit + # metric information includes field name type field type: 0-number, 1-string whether instance is the primary key of the instance unit: metric unit - field: token type: 1 - field: refreshToken @@ -197,7 +197,7 @@ metrics: # request header content headers: content-type: ^_^contentType^_^ - # Response data analysis method: default-system rules, jsonPath-jsonPath script, website-website usability indicator monitoring + # Response data analysis method: default-system rules, jsonPath-jsonPath script, website-website usability metric monitoring parseType: jsonPath parseScript: '$.data' @@ -215,7 +215,7 @@ metrics: ![](/img/docs/advanced/extend-http-example-5.png) -** After the addition is successful, we can see the `token`, `refreshToken` indicator data we collected on the details page. ** +** After the addition is successful, we can see the `token`, `refreshToken` metric data we collected on the details page. ** ![](/img/docs/advanced/extend-http-example-6.png) @@ -223,7 +223,7 @@ metrics: -### Use `token` as a variable parameter to collect and use the following indicator groups +### Use `token` as a variable parameter to collect and use the following metricss **Add an index group definition `summary` in `app-hertzbeat_token.yml`, which is the same as `summary` in Tutorial 1, and set the collection priority to 1** @@ -295,17 +295,17 @@ params: type: textarea placeholder: 'Available When POST PUT' required: false -# List of indicator groups +# List of metricss metrics: # The first monitoring index group cpu -# Note: Built-in monitoring indicators have (responseTime - response time) +# Note: Built-in monitoring metrics have (responseTime - response time) - name: auth # The smaller the index group scheduling priority (0-127), the higher the priority, and the index group with low priority will not be scheduled until the collection of index groups with high priority is completed, and the index groups with the same priority will be scheduled and collected in parallel - # The indicator group with priority 0 is the availability indicator group, that is, it will be scheduled first, and other indicator groups will continue to be scheduled if the collection is successful, and the scheduling will be interrupted if the collection fails + # The metrics with priority 0 is the availability metrics, that is, it will be scheduled first, and other metricss will continue to be scheduled if the collection is successful, and the scheduling will be interrupted if the collection fails priority: 0 - # Specific monitoring indicators in the indicator group + # Specific monitoring metrics in the metrics fields: - # Indicator information includes field name type field type: 0-number, 1-string whether instance is the primary key of the instance unit: indicator unit + # metric information includes field name type field type: 0-number, 1-string whether instance is the primary key of the instance unit: metric unit - field: token type: 1 - field: refreshToken @@ -331,18 +331,18 @@ metrics: # Request parameter content params: ^_^params^_^: ^_^params^_^ - # Response data analysis method: default-system rules, jsonPath-jsonPath script, website-website usability indicator monitoring + # Response data analysis method: default-system rules, jsonPath-jsonPath script, website-website usability metric monitoring parseType: jsonPath parseScript: '$.data' - name: summary # The smaller the index group scheduling priority (0-127), the higher the priority, and the index group with low priority will not be scheduled until the collection of index groups with high priority is completed, and the index groups with the same priority will be scheduled and collected in parallel - # The indicator group with priority 0 is the availability indicator group, that is, it will be scheduled first, and other indicator groups will continue to be scheduled if the collection is successful, and the scheduling will be interrupted if the collection fails + # The metrics with priority 0 is the availability metrics, that is, it will be scheduled first, and other metricss will continue to be scheduled if the collection is successful, and the scheduling will be interrupted if the collection fails priority: 1 - # Specific monitoring indicators in the indicator group + # Specific monitoring metrics in the metrics fields: - # Indicator information includes field name type field type: 0-number, 1-string whether instance is the primary key of the instance unit: indicator unit + # metric information includes field name type field type: 0-number, 1-string whether instance is the primary key of the instance unit: metric unit - field: category type: 1 - field: app @@ -369,7 +369,7 @@ metrics: # Authentication methods: Basic Auth, Digest Auth, Bearer Token type: Bearer Token bearerTokenToken: ^o^token^o^ - # Response data analysis method: default-system rules, jsonPath-jsonPath script, website-website usability indicator monitoring + # Response data analysis method: default-system rules, jsonPath-jsonPath script, website-website usability metric monitoring parseType: jsonPath parseScript: '$.data.apps.*' diff --git a/home/versioned_docs/version-v1.3.x/advanced/extend-http-jsonpath.md b/home/versioned_docs/version-v1.3.x/advanced/extend-http-jsonpath.md index a2c0127270..5faa3dfe65 100644 --- a/home/versioned_docs/version-v1.3.x/advanced/extend-http-jsonpath.md +++ b/home/versioned_docs/version-v1.3.x/advanced/extend-http-jsonpath.md @@ -136,7 +136,7 @@ metrics: # The smaller Metric group scheduling priority(0-127), the higher the priority. After completion of the high priority Metric group collection,the low priority Metric group will then be scheduled. Metric groups with the same priority will be scheduled in parallel. # Metric group with a priority of 0 is an availability group which will be scheduled first. If the collection succeeds, the scheduling will continue otherwise interrupt scheduling. priority: 0 - # Specific monitoring Metrics in the Metric group + # metrics fields list fields: # Metric information include field: name type: field type(0-number: number, 1-string: string) nstance: primary key of instance or not unit: Metric unit - field: type diff --git a/home/versioned_docs/version-v1.3.x/advanced/extend-http.md b/home/versioned_docs/version-v1.3.x/advanced/extend-http.md index bf542dc593..b79fd58d6d 100644 --- a/home/versioned_docs/version-v1.3.x/advanced/extend-http.md +++ b/home/versioned_docs/version-v1.3.x/advanced/extend-http.md @@ -112,7 +112,7 @@ metrics: # The smaller Metric group scheduling priority(0-127), the higher the priority. After completion of the high priority Metric group collection,the low priority Metric group will then be scheduled. Metric groups with the same priority will be scheduled in parallel. # Metric group with a priority of 0 is an availability group which will be scheduled first. If the collection succeeds, the scheduling will continue otherwise interrupt scheduling. priority: 0 - # Specific monitoring Metrics in the Metric group + # metrics fields list fields: # Metric information include field: name type: field type(0-number: number, 1-string: string) nstance: primary key of instance or not unit: Metric unit - field: hostname diff --git a/home/versioned_docs/version-v1.3.x/advanced/extend-jdbc.md b/home/versioned_docs/version-v1.3.x/advanced/extend-jdbc.md index 2027f64a7c..c7750fd3a4 100644 --- a/home/versioned_docs/version-v1.3.x/advanced/extend-jdbc.md +++ b/home/versioned_docs/version-v1.3.x/advanced/extend-jdbc.md @@ -120,7 +120,7 @@ metrics: # The smaller Metric group scheduling priority(0-127), the higher the priority. After completion of the high priority Metric group collection,the low priority Metric group will then be scheduled. Metric groups with the same priority will be scheduled in parallel. # Metric group with a priority of 0 is an availability group which will be scheduled first. If the collection succeeds, the scheduling will continue otherwise interrupt scheduling. priority: 0 - # Specific monitoring Metrics in the Metric group + # metrics fields list fields: # Metric information include field: name type: field type(0-number: number, 1-string: string) instance: primary key of instance or not unit: Metric unit - field: version diff --git a/home/versioned_docs/version-v1.3.x/advanced/extend-jmx.md b/home/versioned_docs/version-v1.3.x/advanced/extend-jmx.md index 0d35ac7a0a..dbb3dae811 100644 --- a/home/versioned_docs/version-v1.3.x/advanced/extend-jmx.md +++ b/home/versioned_docs/version-v1.3.x/advanced/extend-jmx.md @@ -113,12 +113,12 @@ params: metrics: # metrics - basic - name: basic - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue priority: 0 # collect metrics content fields: - # field-metric name, type-metric type(0-number,1-string), unit-metric unit('%','ms','MB'), instance-if is metrics group unique identifier + # field-metric name, type-metric type(0-number,1-string), unit-metric unit('%','ms','MB'), instance-if is metrics unique identifier - field: VmName type: 1 - field: VmVendor diff --git a/home/versioned_docs/version-v1.3.x/advanced/extend-point.md b/home/versioned_docs/version-v1.3.x/advanced/extend-point.md index 3b1176015e..2d0e4a12e5 100644 --- a/home/versioned_docs/version-v1.3.x/advanced/extend-point.md +++ b/home/versioned_docs/version-v1.3.x/advanced/extend-point.md @@ -102,12 +102,12 @@ params: metrics: # metrics - summary, inner monitoring metrics (responseTime - response time, keyword - number of keywords) - name: summary - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue priority: 0 # collect metrics content fields: - # field-metric name, type-metric type(0-number,1-string), unit-metric unit('%','ms','MB'), instance-if is metrics group unique identifier + # field-metric name, type-metric type(0-number,1-string), unit-metric unit('%','ms','MB'), instance-if is metrics unique identifier - field: responseTime type: 0 unit: ms diff --git a/home/versioned_docs/version-v1.3.x/advanced/extend-snmp.md b/home/versioned_docs/version-v1.3.x/advanced/extend-snmp.md index 5be5939320..dac0dfe1b1 100644 --- a/home/versioned_docs/version-v1.3.x/advanced/extend-snmp.md +++ b/home/versioned_docs/version-v1.3.x/advanced/extend-snmp.md @@ -122,12 +122,12 @@ params: metrics: # metrics - system - name: system - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue priority: 0 # collect metrics content fields: - # field-metric name, type-metric type(0-number,1-string), unit-metric unit('%','ms','MB'), instance-if is metrics group unique identifier + # field-metric name, type-metric type(0-number,1-string), unit-metric unit('%','ms','MB'), instance-if is metrics unique identifier - field: name type: 1 - field: descr diff --git a/home/versioned_docs/version-v1.3.x/advanced/extend-ssh.md b/home/versioned_docs/version-v1.3.x/advanced/extend-ssh.md index 2bb1360276..543b08b3e3 100644 --- a/home/versioned_docs/version-v1.3.x/advanced/extend-ssh.md +++ b/home/versioned_docs/version-v1.3.x/advanced/extend-ssh.md @@ -117,7 +117,7 @@ metrics: # The smaller Metric group scheduling priority(0-127), the higher the priority. After completion of the high priority Metric group collection,the low priority Metric group will then be scheduled. Metric groups with the same priority will be scheduled in parallel. # Metric group with a priority of 0 is an availability group which will be scheduled first. If the collection succeeds, the scheduling will continue otherwise interrupt scheduling. priority: 0 - # Specific monitoring Metrics in the Metric group + # metrics fields list fields: # Metric information include field: name type: field type(0-number: number, 1-string: string) instance: primary key of instance or not unit: Metric unit - field: hostname diff --git a/home/versioned_docs/version-v1.3.x/advanced/extend-tutorial.md b/home/versioned_docs/version-v1.3.x/advanced/extend-tutorial.md index cdd889c253..cef42ed965 100644 --- a/home/versioned_docs/version-v1.3.x/advanced/extend-tutorial.md +++ b/home/versioned_docs/version-v1.3.x/advanced/extend-tutorial.md @@ -11,7 +11,7 @@ Before reading this tutorial, we hope that you are familiar with how to customiz ### HTTP protocol parses the general response structure to obtain metrics data -> In many scenarios, we need to monitor the provided HTTP API interface and obtain the index value returned by the interface. In this article, we use the http custom protocol to parse our common http interface response structure, and obtain the fields in the returned body as indicator data. +> In many scenarios, we need to monitor the provided HTTP API interface and obtain the index value returned by the interface. In this article, we use the http custom protocol to parse our common http interface response structure, and obtain the fields in the returned body as metric data. ``` @@ -152,12 +152,12 @@ metrics: # the first metrics summary # attention: Built-in monitoring metrics contains (responseTime - Response time) - name: summary - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue priority: 0 # collect metrics content fields: - # metrics content contains field-metric name, type-metric type:0-number,1-string, instance-if is metrics group, unit-metric unit('%','ms','MB') + # metrics content contains field-metric name, type-metric type:0-number,1-string, instance-if is metrics, unit-metric unit('%','ms','MB') - field: app type: 1 instance: true @@ -213,7 +213,7 @@ metrics: ![](/img/docs/advanced/extend-http-example-3.png) -> After a certain period of time (depending on the collection cycle), we can see the specific indicator data and historical charts in the monitoring details! +> After a certain period of time (depending on the collection cycle), we can see the specific metric data and historical charts in the monitoring details! ![](/img/docs/advanced/extend-http-example-4.png) diff --git a/home/versioned_docs/version-v1.3.x/help/activemq.md b/home/versioned_docs/version-v1.3.x/help/activemq.md index 1bf72231df..52e3090fde 100644 --- a/home/versioned_docs/version-v1.3.x/help/activemq.md +++ b/home/versioned_docs/version-v1.3.x/help/activemq.md @@ -66,7 +66,7 @@ ACTIVEMQ_SUNJMX_START="$ACTIVEMQ_SUNJMX_START -Dcom.sun.management.jmxremote" ### Collect Metrics -#### Metrics Group: broker +#### metrics: broker | Metric Name | Unit | Description | |-------------------------|------|-----------------------------------------------------------------------| @@ -89,7 +89,7 @@ ACTIVEMQ_SUNJMX_START="$ACTIVEMQ_SUNJMX_START -Dcom.sun.management.jmxremote" | MaxMessageSize | None | Max message size on this broker | | MinMessageSize | None | Min message size on this broker | -#### Metrics Group: topic +#### metrics: topic | Metric Name | Unit | Description | |-------------------------|------|-------------------------------------------------------------------------------------------| @@ -114,7 +114,7 @@ ACTIVEMQ_SUNJMX_START="$ACTIVEMQ_SUNJMX_START -Dcom.sun.management.jmxremote" | MinMessageSize | B | Min message size on this destination | -#### Metrics Group: memory_pool +#### metrics: memory_pool | Metric Name | Unit | Description | |-------------| ----------- |----------------| @@ -124,7 +124,7 @@ ACTIVEMQ_SUNJMX_START="$ACTIVEMQ_SUNJMX_START -Dcom.sun.management.jmxremote" | max | kb | max size | | used | kb | used size | -#### Metrics Group: class_loading +#### metrics: class_loading | Metric Name | Unit | Description | |-----------------------| ----------- | ----------- | @@ -133,7 +133,7 @@ ACTIVEMQ_SUNJMX_START="$ACTIVEMQ_SUNJMX_START -Dcom.sun.management.jmxremote" | UnloadedClassCount | | Unloaded Class Count | -#### Metrics Group: thread +#### metrics: thread | Metric Name | Unit | Description | |-------------------------| ----------- | ----------- | diff --git a/home/versioned_docs/version-v1.3.x/help/rabbitmq.md b/home/versioned_docs/version-v1.3.x/help/rabbitmq.md index fd06687369..1bcd3ea585 100644 --- a/home/versioned_docs/version-v1.3.x/help/rabbitmq.md +++ b/home/versioned_docs/version-v1.3.x/help/rabbitmq.md @@ -9,7 +9,7 @@ keywords: [open source monitoring tool, open source rabbitmq monitoring tool, mo ### Pre-monitoring Operations -> HertzBeat uses RabbitMQ Management's Rest Api to collect RabbitMQ indicator data. +> HertzBeat uses RabbitMQ Management's Rest Api to collect RabbitMQ metric data. > Therefore, you need to enable the Management plug-in in your RabbitMQ environment 1. Open the Management plugin, or use the self-opening version @@ -38,7 +38,7 @@ rabbitmq-plugins enable rabbitmq_management ### Collect Metrics -#### Metrics Group: overview +#### metrics: overview | Metric Name | Metric Unit | Metric Description | |--------------------|-------------|------------------------------------| @@ -50,7 +50,7 @@ rabbitmq-plugins enable rabbitmq_management | cluster_name | None | Cluster name | | rates_mode | None | rates mode | -#### Metrics Group: object_totals +#### metrics: object_totals | Metric Name | Metric Unit | Metric Description | |-------------|-------------|-----------------------------| @@ -60,7 +60,7 @@ rabbitmq-plugins enable rabbitmq_management | exchanges | none | total number of exchanges | | queues | none | total number of queues | -#### Metrics Group: nodes +#### metrics: nodes | Metric Name | Metric Unit | Metric Description | |--------------------|-------------|-----------------------------------------------------------| @@ -101,7 +101,7 @@ rabbitmq-plugins enable rabbitmq_management | connection_closed | None | connection closed num | -#### Metrics Group: queues +#### metrics: queues | Metric Name | Metric Unit | Metric Description | |------------------------------|-------------|--------------------------------------------------------------------------------------------------------------------------------------| diff --git a/home/versioned_docs/version-v1.3.x/start/custom-config.md b/home/versioned_docs/version-v1.3.x/start/custom-config.md index c8d616396d..91282bf505 100644 --- a/home/versioned_docs/version-v1.3.x/start/custom-config.md +++ b/home/versioned_docs/version-v1.3.x/start/custom-config.md @@ -39,9 +39,9 @@ alerter: console-url: https://console.tancloud.cn ``` -3. Use external redis instead of memory to store real-time indicator data +3. Use external redis instead of memory to store real-time metric data -> By default, the real-time data of our indicators is stored in memory, which can be configured as follows to use redis instead of memory storage. +> By default, the real-time data of our metrics is stored in memory, which can be configured as follows to use redis instead of memory storage. Note ⚠️ `memory.enabled: false, redis.enabled: true` ```yaml diff --git a/home/versioned_docs/version-v1.3.x/start/docker-deploy.md b/home/versioned_docs/version-v1.3.x/start/docker-deploy.md index 3e2fcf42e6..6f35986034 100644 --- a/home/versioned_docs/version-v1.3.x/start/docker-deploy.md +++ b/home/versioned_docs/version-v1.3.x/start/docker-deploy.md @@ -32,8 +32,8 @@ sidebar_label: Install via Docker You can modify the configuration file according to your needs. - If you need to use email to send alarms, you need to replace the email server parameters `spring.mail` in `application.yml` - **Recommended** If you need to use an external Mysql database to replace the built-in H2 database, you need to replace the `spring.datasource` parameter in `application.yml` For specific steps, see [Using Mysql to replace H2 database](mysql-change) - - **Recommended** If you need to use the time series database TDengine to store indicator data, you need to replace the `warehouse.store.td-engine` parameter in `application.yml` for specific steps, see [Using TDengine to store metrics data](tdengine-init) - - **Recommended** If you need to use the time series database IotDB to store the indicator database, you need to replace the `warehouse.storeiot-db` parameter in `application.yml` For specific steps, see [Use IotDB to store metrics data](iotdb-init) + - **Recommended** If you need to use the time series database TDengine to store metric data, you need to replace the `warehouse.store.td-engine` parameter in `application.yml` for specific steps, see [Using TDengine to store metrics data](tdengine-init) + - **Recommended** If you need to use the time series database IotDB to store the metric database, you need to replace the `warehouse.storeiot-db` parameter in `application.yml` For specific steps, see [Use IotDB to store metrics data](iotdb-init) 4. Mounted the account file(optional) HertzBeat default built-in three user accounts, respectively `admin/hertzbeat tom/hertzbeat guest/hertzbeat` diff --git a/home/versioned_docs/version-v1.3.x/start/iotdb-init.md b/home/versioned_docs/version-v1.3.x/start/iotdb-init.md index e3b9d64cde..939e2f986e 100644 --- a/home/versioned_docs/version-v1.3.x/start/iotdb-init.md +++ b/home/versioned_docs/version-v1.3.x/start/iotdb-init.md @@ -6,7 +6,7 @@ sidebar_label: Use IoTDB Store Metrics HertzBeat's historical data storage relies on the time series database IoTDB or TDengine, you can choose one of them to install and initialize, or not to install (note ⚠️ but it is strongly recommended to configure in the production environment) -Apache IoTDB is a software system that integrates the collection, storage, management and analysis of time series data of the Internet of Things. We use it to store and analyze the historical data of monitoring indicators collected. Support V0.13+ version and V1.0.+ version. +Apache IoTDB is a software system that integrates the collection, storage, management and analysis of time series data of the Internet of Things. We use it to store and analyze the historical data of monitoring metrics collected. Support V0.13+ version and V1.0.+ version. **Note⚠️ Time series database is optional, but production environment configuration is strongly recommended to provide more complete historical chart functions and high performance** **⚠️ If you do not configure a time series database, only the last hour of historical data is retained.** diff --git a/home/versioned_docs/version-v1.3.x/start/package-deploy.md b/home/versioned_docs/version-v1.3.x/start/package-deploy.md index 3f9244acff..b7a5191432 100644 --- a/home/versioned_docs/version-v1.3.x/start/package-deploy.md +++ b/home/versioned_docs/version-v1.3.x/start/package-deploy.md @@ -30,8 +30,8 @@ sidebar_label: Install via Package Modify the configuration file `hertzbeat/config/application.yml` params according to your needs. - If you need to use email to send alarms, you need to replace the email server parameters `spring.mail` in `application.yml` - **Recommended** If you need to use an external Mysql database to replace the built-in H2 database, you need to replace the `spring.datasource` parameter in `application.yml` For specific steps, see [Using Mysql to replace H2 database](mysql-change) - - **Recommended** If you need to use the time series database TDengine to store indicator data, you need to replace the `warehouse.store.td-engine` parameter in `application.yml` for specific steps, see [Using TDengine to store metrics data](tdengine-init) - - **Recommended** If you need to use the time series database IotDB to store the indicator database, you need to replace the `warehouse.storeiot-db` parameter in `application.yml` For specific steps, see [Use IotDB to store metrics data](iotdb-init) + - **Recommended** If you need to use the time series database TDengine to store metric data, you need to replace the `warehouse.store.td-engine` parameter in `application.yml` for specific steps, see [Using TDengine to store metrics data](tdengine-init) + - **Recommended** If you need to use the time series database IotDB to store the metric database, you need to replace the `warehouse.storeiot-db` parameter in `application.yml` For specific steps, see [Use IotDB to store metrics data](iotdb-init) 4. Configure the account file(optional) HertzBeat default built-in three user accounts, respectively `admin/hertzbeat tom/hertzbeat guest/hertzbeat` diff --git a/home/versioned_docs/version-v1.3.x/start/sslcert-practice.md b/home/versioned_docs/version-v1.3.x/start/sslcert-practice.md index 48ef6347f7..aefa594160 100644 --- a/home/versioned_docs/version-v1.3.x/start/sslcert-practice.md +++ b/home/versioned_docs/version-v1.3.x/start/sslcert-practice.md @@ -45,7 +45,7 @@ gitee: https://gitee.com/dromara/hertzbeat 3. View the detection index data -> In the monitoring list, you can view the monitoring status, and in the monitoring details, you can view the indicator data chart, etc. +> In the monitoring list, you can view the monitoring status, and in the monitoring details, you can view the metric data chart, etc. ![](https://p3-juejin.byteimg.com/tos-cn-i-k3u1fbpfcp/f874b45e909c4bb0acdd28b3fb034a61~tplv-k3u1fbpfcp-zoom-1.image) @@ -62,7 +62,7 @@ gitee: https://gitee.com/dromara/hertzbeat ![](https://p3-juejin.byteimg.com/tos-cn-i-k3u1fbpfcp/8d6205172d43463aa34e534477f132f1~tplv-k3u1fbpfcp-zoom-1.image) -> Configure the threshold, select the SSL certificate indicator object, configure the alarm expression-triggered when the indicator `expired` is `true`, that is, `equals(expired,"true")`, set the alarm level notification template information, etc. +> Configure the threshold, select the SSL certificate metric object, configure the alarm expression-triggered when the metric `expired` is `true`, that is, `equals(expired,"true")`, set the alarm level notification template information, etc. ![](https://p3-juejin.byteimg.com/tos-cn-i-k3u1fbpfcp/83d17b381d994f26a6240e01915b2001~tplv-k3u1fbpfcp-zoom-1.image) @@ -77,7 +77,7 @@ gitee: https://gitee.com/dromara/hertzbeat 5. Set the threshold (triggered one week before the certificate expires) -> In the same way, add a new configuration threshold and configure an alarm expression - when the indicator expires timestamp `end_timestamp`, the `now()` function is the current timestamp, if the configuration triggers an alarm one week in advance: `end_timestamp <= (now( ) + 604800000)` , where `604800000` is the 7-day total time difference in milliseconds. +> In the same way, add a new configuration threshold and configure an alarm expression - when the metric expires timestamp `end_timestamp`, the `now()` function is the current timestamp, if the configuration triggers an alarm one week in advance: `end_timestamp <= (now( ) + 604800000)` , where `604800000` is the 7-day total time difference in milliseconds. ![](https://p3-juejin.byteimg.com/tos-cn-i-k3u1fbpfcp/0d6f837f57c247e09f668f60eff4a0ff~tplv-k3u1fbpfcp-zoom-1.image) diff --git a/home/versioned_docs/version-v1.3.x/start/tdengine-init.md b/home/versioned_docs/version-v1.3.x/start/tdengine-init.md index 1a851fea3c..c190f9eae1 100644 --- a/home/versioned_docs/version-v1.3.x/start/tdengine-init.md +++ b/home/versioned_docs/version-v1.3.x/start/tdengine-init.md @@ -6,7 +6,7 @@ sidebar_label: Use TDengine Store Metrics HertzBeat's historical data storage depends on the time series database TDengine or IoTDB, choose one of them to install and initialize, or not to install (note ⚠️ but it is strongly recommended to configure in the production environment) -TDengine is an open-source IoT time-series database, which we use to store the collected historical data of monitoring indicators. Pay attention to support ⚠️ 3.x version. +TDengine is an open-source IoT time-series database, which we use to store the collected historical data of monitoring metrics. Pay attention to support ⚠️ 3.x version. **Note⚠️ Time series database is optional, but production environment configuration is strongly recommended to provide more complete historical chart functions and high performance** **⚠️ If you do not configure a time series database, only the last hour of historical data is retained.** diff --git a/manager/src/main/java/org/dromara/hertzbeat/manager/component/alerter/impl/TelegramBotAlertNotifyHandlerImpl.java b/manager/src/main/java/org/dromara/hertzbeat/manager/component/alerter/impl/TelegramBotAlertNotifyHandlerImpl.java index fc8a65a8c2..b84dad17e3 100644 --- a/manager/src/main/java/org/dromara/hertzbeat/manager/component/alerter/impl/TelegramBotAlertNotifyHandlerImpl.java +++ b/manager/src/main/java/org/dromara/hertzbeat/manager/component/alerter/impl/TelegramBotAlertNotifyHandlerImpl.java @@ -41,10 +41,8 @@ import org.springframework.web.client.RestTemplate; * Created by Musk.Chen on 2023/1/16 */ @Component -@RequiredArgsConstructor @Slf4j final class TelegramBotAlertNotifyHandlerImpl extends AbstractAlertNotifyHandlerImpl { - private final RestTemplate restTemplate; @Override public void send(NoticeReceiver receiver, NoticeTemplate noticeTemplate, Alert alert) throws AlertNoticeException { diff --git a/manager/src/main/java/org/dromara/hertzbeat/manager/component/alerter/impl/WeWorkAppAlertNotifyHandlerImpl.java b/manager/src/main/java/org/dromara/hertzbeat/manager/component/alerter/impl/WeWorkAppAlertNotifyHandlerImpl.java index c352e3294b..fb31559371 100644 --- a/manager/src/main/java/org/dromara/hertzbeat/manager/component/alerter/impl/WeWorkAppAlertNotifyHandlerImpl.java +++ b/manager/src/main/java/org/dromara/hertzbeat/manager/component/alerter/impl/WeWorkAppAlertNotifyHandlerImpl.java @@ -1,12 +1,11 @@ package org.dromara.hertzbeat.manager.component.alerter.impl; -import lombok.RequiredArgsConstructor; +import com.fasterxml.jackson.annotation.JsonProperty; +import lombok.*; import lombok.extern.slf4j.Slf4j; import org.dromara.hertzbeat.common.entity.alerter.Alert; import org.dromara.hertzbeat.common.entity.manager.NoticeReceiver; import org.dromara.hertzbeat.common.entity.manager.NoticeTemplate; -import org.dromara.hertzbeat.manager.pojo.dto.WeChatAppDTO; -import org.dromara.hertzbeat.manager.pojo.dto.WeChatAppReq; import org.dromara.hertzbeat.manager.support.exception.AlertNoticeException; import org.springframework.http.HttpEntity; import org.springframework.http.HttpHeaders; @@ -80,4 +79,73 @@ public class WeWorkAppAlertNotifyHandlerImpl extends AbstractAlertNotifyHandlerI public byte type() { return 10; } + + @Data + @AllArgsConstructor + @NoArgsConstructor + private static class WeChatAppReq { + + @JsonProperty(value = "errcode") + private Integer errCode; + + @JsonProperty(value = "errmsg") + private String errMsg; + + @JsonProperty(value = "access_token") + private String accessToken; + } + + @Data + @Builder + @AllArgsConstructor + @NoArgsConstructor + private static class WeChatAppDTO { + + /** + * markdown格式 + */ + public static final String MARKDOWN = "markdown"; + + @JsonProperty(value = "touser") + private String toUser; + + @JsonProperty(value = "toparty") + private String toParty; + + @JsonProperty(value = "totag") + private String toTag; + + @JsonProperty(value = "msgtype") + private String msgType; + + @JsonProperty(value = "agentid") + private Integer agentId; + + /** + * text message + */ + private TextDTO text; + + /** + * markdown消息 + */ + private MarkdownDTO markdown; + + @Data + private static class MarkdownDTO { + /** + * 消息内容 + */ + private String content; + } + + @Data + private static class TextDTO { + /** + * 消息内容 + */ + private String content; + } + + } } diff --git a/manager/src/main/java/org/dromara/hertzbeat/manager/component/alerter/impl/WeWorkRobotAlertNotifyHandlerImpl.java b/manager/src/main/java/org/dromara/hertzbeat/manager/component/alerter/impl/WeWorkRobotAlertNotifyHandlerImpl.java index 13c20459e3..b3aecac857 100644 --- a/manager/src/main/java/org/dromara/hertzbeat/manager/component/alerter/impl/WeWorkRobotAlertNotifyHandlerImpl.java +++ b/manager/src/main/java/org/dromara/hertzbeat/manager/component/alerter/impl/WeWorkRobotAlertNotifyHandlerImpl.java @@ -17,12 +17,11 @@ package org.dromara.hertzbeat.manager.component.alerter.impl; -import lombok.RequiredArgsConstructor; +import lombok.*; import lombok.extern.slf4j.Slf4j; import org.dromara.hertzbeat.common.entity.alerter.Alert; import org.dromara.hertzbeat.common.entity.manager.NoticeReceiver; import org.dromara.hertzbeat.common.entity.manager.NoticeTemplate; -import org.dromara.hertzbeat.manager.pojo.dto.WeWorkWebHookDto; import org.dromara.hertzbeat.manager.support.exception.AlertNoticeException; import org.springframework.http.*; import org.springframework.stereotype.Component; @@ -72,4 +71,40 @@ final class WeWorkRobotAlertNotifyHandlerImpl extends AbstractAlertNotifyHandler return 4; } + @Data + @Builder + @AllArgsConstructor + @NoArgsConstructor + private static class WeWorkWebHookDto { + + public static final String WEBHOOK_URL = "https://qyapi.weixin.qq.com/cgi-bin/webhook/send?key="; + /** + * markdown格式 + */ + private static final String MARKDOWN = "markdown"; + /** + * 文本格式 + */ + private static final String TEXT = "text"; + + /** + * 消息类型 + */ + @Builder.Default + private String msgtype = MARKDOWN; + + /** + * markdown消息 + */ + private MarkdownDTO markdown; + + @Data + private static class MarkdownDTO { + /** + * 消息内容 + */ + private String content; + } + + } } diff --git a/manager/src/main/java/org/dromara/hertzbeat/manager/component/alerter/impl/WebHookAlertNotifyHandlerImpl.java b/manager/src/main/java/org/dromara/hertzbeat/manager/component/alerter/impl/WebHookAlertNotifyHandlerImpl.java index 8d56744285..ff607c1c49 100644 --- a/manager/src/main/java/org/dromara/hertzbeat/manager/component/alerter/impl/WebHookAlertNotifyHandlerImpl.java +++ b/manager/src/main/java/org/dromara/hertzbeat/manager/component/alerter/impl/WebHookAlertNotifyHandlerImpl.java @@ -31,11 +31,8 @@ import org.springframework.web.client.RestTemplate; * */ @Component -@RequiredArgsConstructor @Slf4j final class WebHookAlertNotifyHandlerImpl extends AbstractAlertNotifyHandlerImpl { - - private final RestTemplate restTemplate; @Override public void send(NoticeReceiver receiver, NoticeTemplate noticeTemplate, Alert alert) { diff --git a/manager/src/main/java/org/dromara/hertzbeat/manager/controller/AppController.java b/manager/src/main/java/org/dromara/hertzbeat/manager/controller/AppController.java index b2869311ba..84025dc27f 100644 --- a/manager/src/main/java/org/dromara/hertzbeat/manager/controller/AppController.java +++ b/manager/src/main/java/org/dromara/hertzbeat/manager/controller/AppController.java @@ -138,7 +138,7 @@ public class AppController { } @GetMapping(path = "/hierarchy") - @Operation(summary = "Query all monitor metrics level, output in a hierarchical structure", description = "查询所有监控的类型-指标组-指标层级,以层级结构输出") + @Operation(summary = "Query all monitor metrics level, output in a hierarchical structure", description = "查询所有监控的类型指标层级,以层级结构输出") public ResponseEntity>> queryAppsHierarchy( @Parameter(description = "en: language type,zh: 语言类型", example = "zh-CN") diff --git a/manager/src/main/java/org/dromara/hertzbeat/manager/pojo/dto/Hierarchy.java b/manager/src/main/java/org/dromara/hertzbeat/manager/pojo/dto/Hierarchy.java index 53ee9e9e40..53764be266 100644 --- a/manager/src/main/java/org/dromara/hertzbeat/manager/pojo/dto/Hierarchy.java +++ b/manager/src/main/java/org/dromara/hertzbeat/manager/pojo/dto/Hierarchy.java @@ -28,54 +28,48 @@ import static io.swagger.v3.oas.annotations.media.Schema.AccessMode.READ_WRITE; /** * Hierarchical structure - * 层级关系结构 - * eg: Monitoring Type Indicator Group Indicator Information Hierarchy Relationship - * eg: 监控类型指标组指标信息层级关系 - * - * + * eg: Monitoring Type metrics Information Hierarchy Relationship * */ @AllArgsConstructor @NoArgsConstructor @Data -@Schema(description = "Monitor Hierarchy | 监控类型指标组指标信息层级关系") +@Schema(description = "Monitor Hierarchy | 监控类型指标信息层级关系") public class Hierarchy { /** * Category value */ - @Schema(description = "类别值", example = "os", accessMode = READ_WRITE) + @Schema(description = "Category Value", example = "os", accessMode = READ_WRITE) String category; /** * Attribute value */ - @Schema(description = "属性值", example = "linux", accessMode = READ_WRITE) + @Schema(description = "Attribute value", example = "linux", accessMode = READ_WRITE) String value; /** * Attribute internationalization tag */ - @Schema(description = "属性国际化标签", example = "Linux系统", accessMode = READ_WRITE) + @Schema(description = "Attribute internationalization tag", example = "Linux系统", accessMode = READ_WRITE) String label; /** * Is it a leaf node */ - @Schema(description = "是否是叶子节点", example = "true", accessMode = READ_WRITE) + @Schema(description = "Is it a leaf node", example = "true", accessMode = READ_WRITE) Boolean isLeaf = false; /** * For leaf metric * metric type 0-number: number 1-string: string - * 指标类型 0-number:数字 1-string:字符串 */ @Schema(description = "metric type 0-number: number 1-string: string") private Byte type; /** * metric unit - * 指标单位 */ @Schema(description = "metric unit") private String unit; @@ -83,6 +77,6 @@ public class Hierarchy { /** * Next level of association */ - @Schema(description = "下一关联层级", accessMode = READ_WRITE) + @Schema(description = "Next Hierarchy", accessMode = READ_WRITE) private List children; } diff --git a/manager/src/main/java/org/dromara/hertzbeat/manager/pojo/dto/MonitorDto.java b/manager/src/main/java/org/dromara/hertzbeat/manager/pojo/dto/MonitorDto.java index 42cfc532e0..36c800ca41 100644 --- a/manager/src/main/java/org/dromara/hertzbeat/manager/pojo/dto/MonitorDto.java +++ b/manager/src/main/java/org/dromara/hertzbeat/manager/pojo/dto/MonitorDto.java @@ -31,44 +31,26 @@ import static io.swagger.v3.oas.annotations.media.Schema.AccessMode.READ_WRITE; /** * Monitoring Information External Interaction Entities - * 监控信息对外交互实体 - * - * * */ @Data @Schema(description = "Monitoring information entities | 监控信息实体") public class MonitorDto { - - /** - * Monitoring entity - * 监控实体 - */ - @Schema(description = "监控实体", accessMode = READ_WRITE) + + @Schema(description = "Monitor Content", accessMode = READ_WRITE) @NotNull @Valid private Monitor monitor; - - /** - * Params 参数 - */ - @Schema(description = "监控参数", accessMode = READ_WRITE) + + @Schema(description = "Monitor Params", accessMode = READ_WRITE) @NotNull @Valid private List params; - - /** - * List of indicator groups - * 指标组列表 - */ - @Schema(description = "指标组列表", accessMode = READ_ONLY) + + @Schema(description = "Monitor Metrics", accessMode = READ_ONLY) private List metrics; - - /** - * Whether to detect - * 是否探测 - */ - @Schema(description = "是否进行探测", accessMode = READ_WRITE) + + @Schema(description = "Whether to Detect", accessMode = READ_WRITE) private boolean detected; /** diff --git a/manager/src/main/java/org/dromara/hertzbeat/manager/pojo/dto/WeChatAppDTO.java b/manager/src/main/java/org/dromara/hertzbeat/manager/pojo/dto/WeChatAppDTO.java deleted file mode 100644 index 6a3c4822b7..0000000000 --- a/manager/src/main/java/org/dromara/hertzbeat/manager/pojo/dto/WeChatAppDTO.java +++ /dev/null @@ -1,65 +0,0 @@ -package org.dromara.hertzbeat.manager.pojo.dto; - -import com.fasterxml.jackson.annotation.JsonProperty; -import lombok.AllArgsConstructor; -import lombok.Builder; -import lombok.Data; -import lombok.NoArgsConstructor; - -/** - * WeChatAppDTO - * - */ -@Data -@Builder -@AllArgsConstructor -@NoArgsConstructor -public class WeChatAppDTO { - - /** - * markdown格式 - */ - public static final String MARKDOWN = "markdown"; - - @JsonProperty(value = "touser") - private String toUser; - - @JsonProperty(value = "toparty") - private String toParty; - - @JsonProperty(value = "totag") - private String toTag; - - @JsonProperty(value = "msgtype") - private String msgType; - - @JsonProperty(value = "agentid") - private Integer agentId; - - /** - * text message - */ - private TextDTO text; - - /** - * markdown消息 - */ - private MarkdownDTO markdown; - - @Data - public static class MarkdownDTO { - /** - * 消息内容 - */ - private String content; - } - - @Data - public static class TextDTO { - /** - * 消息内容 - */ - private String content; - } - -} \ No newline at end of file diff --git a/manager/src/main/java/org/dromara/hertzbeat/manager/pojo/dto/WeChatAppReq.java b/manager/src/main/java/org/dromara/hertzbeat/manager/pojo/dto/WeChatAppReq.java deleted file mode 100644 index 2afa5613c2..0000000000 --- a/manager/src/main/java/org/dromara/hertzbeat/manager/pojo/dto/WeChatAppReq.java +++ /dev/null @@ -1,26 +0,0 @@ -package org.dromara.hertzbeat.manager.pojo.dto; - -import com.fasterxml.jackson.annotation.JsonProperty; -import lombok.AllArgsConstructor; -import lombok.Data; -import lombok.NoArgsConstructor; - -/** - * WeChatAppReq - * - * @create 2023/04/05 - */ -@Data -@AllArgsConstructor -@NoArgsConstructor -public class WeChatAppReq { - - @JsonProperty(value = "errcode") - private Integer errCode; - - @JsonProperty(value = "errmsg") - private String errMsg; - - @JsonProperty(value = "access_token") - private String accessToken; -} diff --git a/manager/src/main/java/org/dromara/hertzbeat/manager/pojo/dto/WeWorkWebHookDto.java b/manager/src/main/java/org/dromara/hertzbeat/manager/pojo/dto/WeWorkWebHookDto.java deleted file mode 100644 index 1c7492f658..0000000000 --- a/manager/src/main/java/org/dromara/hertzbeat/manager/pojo/dto/WeWorkWebHookDto.java +++ /dev/null @@ -1,66 +0,0 @@ -/* - * Licensed to the Apache Software Foundation (ASF) under one or more - * contributor license agreements. See the NOTICE file distributed with - * this work for additional information regarding copyright ownership. - * The ASF licenses this file to You under the Apache License, Version 2.0 - * (the "License"); you may not use this file except in compliance with - * the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -package org.dromara.hertzbeat.manager.pojo.dto; - -import lombok.AllArgsConstructor; -import lombok.Builder; -import lombok.Data; -import lombok.NoArgsConstructor; - -/** - * 企业微信机器人请求消息体 - * - * - * @version 1.0 - */ -@Data -@Builder -@AllArgsConstructor -@NoArgsConstructor -public class WeWorkWebHookDto { - - public static final String WEBHOOK_URL = "https://qyapi.weixin.qq.com/cgi-bin/webhook/send?key="; - /** - * markdown格式 - */ - private static final String MARKDOWN = "markdown"; - /** - * 文本格式 - */ - private static final String TEXT = "text"; - - /** - * 消息类型 - */ - @Builder.Default - private String msgtype = MARKDOWN; - - /** - * markdown消息 - */ - private MarkdownDTO markdown; - - @Data - public static class MarkdownDTO { - /** - * 消息内容 - */ - private String content; - } - -} diff --git a/manager/src/main/java/org/dromara/hertzbeat/manager/scheduler/AssignJobs.java b/manager/src/main/java/org/dromara/hertzbeat/manager/scheduler/AssignJobs.java index 773731a95e..d3d0b99334 100644 --- a/manager/src/main/java/org/dromara/hertzbeat/manager/scheduler/AssignJobs.java +++ b/manager/src/main/java/org/dromara/hertzbeat/manager/scheduler/AssignJobs.java @@ -3,8 +3,8 @@ package org.dromara.hertzbeat.manager.scheduler; import lombok.Data; import lombok.extern.slf4j.Slf4j; -import java.util.HashSet; import java.util.Set; +import java.util.concurrent.ConcurrentHashMap; /** * 分配的采集任务列表 @@ -34,10 +34,10 @@ public class AssignJobs { private Set pinnedJobs; public AssignJobs() { - jobs = new HashSet<>(16); - addingJobs = new HashSet<>(16); - removingJobs = new HashSet<>(16); - pinnedJobs = new HashSet<>(16); + jobs = ConcurrentHashMap.newKeySet(16); + addingJobs = ConcurrentHashMap.newKeySet(16); + removingJobs = ConcurrentHashMap.newKeySet(16); + pinnedJobs = ConcurrentHashMap.newKeySet(16); } public void addAssignJob(Long jobId) { diff --git a/manager/src/main/java/org/dromara/hertzbeat/manager/service/AppService.java b/manager/src/main/java/org/dromara/hertzbeat/manager/service/AppService.java index ef01cd4c5a..2471bba41b 100644 --- a/manager/src/main/java/org/dromara/hertzbeat/manager/service/AppService.java +++ b/manager/src/main/java/org/dromara/hertzbeat/manager/service/AppService.java @@ -81,11 +81,11 @@ public interface AppService { Map getI18nResources(String lang); /** - * Query all types of monitoring - indicator group - indicator level - * 查询所有监控的类型-指标组-指标层级 - * - * @param lang language 语言 - * @return level information 层级信息 + * Query all types of monitoring hierarchy + * 查询所有监控的层级资源 + * + * @param lang language + * @return hierarchy information */ List getAllAppHierarchy(String lang); diff --git a/manager/src/main/java/org/dromara/hertzbeat/manager/service/NoticeConfigService.java b/manager/src/main/java/org/dromara/hertzbeat/manager/service/NoticeConfigService.java index 6d641ad4c0..f5910cf669 100644 --- a/manager/src/main/java/org/dromara/hertzbeat/manager/service/NoticeConfigService.java +++ b/manager/src/main/java/org/dromara/hertzbeat/manager/service/NoticeConfigService.java @@ -131,8 +131,8 @@ public interface NoticeConfigService { * Query the template information according to the template ID * 根据通知模板ID查询模板信息 * - * @param id Template ID List 接收人ID - * @return Template 通知模板 + * @param id Template ID + * @return Template */ NoticeTemplate getOneTemplateById(Long id); @@ -156,17 +156,15 @@ public interface NoticeConfigService { /** * Add a notification template - * 新增一个通知接收人 * - * @param noticeTemplate template information 接收人信息 + * @param noticeTemplate template information */ void addNoticeTemplate(NoticeTemplate noticeTemplate); /** * Modify notification templates - * 修改通知接收人 * - * @param noticeTemplate template information 接收人信息 + * @param noticeTemplate template information */ void editNoticeTemplate(NoticeTemplate noticeTemplate); diff --git a/manager/src/main/java/org/dromara/hertzbeat/manager/service/impl/AppServiceImpl.java b/manager/src/main/java/org/dromara/hertzbeat/manager/service/impl/AppServiceImpl.java index 30ad43b540..a2a80ce805 100644 --- a/manager/src/main/java/org/dromara/hertzbeat/manager/service/impl/AppServiceImpl.java +++ b/manager/src/main/java/org/dromara/hertzbeat/manager/service/impl/AppServiceImpl.java @@ -363,7 +363,6 @@ public class AppServiceImpl implements AppService, CommandLineRunner { verifyDefineAppContent(app, isModify); appDefineStore.save(app.getApp(), ymlContent); appDefines.put(app.getApp().toLowerCase(), app); - // bug 当模板 app-redis.yml被修改,比如 增加指标组,删除指标,当前的job中,持有的缓存 metrics实例, // 解决 :模板修改后,同类型模板的所有监控实例 ,在任务状态中,需要重新下发任务 SpringContextHolder.getBean(MonitorService.class).updateAppCollectJob(app); } diff --git a/manager/src/main/java/org/dromara/hertzbeat/manager/service/impl/MonitorServiceImpl.java b/manager/src/main/java/org/dromara/hertzbeat/manager/service/impl/MonitorServiceImpl.java index 5183f3be1a..6ab03e3dac 100644 --- a/manager/src/main/java/org/dromara/hertzbeat/manager/service/impl/MonitorServiceImpl.java +++ b/manager/src/main/java/org/dromara/hertzbeat/manager/service/impl/MonitorServiceImpl.java @@ -140,8 +140,7 @@ public class MonitorServiceImpl implements MonitorService { List configmaps = params.stream().map(param -> new Configmap(param.getField(), param.getValue(), param.getType())).collect(Collectors.toList()); appDefine.setConfigmap(configmaps); - // To detect availability, you only need to collect the set of availability indicators with a priority of 0. - // 探测可用性只需要采集优先级为0的可用性指标集合 + // To detect availability, you only need to collect the set of availability metrics with a priority of 0. List availableMetrics = appDefine.getMetrics().stream() .filter(item -> item.getPriority() == 0).collect(Collectors.toList()); appDefine.setMetrics(availableMetrics); @@ -152,7 +151,6 @@ public class MonitorServiceImpl implements MonitorService { collectRep = collectJobScheduling.collectSyncJobData(appDefine); } // If the detection result fails, a detection exception is thrown - // 判断探测结果 失败则抛出探测异常 if (collectRep == null || collectRep.isEmpty()) { throw new MonitorDetectException("Collect Timeout No Response"); } diff --git a/manager/src/main/resources/define/app-a_example.yml b/manager/src/main/resources/define/app-a_example.yml index 4f050443d1..6847274b6c 100644 --- a/manager/src/main/resources/define/app-a_example.yml +++ b/manager/src/main/resources/define/app-a_example.yml @@ -169,20 +169,20 @@ params: # 当字段类型为key-value时, 使用valueAlias配置value的展示别名 valueAlias: Header Value # collect metrics config list -# 采集指标组配置列表 +# 采集指标配置列表 metrics: # metrics - cpu - # 监控指标组 - cpu + # 监控指标 - cpu - name: cpu # metrics name i18n label - # 指标组国际化展示名称 + # 指标国际化展示名称 i18n: zh-CN: CPU 信息 en-US: CPU Info - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue - # 指标组调度优先级(0->127)->(优先级高->低) 优先级低的指标组会等优先级高的指标组采集完成后才会被调度, 相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # 指标采集调度优先级(0->127)->(优先级高->低) 优先级低的指标会等优先级高的指标采集完成后才会被调度, 相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 0 # collect metrics content # 具体监控指标列表 diff --git a/manager/src/main/resources/define/app-activemq.yml b/manager/src/main/resources/define/app-activemq.yml index 61df04908e..22b94436a9 100644 --- a/manager/src/main/resources/define/app-activemq.yml +++ b/manager/src/main/resources/define/app-activemq.yml @@ -129,15 +129,15 @@ params: hide: true # collect metrics config list -# 采集指标组配置列表 +# 采集指标配置列表 metrics: # metrics - basic - # 监控指标组 - basic + # 监控指标 - basic - name: basic - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue - # 指标组调度优先级(0->127)->(优先级高->低) 优先级低的指标组会等优先级高的指标组采集完成后才会被调度, 相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # 指标采集调度优先级(0->127)->(优先级高->低) 优先级低的指标会等优先级高的指标采集完成后才会被调度, 相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 0 # collect metrics content # 具体监控指标列表 diff --git a/manager/src/main/resources/define/app-airflow.yml b/manager/src/main/resources/define/app-airflow.yml index 891cae704f..7f5260de09 100644 --- a/manager/src/main/resources/define/app-airflow.yml +++ b/manager/src/main/resources/define/app-airflow.yml @@ -88,7 +88,7 @@ params: required: false # collect metrics config list -# 采集指标组配置列表 +# 采集指标配置列表 metrics: - name: airflow_health priority: 0 diff --git a/manager/src/main/resources/define/app-almalinux.yml b/manager/src/main/resources/define/app-almalinux.yml index c4742d09cd..5e9bb50e33 100644 --- a/manager/src/main/resources/define/app-almalinux.yml +++ b/manager/src/main/resources/define/app-almalinux.yml @@ -155,19 +155,18 @@ params: # 是否隐藏字段 true or false hide: true # collect metrics config list -# 采集指标组配置列表 +# 采集指标配置列表 metrics: # metrics - basic, inner monitoring metrics (responseTime - response time) - # 监控指标组 - basic, 内置监控指标有 (responseTime - 响应时间) + # 监控指标 - basic, 内置监控指标有 (responseTime - 响应时间) - name: basic i18n: zh-CN: 系统基本信息 en-US: Basic Info - # 指标组调度优先级(0-127)越小优先级越高,优先级低的指标组会等优先级高的指标组采集完成后才会被调度,相同优先级的指标组会并行调度采集 - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue - # 指标组调度优先级(0->127)->(优先级高->低) 优先级低的指标组会等优先级高的指标组采集完成后才会被调度, 相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # 指标采集调度优先级(0->127)->(优先级高->低) 优先级低的指标会等优先级高的指标采集完成后才会被调度, 相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 0 # collect metrics content # 具体监控指标列表 diff --git a/manager/src/main/resources/define/app-api.yml b/manager/src/main/resources/define/app-api.yml index 48fd6ec0af..7d81648c21 100644 --- a/manager/src/main/resources/define/app-api.yml +++ b/manager/src/main/resources/define/app-api.yml @@ -326,18 +326,18 @@ params: # 是否隐藏字段 true or false hide: true # collect metrics config list -# 采集指标组配置列表 +# 采集指标配置列表 metrics: # metrics - summary - # 监控指标组 - summary + # 监控指标 - summary - name: summary i18n: zh-CN: 概要 en-US: Summary - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue - # 指标组调度优先级(0->127)->(优先级高->低) 优先级低的指标组会等优先级高的指标组采集完成后才会被调度, 相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # 指标采集调度优先级(0->127)->(优先级高->低) 优先级低的指标会等优先级高的指标采集完成后才会被调度, 相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 0 # collect metrics content # 具体监控指标列表 diff --git a/manager/src/main/resources/define/app-centos.yml b/manager/src/main/resources/define/app-centos.yml index 33c9804bea..eec8e45a20 100644 --- a/manager/src/main/resources/define/app-centos.yml +++ b/manager/src/main/resources/define/app-centos.yml @@ -155,16 +155,15 @@ params: # 是否隐藏字段 true or false hide: true # collect metrics config list -# 采集指标组配置列表 +# 采集指标配置列表 metrics: # metrics - basic, inner monitoring metrics (responseTime - response time) - # 监控指标组 - basic, 内置监控指标有 (responseTime - 响应时间) + # 监控指标 - basic, 内置监控指标有 (responseTime - 响应时间) - name: basic - # 指标组调度优先级(0-127)越小优先级越高,优先级低的指标组会等优先级高的指标组采集完成后才会被调度,相同优先级的指标组会并行调度采集 - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue - # 指标组调度优先级(0->127)->(优先级高->低) 优先级低的指标组会等优先级高的指标组采集完成后才会被调度, 相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # 指标采集调度优先级(0->127)->(优先级高->低) 优先级低的指标会等优先级高的指标采集完成后才会被调度, 相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 0 # collect metrics content # 具体监控指标列表 diff --git a/manager/src/main/resources/define/app-cisco_switch.yml b/manager/src/main/resources/define/app-cisco_switch.yml index f2064c6028..d2001c4c50 100644 --- a/manager/src/main/resources/define/app-cisco_switch.yml +++ b/manager/src/main/resources/define/app-cisco_switch.yml @@ -135,15 +135,15 @@ params: # 默认值 defaultValue: 6000 # collect metrics config list -# 采集指标组配置列表 +# 采集指标配置列表 metrics: # metrics - system - # 监控指标组 - system + # 监控指标 - system - name: system - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue - # 指标组调度优先级(0->127)->(优先级高->低) 优先级低的指标组会等优先级高的指标组采集完成后才会被调度, 相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # 指标采集调度优先级(0->127)->(优先级高->低) 优先级低的指标会等优先级高的指标采集完成后才会被调度, 相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 0 # collect metrics content # 具体监控指标列表 diff --git a/manager/src/main/resources/define/app-clickhouse.yml b/manager/src/main/resources/define/app-clickhouse.yml index 806bd1dbbe..a24f0bb07e 100644 --- a/manager/src/main/resources/define/app-clickhouse.yml +++ b/manager/src/main/resources/define/app-clickhouse.yml @@ -136,15 +136,15 @@ params: # 是否是必输项 true-必填 false-可选 required: false # collect metrics config list -# 采集指标组配置列表 +# 采集指标配置列表 metrics: # metrics - ping_available - # 监控指标组 - ping_available + # 监控指标 - ping_available - name: ping_available - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue - # 指标组调度优先级(0->127)->(优先级高->低) 优先级低的指标组会等优先级高的指标组采集完成后才会被调度, 相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # 指标采集调度优先级(0->127)->(优先级高->低) 优先级低的指标会等优先级高的指标采集完成后才会被调度, 相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 0 # collect metrics content # 具体监控指标列表 diff --git a/manager/src/main/resources/define/app-coreos.yml b/manager/src/main/resources/define/app-coreos.yml index 9b4618b929..9ca8001c4c 100644 --- a/manager/src/main/resources/define/app-coreos.yml +++ b/manager/src/main/resources/define/app-coreos.yml @@ -155,19 +155,18 @@ params: # 是否隐藏字段 true or false hide: true # collect metrics config list -# 采集指标组配置列表 +# 采集指标配置列表 metrics: # metrics - basic, inner monitoring metrics (responseTime - response time) - # 监控指标组 - basic, 内置监控指标有 (responseTime - 响应时间) + # 监控指标 - basic, 内置监控指标有 (responseTime - 响应时间) - name: basic i18n: zh-CN: 系统基本信息 en-US: Basic Info - # 指标组调度优先级(0-127)越小优先级越高,优先级低的指标组会等优先级高的指标组采集完成后才会被调度,相同优先级的指标组会并行调度采集 - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue - # 指标组调度优先级(0->127)->(优先级高->低) 优先级低的指标组会等优先级高的指标组采集完成后才会被调度, 相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # 指标采集调度优先级(0->127)->(优先级高->低) 优先级低的指标会等优先级高的指标采集完成后才会被调度, 相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 0 # collect metrics content # 具体监控指标列表 diff --git a/manager/src/main/resources/define/app-debian.yml b/manager/src/main/resources/define/app-debian.yml index a031ec9838..66961f93db 100644 --- a/manager/src/main/resources/define/app-debian.yml +++ b/manager/src/main/resources/define/app-debian.yml @@ -155,19 +155,18 @@ params: # 是否隐藏字段 true or false hide: true # collect metrics config list -# 采集指标组配置列表 +# 采集指标配置列表 metrics: # metrics - basic, inner monitoring metrics (responseTime - response time) - # 监控指标组 - basic, 内置监控指标有 (responseTime - 响应时间) + # 监控指标 - basic, 内置监控指标有 (responseTime - 响应时间) - name: basic i18n: zh-CN: 系统基本信息 en-US: Basic Info - # 指标组调度优先级(0-127)越小优先级越高,优先级低的指标组会等优先级高的指标组采集完成后才会被调度,相同优先级的指标组会并行调度采集 - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue - # 指标组调度优先级(0->127)->(优先级高->低) 优先级低的指标组会等优先级高的指标组采集完成后才会被调度, 相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # 指标采集调度优先级(0->127)->(优先级高->低) 优先级低的指标会等优先级高的指标采集完成后才会被调度, 相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 0 # collect metrics content # 具体监控指标列表 diff --git a/manager/src/main/resources/define/app-dm.yml b/manager/src/main/resources/define/app-dm.yml index 20b1ade8f3..b5a0c9ce64 100644 --- a/manager/src/main/resources/define/app-dm.yml +++ b/manager/src/main/resources/define/app-dm.yml @@ -129,15 +129,15 @@ params: # default value defaultValue: 3000 # collect metrics config list -# 采集指标组配置列表 +# 采集指标配置列表 metrics: # metrics - basic - # 监控指标组 - basic + # 监控指标 - basic - name: basic - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue - # 指标组调度优先级(0->127)->(优先级高->低) 优先级低的指标组会等优先级高的指标组采集完成后才会被调度, 相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # 指标采集调度优先级(0->127)->(优先级高->低) 优先级低的指标会等优先级高的指标采集完成后才会被调度, 相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 0 # collect metrics content # 具体监控指标列表 diff --git a/manager/src/main/resources/define/app-docker.yml b/manager/src/main/resources/define/app-docker.yml index a2d6903800..2da20f4a51 100644 --- a/manager/src/main/resources/define/app-docker.yml +++ b/manager/src/main/resources/define/app-docker.yml @@ -70,13 +70,13 @@ params: required: false metrics: - name: system - # The smaller the index group scheduling priority (0-127), the higher the priority. The index group with low priority will not be scheduled until the collection of index groups with high priority is completed. The index groups with the same priority will be scheduled and collected in parallel. - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue - # 指标组调度优先级(0-127)越小优先级越高,优先级低的指标组会等优先级高的指标组采集完成后才会被调度,相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # 指标调度优先级(0-127)越小优先级越高,优先级低的指标会等优先级高的指标采集完成后才会被调度,相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 0 - # specific monitoring metrics in the metric group - # 指标组中的具体监控指标 + # metrics fields list + # 具体监控指标列表 fields: # metric information includes field name type field type: 0-number, 1-string whether instance is the primary key of the instance unit: metric unit # 指标信息 包括 field名称 type字段类型:0-number数字,1-string字符串 label-是否是指标标签字段 unit:指标单位 @@ -159,13 +159,13 @@ metrics: parseType: default - name: containers - # The smaller the priority value (0-127), the higher the priority of the metrics group. Lower-priority metrics groups will be scheduled after higher-priority metrics groups have been collected. Metrics groups with the same priority will be scheduled to collect data in parallel. - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue - # 指标组调度优先级(0-127)越小优先级越高,优先级低的指标组会等优先级高的指标组采集完成后才会被调度,相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # The smaller the priority value (0-127), the higher the priority of the metrics. Lower-priority metricss will be scheduled after higher-priority metricss have been collected. metricss with the same priority will be scheduled to collect data in parallel. + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # 指标调度优先级(0-127)越小优先级越高,优先级低的指标会等优先级高的指标采集完成后才会被调度,相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 1 - # specific monitoring metrics in the metric group - # 指标组中的具体监控指标 + # metrics fields list + # 具体监控指标列表 fields: # metric information includes field name type field type: 0-number, 1-string whether instance is the primary key of the instance unit: metric unit # 指标信息 包括 field名称 type字段类型:0-number数字,1-string字符串 label-是否是指标标签字段 unit:指标单位 diff --git a/manager/src/main/resources/define/app-dynamic_tp.yml b/manager/src/main/resources/define/app-dynamic_tp.yml index 0bc693ed7c..473bb46c11 100644 --- a/manager/src/main/resources/define/app-dynamic_tp.yml +++ b/manager/src/main/resources/define/app-dynamic_tp.yml @@ -105,15 +105,15 @@ params: # hide-是否隐藏此参数将其放入高级设置中 hide: true # collect metrics config list -# 采集指标组配置列表 +# 采集指标配置列表 metrics: # metrics - thread_pool - # 监控指标组 - thread_pool + # 监控指标 - thread_pool - name: thread_pool - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue - # 指标组调度优先级(0->127)->(优先级高->低) 优先级低的指标组会等优先级高的指标组采集完成后才会被调度, 相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # 指标采集调度优先级(0->127)->(优先级高->低) 优先级低的指标会等优先级高的指标采集完成后才会被调度, 相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 0 # collect metrics content # 具体监控指标列表 diff --git a/manager/src/main/resources/define/app-elasticsearch.yml b/manager/src/main/resources/define/app-elasticsearch.yml index fedee80bdb..6694b9a3d7 100644 --- a/manager/src/main/resources/define/app-elasticsearch.yml +++ b/manager/src/main/resources/define/app-elasticsearch.yml @@ -157,15 +157,15 @@ params: # required-是否是必输项 true-必填 false-可选 required: false # collect metrics config list -# 采集指标组配置列表 +# 采集指标配置列表 metrics: # metrics - cpu - # 监控指标组 - cpu + # 监控指标 - cpu - name: health - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue - # 指标组调度优先级(0->127)->(优先级高->低) 优先级低的指标组会等优先级高的指标组采集完成后才会被调度, 相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # 指标采集调度优先级(0->127)->(优先级高->低) 优先级低的指标会等优先级高的指标采集完成后才会被调度, 相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 0 # collect metrics content # 具体监控指标列表 diff --git a/manager/src/main/resources/define/app-emqx.yml b/manager/src/main/resources/define/app-emqx.yml index 85c7b15e61..2024e60ac7 100644 --- a/manager/src/main/resources/define/app-emqx.yml +++ b/manager/src/main/resources/define/app-emqx.yml @@ -104,23 +104,23 @@ params: type: text required: true metrics: - # the first metrics summary - # attention: Built-in monitoring metrics contains (responseTime - Response time) - # 第一个监控指标组 summary - # 注意:内置监控指标有 (responseTime - 响应时间) + # metrics - summary + # 监控指标 - summary - name: summary + # metrics name i18n label + # 指标国际化展示名称 i18n: zh-CN: 概要 en-US: Summary - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue - # 指标组调度优先级(0-127)越小优先级越高,优先级低的指标组会等优先级高的指标组采集完成后才会被调度,相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # 指标调度优先级(0-127)越小优先级越高,优先级低的指标会等优先级高的指标采集完成后才会被调度,相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 0 # collect metrics content - # 指标组中的具体监控指标 + # 具体监控指标列表 fields: - # metrics content contains field-metric name, type-metric type:0-number,1-string, instance-if is metrics group, unit-metric unit('%','ms','MB') + # metrics content contains field-metric name, type-metric type:0-number,1-string, instance-if is metrics, unit-metric unit('%','ms','MB') # 指标信息 包括 field名称 type字段类型:0-number数字,1-string字符串 label-是否是指标标签字段 unit:指标单位 - field: version type: 1 @@ -193,15 +193,15 @@ metrics: parseScript: '$' - name: metrics - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue - # 指标组调度优先级(0-127)越小优先级越高,优先级低的指标组会等优先级高的指标组采集完成后才会被调度,相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # 指标调度优先级(0-127)越小优先级越高,优先级低的指标会等优先级高的指标采集完成后才会被调度,相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 1 # collect metrics content - # 指标组中的具体监控指标 + # 具体监控指标列表 fields: - # metrics content contains field-metric name, type-metric type:0-number,1-string, instance-if is metrics group, unit-metric unit('%','ms','MB') + # metrics content contains field-metric name, type-metric type:0-number,1-string, instance-if is metrics, unit-metric unit('%','ms','MB') # 指标信息 包括 field名称 type字段类型:0-number数字,1-string字符串 label-是否是指标标签字段 unit:指标单位 - field: client_connected type: 0 @@ -300,7 +300,7 @@ metrics: - name: stats priority: 2 fields: - # metrics content contains field-metric name, type-metric type:0-number,1-string, instance-if is metrics group, unit-metric unit('%','ms','MB') + # metrics content contains field-metric name, type-metric type:0-number,1-string, instance-if is metrics, unit-metric unit('%','ms','MB') # 指标信息 包括 field名称 type字段类型:0-number数字,1-string字符串 label-是否是指标标签字段 unit:指标单位 - field: channels_count type: 0 diff --git a/manager/src/main/resources/define/app-euleros.yml b/manager/src/main/resources/define/app-euleros.yml index 5c14f61e49..09670ee1f0 100644 --- a/manager/src/main/resources/define/app-euleros.yml +++ b/manager/src/main/resources/define/app-euleros.yml @@ -155,19 +155,18 @@ params: # 是否隐藏字段 true or false hide: true # collect metrics config list -# 采集指标组配置列表 +# 采集指标配置列表 metrics: # metrics - basic, inner monitoring metrics (responseTime - response time) - # 监控指标组 - basic, 内置监控指标有 (responseTime - 响应时间) + # 监控指标 - basic, 内置监控指标有 (responseTime - 响应时间) - name: basic i18n: zh-CN: 系统基本信息 en-US: Basic Info - # 指标组调度优先级(0-127)越小优先级越高,优先级低的指标组会等优先级高的指标组采集完成后才会被调度,相同优先级的指标组会并行调度采集 - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue - # 指标组调度优先级(0->127)->(优先级高->低) 优先级低的指标组会等优先级高的指标组采集完成后才会被调度, 相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # 指标采集调度优先级(0->127)->(优先级高->低) 优先级低的指标会等优先级高的指标采集完成后才会被调度, 相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 0 # collect metrics content # 具体监控指标列表 diff --git a/manager/src/main/resources/define/app-flink.yml b/manager/src/main/resources/define/app-flink.yml index c912be148f..96c9aec3e1 100644 --- a/manager/src/main/resources/define/app-flink.yml +++ b/manager/src/main/resources/define/app-flink.yml @@ -117,15 +117,15 @@ params: required: false hide: true # collect metrics config list -# 采集指标组配置列表 +# 采集指标配置列表 metrics: # metrics - basic - # 监控指标组 - basic + # 监控指标 - basic - name: basic - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue - # 指标组调度优先级(0->127)->(优先级高->低) 优先级低的指标组会等优先级高的指标组采集完成后才会被调度, 相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # 指标采集调度优先级(0->127)->(优先级高->低) 优先级低的指标会等优先级高的指标采集完成后才会被调度, 相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 0 # collect metrics content # 具体监控指标列表 diff --git a/manager/src/main/resources/define/app-freebsd.yml b/manager/src/main/resources/define/app-freebsd.yml index 0a54506b08..e74186131d 100644 --- a/manager/src/main/resources/define/app-freebsd.yml +++ b/manager/src/main/resources/define/app-freebsd.yml @@ -155,19 +155,18 @@ params: # 是否隐藏字段 true or false hide: true # collect metrics config list -# 采集指标组配置列表 +# 采集指标配置列表 metrics: # metrics - basic, inner monitoring metrics (responseTime - response time) - # 监控指标组 - basic, 内置监控指标有 (responseTime - 响应时间) + # 监控指标 - basic, 内置监控指标有 (responseTime - 响应时间) - name: basic i18n: zh-CN: 系统基本信息 en-US: Basic Info - # 指标组调度优先级(0-127)越小优先级越高,优先级低的指标组会等优先级高的指标组采集完成后才会被调度,相同优先级的指标组会并行调度采集 - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue - # 指标组调度优先级(0->127)->(优先级高->低) 优先级低的指标组会等优先级高的指标组采集完成后才会被调度, 相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # 指标采集调度优先级(0->127)->(优先级高->低) 优先级低的指标会等优先级高的指标采集完成后才会被调度, 相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 0 # collect metrics content # 具体监控指标列表 diff --git a/manager/src/main/resources/define/app-ftp.yml b/manager/src/main/resources/define/app-ftp.yml index db82f72372..b7860a7d36 100644 --- a/manager/src/main/resources/define/app-ftp.yml +++ b/manager/src/main/resources/define/app-ftp.yml @@ -105,15 +105,15 @@ params: required: true defaultValue: 1000 # collect metrics config list -# 采集指标组配置列表 +# 采集指标配置列表 metrics: # metrics - basic - # 监控指标组 - basic + # 监控指标 - basic - name: basic - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue - # 指标组调度优先级(0->127)->(优先级高->低) 优先级低的指标组会等优先级高的指标组采集完成后才会被调度, 相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # 指标采集调度优先级(0->127)->(优先级高->低) 优先级低的指标会等优先级高的指标采集完成后才会被调度, 相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 0 # collect metrics content # 具体监控指标列表 diff --git a/manager/src/main/resources/define/app-fullsite.yml b/manager/src/main/resources/define/app-fullsite.yml index 15c4ad259b..0367998976 100644 --- a/manager/src/main/resources/define/app-fullsite.yml +++ b/manager/src/main/resources/define/app-fullsite.yml @@ -86,15 +86,15 @@ params: required: true # collect metrics config list -# 采集指标组配置列表 +# 采集指标配置列表 metrics: # metrics - summary - # 监控指标组 - summary + # 监控指标 - summary - name: summary - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue - # 指标组调度优先级(0->127)->(优先级高->低) 优先级低的指标组会等优先级高的指标组采集完成后才会被调度, 相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # 指标采集调度优先级(0->127)->(优先级高->低) 优先级低的指标会等优先级高的指标采集完成后才会被调度, 相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 0 # collect metrics content # 具体监控指标列表 diff --git a/manager/src/main/resources/define/app-h3c_switch.yml b/manager/src/main/resources/define/app-h3c_switch.yml index 3532cd04de..637a2ea690 100644 --- a/manager/src/main/resources/define/app-h3c_switch.yml +++ b/manager/src/main/resources/define/app-h3c_switch.yml @@ -135,15 +135,15 @@ params: # 默认值 defaultValue: 6000 # collect metrics config list -# 采集指标组配置列表 +# 采集指标配置列表 metrics: # metrics - system - # 监控指标组 - system + # 监控指标 - system - name: system - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue - # 指标组调度优先级(0->127)->(优先级高->低) 优先级低的指标组会等优先级高的指标组采集完成后才会被调度, 相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # 指标采集调度优先级(0->127)->(优先级高->低) 优先级低的指标会等优先级高的指标采集完成后才会被调度, 相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 0 # collect metrics content # 具体监控指标列表 diff --git a/manager/src/main/resources/define/app-hadoop.yml b/manager/src/main/resources/define/app-hadoop.yml index a2e011ab16..0a1a7ef734 100644 --- a/manager/src/main/resources/define/app-hadoop.yml +++ b/manager/src/main/resources/define/app-hadoop.yml @@ -128,15 +128,15 @@ params: # 是否隐藏字段 true or false hide: true # collect metrics config list -# 采集指标组配置列表 +# 采集指标配置列表 metrics: # metrics - basic - # 监控指标组 - basic + # 监控指标 - basic - name: basic - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue - # 指标组调度优先级(0->127)->(优先级高->低) 优先级低的指标组会等优先级高的指标组采集完成后才会被调度, 相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # 指标采集调度优先级(0->127)->(优先级高->低) 优先级低的指标会等优先级高的指标采集完成后才会被调度, 相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 0 # collect metrics content # 具体监控指标列表 @@ -282,7 +282,7 @@ metrics: - name: thread priority: 7 # collect metrics content - # 指标组中的具体监控指标 + # 具体监控指标列表 fields: # field-metric name, type-metric type(0-number,1-string), unit-metric unit('%','ms','MB'), label-whether it is a metrics label field # field-指标名称, type-指标类型(0-number数字,1-string字符串), unit-指标单位('%','ms','MB'), label-是否是指标标签字段 diff --git a/manager/src/main/resources/define/app-hertzbeat.yml b/manager/src/main/resources/define/app-hertzbeat.yml index e60f8b6d7a..8e7de12249 100644 --- a/manager/src/main/resources/define/app-hertzbeat.yml +++ b/manager/src/main/resources/define/app-hertzbeat.yml @@ -89,18 +89,16 @@ params: metrics: # the first metrics summary # attention: Built-in monitoring metrics contains (responseTime - Response time) - # 第一个监控指标组 summary - # 注意:内置监控指标有 (responseTime - 响应时间) - name: summary - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue - # 指标组调度优先级(0-127)越小优先级越高,优先级低的指标组会等优先级高的指标组采集完成后才会被调度,相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # 指标调度优先级(0-127)越小优先级越高,优先级低的指标会等优先级高的指标采集完成后才会被调度,相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 0 # collect metrics content - # 指标组中的具体监控指标 + # 具体监控指标列表 fields: - # metrics content contains field-metric name, type-metric type:0-number,1-string, instance-if is metrics group, unit-metric unit('%','ms','MB') + # metrics content contains field-metric name, type-metric type:0-number,1-string, instance-if is metrics, unit-metric unit('%','ms','MB') # 指标信息 包括 field名称 type字段类型:0-number数字,1-string字符串 label-是否是指标标签字段 unit:指标单位 - field: app type: 1 diff --git a/manager/src/main/resources/define/app-hertzbeat_token.yml b/manager/src/main/resources/define/app-hertzbeat_token.yml index 1564ec7b80..4080954110 100644 --- a/manager/src/main/resources/define/app-hertzbeat_token.yml +++ b/manager/src/main/resources/define/app-hertzbeat_token.yml @@ -87,15 +87,15 @@ params: placeholder: 'Available When POST PUT' required: false # collect metrics config list -# 采集指标组配置列表 +# 采集指标配置列表 metrics: # metrics - auth - # 监控指标组 - auth + # 监控指标 - auth - name: auth - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue - # 指标组调度优先级(0->127)->(优先级高->低) 优先级低的指标组会等优先级高的指标组采集完成后才会被调度, 相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # 指标采集调度优先级(0->127)->(优先级高->低) 优先级低的指标会等优先级高的指标采集完成后才会被调度, 相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 0 # collect metrics content # 具体监控指标列表 diff --git a/manager/src/main/resources/define/app-hpe_switch.yml b/manager/src/main/resources/define/app-hpe_switch.yml index 5b2f4c9fd4..daa24ad38d 100644 --- a/manager/src/main/resources/define/app-hpe_switch.yml +++ b/manager/src/main/resources/define/app-hpe_switch.yml @@ -135,15 +135,15 @@ params: # 默认值 defaultValue: 6000 # collect metrics config list -# 采集指标组配置列表 +# 采集指标配置列表 metrics: # metrics - system - # 监控指标组 - system + # 监控指标 - system - name: system - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue - # 指标组调度优先级(0->127)->(优先级高->低) 优先级低的指标组会等优先级高的指标组采集完成后才会被调度, 相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # 指标采集调度优先级(0->127)->(优先级高->低) 优先级低的指标会等优先级高的指标采集完成后才会被调度, 相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 0 # collect metrics content # 具体监控指标列表 diff --git a/manager/src/main/resources/define/app-huawei_switch.yml b/manager/src/main/resources/define/app-huawei_switch.yml index 9b8196499d..b8c3e9da1a 100644 --- a/manager/src/main/resources/define/app-huawei_switch.yml +++ b/manager/src/main/resources/define/app-huawei_switch.yml @@ -135,15 +135,15 @@ params: # 默认值 defaultValue: 6000 # collect metrics config list -# 采集指标组配置列表 +# 采集指标配置列表 metrics: # metrics - system - # 监控指标组 - system + # 监控指标 - system - name: system - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue - # 指标组调度优先级(0->127)->(优先级高->低) 优先级低的指标组会等优先级高的指标组采集完成后才会被调度, 相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # 指标采集调度优先级(0->127)->(优先级高->低) 优先级低的指标会等优先级高的指标采集完成后才会被调度, 相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 0 # collect metrics content # 具体监控指标列表 diff --git a/manager/src/main/resources/define/app-influxdb_promql.yml b/manager/src/main/resources/define/app-influxdb_promql.yml index 30a0620042..ccafd93048 100644 --- a/manager/src/main/resources/define/app-influxdb_promql.yml +++ b/manager/src/main/resources/define/app-influxdb_promql.yml @@ -121,18 +121,16 @@ params: hide: true metrics: - # The first monitoring metric group CPU. + # The first monitoring metrics basic_influxdb_memstats_alloc. # Note: Built-in monitoring metrics include (responseTime - response time) - # 第一个监控指标组 cpu - # 注意:内置监控指标有 (responseTime - 响应时间) - name: basic_influxdb_memstats_alloc - # metrics group scheduling priority(0->127), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue - # 指标组调度优先级(0-127)越小优先级越高,优先级低的指标组会等优先级高的指标组采集完成后才会被调度,相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # metrics scheduling priority(0->127), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # 指标调度优先级(0-127)越小优先级越高,优先级低的指标会等优先级高的指标采集完成后才会被调度,相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 0 - # Specific monitoring metrics in the metric group. - # 指标组中的具体监控指标 + # metrics fields list. + # 具体监控指标列表 fields: # Metric information includes the following: Field name, Type: 0-number, 1-string, instance: indicates whether the metric is the primary key, unit: the unit of the metric # 指标信息 包括 field名称 type字段类型:0-number数字,1-string字符串 label-是否是指标标签字段 unit:指标单位 @@ -190,13 +188,13 @@ metrics: parseType: PromQL - name: influxdb_database_numMeasurements - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue - # 指标组调度优先级(0-127)越小优先级越高,优先级低的指标组会等优先级高的指标组采集完成后才会被调度,相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # 指标调度优先级(0-127)越小优先级越高,优先级低的指标会等优先级高的指标采集完成后才会被调度,相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 1 - # Specific monitoring metrics in the metric group. - # 指标组中的具体监控指标 + # metrics fields list. + # 具体监控指标列表 fields: # Metric information includes the following: Field name, Type: 0-number, 1-string, instance: indicates whether the metric is the primary key, unit: the unit of the metric # 指标信息 包括 field名称 type字段类型:0-number数字,1-string字符串 label-是否是指标标签字段 unit:指标单位 @@ -258,13 +256,13 @@ metrics: parseType: PromQL - name: influxdb_query_rate_seconds # Query rate per second 每秒查询率 - # metrics group scheduling priority(0->127), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue - # 指标组调度优先级(0-127)越小优先级越高,优先级低的指标组会等优先级高的指标组采集完成后才会被调度,相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # metrics scheduling priority(0->127), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # 指标调度优先级(0-127)越小优先级越高,优先级低的指标会等优先级高的指标采集完成后才会被调度,相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 1 - # Specific monitoring metrics in the metric group. - # 指标组中的具体监控指标 + # metrics fields list. + # 具体监控指标列表 fields: # Metric information includes the following: Field name, Type: 0-number, 1-string, instance: indicates whether the metric is the primary key, unit: the unit of the metric # 指标信息 包括 field名称 type字段类型:0-number数字,1-string字符串 label-是否是指标标签字段 unit:指标单位 @@ -322,13 +320,13 @@ metrics: parseType: PromQL - name: influxdb_queryExecutor_queriesFinished_10s # Query rate per second 每秒查询率 - # metrics group scheduling priority(0->127), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue - # 指标组调度优先级(0-127)越小优先级越高,优先级低的指标组会等优先级高的指标组采集完成后才会被调度,相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # metrics scheduling priority(0->127), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # 指标调度优先级(0-127)越小优先级越高,优先级低的指标会等优先级高的指标采集完成后才会被调度,相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 1 - # Specific monitoring metrics in the metric group. - # 指标组中的具体监控指标 + # metrics fields list. + # 具体监控指标列表 fields: # Metric information includes the following: Field name, Type: 0-number, 1-string, instance: indicates whether the metric is the primary key, unit: the unit of the metric # 指标信息 包括 field名称 type字段类型:0-number数字,1-string字符串 label-是否是指标标签字段 unit:指标单位 diff --git a/manager/src/main/resources/define/app-iotdb.yml b/manager/src/main/resources/define/app-iotdb.yml index f907a45efd..a28af72f07 100644 --- a/manager/src/main/resources/define/app-iotdb.yml +++ b/manager/src/main/resources/define/app-iotdb.yml @@ -75,15 +75,15 @@ params: defaultValue: 6000 # collect metrics config list -# 采集指标组配置列表 +# 采集指标配置列表 metrics: # metrics - cluster_node_status - # 监控指标组 - cluster_node_status + # 监控指标 - cluster_node_status - name: cluster_node_status - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue - # 指标组调度优先级(0->127)->(优先级高->低) 优先级低的指标组会等优先级高的指标组采集完成后才会被调度, 相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # 指标采集调度优先级(0->127)->(优先级高->低) 优先级低的指标会等优先级高的指标采集完成后才会被调度, 相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 0 # collect metrics content # 具体监控指标列表 diff --git a/manager/src/main/resources/define/app-jetty.yml b/manager/src/main/resources/define/app-jetty.yml index 6645c30621..26c99142f7 100644 --- a/manager/src/main/resources/define/app-jetty.yml +++ b/manager/src/main/resources/define/app-jetty.yml @@ -128,18 +128,18 @@ params: # 是否隐藏字段 true or false hide: true # collect metrics config list -# 采集指标组配置列表 +# 采集指标配置列表 metrics: # metrics - basic - # 监控指标组 - basic + # 监控指标 - basic - name: basic - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue - # 指标组调度优先级(0->127)->(优先级高->低) 优先级低的指标组会等优先级高的指标组采集完成后才会被调度, 相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # 指标采集调度优先级(0->127)->(优先级高->低) 优先级低的指标会等优先级高的指标采集完成后才会被调度, 相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 0 - # monitor metric content in metrics group - # 指标组中的具体监控指标 + # monitor metric content in metrics + # 具体监控指标列表 fields: # field-metric name, type-metric type(0-number,1-string), unit-metric unit('%','ms','MB'), label-whether it is a metrics label field # field-指标名称, type-指标类型(0-number数字,1-string字符串), unit-指标单位('%','ms','MB'), label-是否是指标标签字段 @@ -171,15 +171,15 @@ metrics: objectName: java.lang:type=Runtime url: ^_^url^_^ # metrics - server - # 监控指标组 - server + # 监控指标 - server - name: server - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue - # 指标组调度优先级(0->127)->(优先级高->低) 优先级低的指标组会等优先级高的指标组采集完成后才会被调度, 相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # 指标采集调度优先级(0->127)->(优先级高->低) 优先级低的指标会等优先级高的指标采集完成后才会被调度, 相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 1 - # monitor metric content in metrics group - # 指标组中的具体监控指标 + # monitor metric content in metrics + # 具体监控指标列表 fields: # field-metric name, type-metric type(0-number,1-string), unit-metric unit('%','ms','MB'), label-whether it is a metrics label field # field-指标名称, type-指标类型(0-number数字,1-string字符串), unit-指标单位('%','ms','MB'), label-是否是指标标签字段 @@ -205,15 +205,15 @@ metrics: objectName: org.eclipse.jetty.server:type=server,id=0 url: ^_^url^_^ # metrics - server - # 监控指标组 - server + # 监控指标 - server - name: memory_pool - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue - # 指标组调度优先级(0->127)->(优先级高->低) 优先级低的指标组会等优先级高的指标组采集完成后才会被调度, 相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # 指标采集调度优先级(0->127)->(优先级高->低) 优先级低的指标会等优先级高的指标采集完成后才会被调度, 相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 1 - # monitor metric content in metrics group - # 指标组中的具体监控指标 + # monitor metric content in metrics + # 具体监控指标列表 fields: # field-metric name, type-metric type(0-number,1-string), unit-metric unit('%','ms','MB'), label-whether it is a metrics label field # field-指标名称, type-指标类型(0-number数字,1-string字符串), unit-指标单位('%','ms','MB'), label-是否是指标标签字段 @@ -260,15 +260,15 @@ metrics: objectName: java.lang:type=MemoryPool,name=* url: ^_^url^_^ # metrics - class_loading - # 监控指标组 - class_loading + # 监控指标 - class_loading - name: class_loading - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue - # 指标组调度优先级(0->127)->(优先级高->低) 优先级低的指标组会等优先级高的指标组采集完成后才会被调度, 相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # 指标采集调度优先级(0->127)->(优先级高->低) 优先级低的指标会等优先级高的指标采集完成后才会被调度, 相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 1 - # monitor metric content in metrics group - # 指标组中的具体监控指标 + # monitor metric content in metrics + # 具体监控指标列表 fields: # field-metric name, type-metric type(0-number,1-string), unit-metric unit('%','ms','MB'), label-whether it is a metrics label field # field-指标名称, type-指标类型(0-number数字,1-string字符串), unit-指标单位('%','ms','MB'), label-是否是指标标签字段 @@ -293,15 +293,15 @@ metrics: objectName: java.lang:type=ClassLoading url: ^_^url^_^ # metrics - thread - # 监控指标组 - thread + # 监控指标 - thread - name: thread - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue - # 指标组调度优先级(0->127)->(优先级高->低) 优先级低的指标组会等优先级高的指标组采集完成后才会被调度, 相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # 指标采集调度优先级(0->127)->(优先级高->低) 优先级低的指标会等优先级高的指标采集完成后才会被调度, 相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 1 - # monitor metric content in metrics group - # 指标组中的具体监控指标 + # monitor metric content in metrics + # 具体监控指标列表 fields: # field-metric name, type-metric type(0-number,1-string), unit-metric unit('%','ms','MB'), label-whether it is a metrics label field # field-指标名称, type-指标类型(0-number数字,1-string字符串), unit-指标单位('%','ms','MB'), label-是否是指标标签字段 @@ -337,15 +337,15 @@ metrics: objectName: java.lang:type=Threading url: ^_^url^_^ # metrics - webapp - # 监控指标组 - webapp + # 监控指标 - webapp - name: webapp - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue - # 指标组调度优先级(0->127)->(优先级高->低) 优先级低的指标组会等优先级高的指标组采集完成后才会被调度, 相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # 指标采集调度优先级(0->127)->(优先级高->低) 优先级低的指标会等优先级高的指标采集完成后才会被调度, 相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 2 - # monitor metric content in metrics group - # 指标组中的具体监控指标 + # monitor metric content in metrics + # 具体监控指标列表 fields: # field-metric name, type-metric type(0-number,1-string), unit-metric unit('%','ms','MB'), label-whether it is a metrics label field # field-指标名称, type-指标类型(0-number数字,1-string字符串), unit-指标单位('%','ms','MB'), label-是否是指标标签字段 diff --git a/manager/src/main/resources/define/app-jvm.yml b/manager/src/main/resources/define/app-jvm.yml index 2b9ab4b626..81f546a305 100644 --- a/manager/src/main/resources/define/app-jvm.yml +++ b/manager/src/main/resources/define/app-jvm.yml @@ -128,15 +128,15 @@ params: # 是否隐藏字段 true or false hide: true # collect metrics config list -# 采集指标组配置列表 +# 采集指标配置列表 metrics: # metrics - basic - # 监控指标组 - basic + # 监控指标 - basic - name: basic - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue - # 指标组调度优先级(0->127)->(优先级高->低) 优先级低的指标组会等优先级高的指标组采集完成后才会被调度, 相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # 指标采集调度优先级(0->127)->(优先级高->低) 优先级低的指标会等优先级高的指标采集完成后才会被调度, 相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 0 i18n: zh-CN: 虚拟机基础信息 @@ -345,7 +345,7 @@ metrics: zh-CN: 线程信息 en-US: Thread # collect metrics content - # 指标组中的具体监控指标 + # 具体监控指标列表 fields: # field-metric name, type-metric type(0-number,1-string), unit-metric unit('%','ms','MB'), label-whether it is a metrics label field # field-指标名称, type-指标类型(0-number数字,1-string字符串), unit-指标单位('%','ms','MB'), label-是否是指标标签字段 diff --git a/manager/src/main/resources/define/app-kafka.yml b/manager/src/main/resources/define/app-kafka.yml index cda42a2270..7534f8bad3 100644 --- a/manager/src/main/resources/define/app-kafka.yml +++ b/manager/src/main/resources/define/app-kafka.yml @@ -84,15 +84,15 @@ params: required: false hide: true # collect metrics config list -# 采集指标组配置列表 +# 采集指标配置列表 metrics: # metrics - server_info - # 监控指标组 - server_info + # 监控指标 - server_info - name: server_info - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue - # 指标组调度优先级(0->127)->(优先级高->低) 优先级低的指标组会等优先级高的指标组采集完成后才会被调度, 相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # 指标采集调度优先级(0->127)->(优先级高->低) 优先级低的指标会等优先级高的指标采集完成后才会被调度, 相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 0 # collect metrics content # 具体监控指标列表 diff --git a/manager/src/main/resources/define/app-kafka_promql.yml b/manager/src/main/resources/define/app-kafka_promql.yml index 9f4045049c..e5d889e08f 100644 --- a/manager/src/main/resources/define/app-kafka_promql.yml +++ b/manager/src/main/resources/define/app-kafka_promql.yml @@ -118,15 +118,19 @@ params: required: false hide: true metrics: - # 第一个监控指标组 cpu - # 注意:内置监控指标有 (responseTime - 响应时间) + # metrics - kafka_brokers + # 监控指标 - kafka_brokers - name: kafka_brokers - # 指标组调度优先级(0-127)越小优先级越高,优先级低的指标组会等优先级高的指标组采集完成后才会被调度,相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # 指标采集调度优先级(0->127)->(优先级高->低) 优先级低的指标会等优先级高的指标采集完成后才会被调度, 相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 0 - # 指标组中的具体监控指标 + # collect metrics content + # 具体监控指标列表 fields: - # 指标信息 包括 field名称 type字段类型:0-number数字,1-string字符串 label-是否是指标标签字段 unit:指标单位 + # field-metric name, i18n-metric name i18n label, type-metric type(0-number,1-string), unit-metric unit('%','ms','MB'), label-whether it is a metrics label field + # field-指标名称, i18n-指标国际化展示名称, type-指标类型(0-number数字,1-string字符串), unit-指标单位('%','ms','MB'), label-是否是指标标签字段 - field: __name__ type: 1 - field: instance @@ -169,10 +173,10 @@ metrics: parseType: PromQL - name: kafka_topic_partitions - # 指标组调度优先级(0-127)越小优先级越高,优先级低的指标组会等优先级高的指标组采集完成后才会被调度,相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # 指标调度优先级(0-127)越小优先级越高,优先级低的指标会等优先级高的指标采集完成后才会被调度,相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 1 - # 指标组中的具体监控指标 + # 具体监控指标列表 fields: # 指标信息 包括 field名称 type字段类型:0-number数字,1-string字符串 label-是否是指标标签字段 unit:指标单位 - field: __name__ @@ -218,10 +222,10 @@ metrics: parseType: PromQL - name: kafka_server_brokertopicmetrics_bytesinpersec #每秒查询率 - # 指标组调度优先级(0-127)越小优先级越高,优先级低的指标组会等优先级高的指标组采集完成后才会被调度,相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # 指标调度优先级(0-127)越小优先级越高,优先级低的指标会等优先级高的指标采集完成后才会被调度,相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 1 - # 指标组中的具体监控指标 + # 具体监控指标列表 fields: # 指标信息 包括 field名称 type字段类型:0-number数字,1-string字符串 label-是否是指标标签字段 unit:指标单位 - field: instance diff --git a/manager/src/main/resources/define/app-kubernetes.yml b/manager/src/main/resources/define/app-kubernetes.yml index 4cedd7b356..1f11f47c86 100644 --- a/manager/src/main/resources/define/app-kubernetes.yml +++ b/manager/src/main/resources/define/app-kubernetes.yml @@ -97,15 +97,15 @@ params: required: true # collect metrics config list -# 采集指标组配置列表 +# 采集指标配置列表 metrics: # metrics - nodes - # 监控指标组 - nodes + # 监控指标 - nodes - name: nodes - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue - # 指标组调度优先级(0->127)->(优先级高->低) 优先级低的指标组会等优先级高的指标组采集完成后才会被调度, 相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # 指标采集调度优先级(0->127)->(优先级高->低) 优先级低的指标会等优先级高的指标采集完成后才会被调度, 相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 0 # collect metrics content # 具体监控指标列表 diff --git a/manager/src/main/resources/define/app-linux.yml b/manager/src/main/resources/define/app-linux.yml index 3fe8445070..dfc186411a 100644 --- a/manager/src/main/resources/define/app-linux.yml +++ b/manager/src/main/resources/define/app-linux.yml @@ -155,19 +155,18 @@ params: # 是否隐藏字段 true or false hide: true # collect metrics config list -# 采集指标组配置列表 +# 采集指标配置列表 metrics: # metrics - basic, inner monitoring metrics (responseTime - response time) - # 监控指标组 - basic, 内置监控指标有 (responseTime - 响应时间) + # 监控指标 - basic, 内置监控指标有 (responseTime - 响应时间) - name: basic i18n: zh-CN: 系统基本信息 en-US: Basic Info - # 指标组调度优先级(0-127)越小优先级越高,优先级低的指标组会等优先级高的指标组采集完成后才会被调度,相同优先级的指标组会并行调度采集 - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue - # 指标组调度优先级(0->127)->(优先级高->低) 优先级低的指标组会等优先级高的指标组采集完成后才会被调度, 相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # 指标采集调度优先级(0->127)->(优先级高->低) 优先级低的指标会等优先级高的指标采集完成后才会被调度, 相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 0 # collect metrics content # 具体监控指标列表 diff --git a/manager/src/main/resources/define/app-mariadb.yml b/manager/src/main/resources/define/app-mariadb.yml index acfd4611b0..7f479a82c3 100644 --- a/manager/src/main/resources/define/app-mariadb.yml +++ b/manager/src/main/resources/define/app-mariadb.yml @@ -108,15 +108,15 @@ params: hide: true # collect metrics config list -# 采集指标组配置列表 +# 采集指标配置列表 metrics: # metrics - basic - # 监控指标组 - basic + # 监控指标 - basic - name: basic - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue - # 指标组调度优先级(0->127)->(优先级高->低) 优先级低的指标组会等优先级高的指标组采集完成后才会被调度, 相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # 指标采集调度优先级(0->127)->(优先级高->低) 优先级低的指标会等优先级高的指标采集完成后才会被调度, 相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 0 # collect metrics content # 具体监控指标列表 diff --git a/manager/src/main/resources/define/app-mongodb.yml b/manager/src/main/resources/define/app-mongodb.yml index 02fa222547..06373327a0 100644 --- a/manager/src/main/resources/define/app-mongodb.yml +++ b/manager/src/main/resources/define/app-mongodb.yml @@ -109,16 +109,16 @@ params: # name 必须为 Diagnostic Commands 名称,支持 . 方式获取子文档,需注意连接的用户是否具有相应命令的权限 # collect metrics config list -# 采集指标组配置列表 +# 采集指标配置列表 metrics: # https://www.mongodb.com/docs/manual/reference/command/buildInfo/#usage # metrics - buildInfo - # 监控指标组 - buildInfo + # 监控指标 - buildInfo - name: buildInfo - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue - # 指标组调度优先级(0->127)->(优先级高->低) 优先级低的指标组会等优先级高的指标组采集完成后才会被调度, 相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # 指标采集调度优先级(0->127)->(优先级高->低) 优先级低的指标会等优先级高的指标采集完成后才会被调度, 相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 1 # collect metrics content i18n: diff --git a/manager/src/main/resources/define/app-mysql.yml b/manager/src/main/resources/define/app-mysql.yml index 4c6f9a39c9..8cecf47801 100644 --- a/manager/src/main/resources/define/app-mysql.yml +++ b/manager/src/main/resources/define/app-mysql.yml @@ -156,15 +156,15 @@ params: hide: true # collect metrics config list -# 采集指标组配置列表 +# 采集指标配置列表 metrics: # metrics - basic - # 监控指标组 - basic + # 监控指标 - basic - name: basic - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue - # 指标组调度优先级(0->127)->(优先级高->低) 优先级低的指标组会等优先级高的指标组采集完成后才会被调度, 相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # 指标采集调度优先级(0->127)->(优先级高->低) 优先级低的指标会等优先级高的指标采集完成后才会被调度, 相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 0 i18n: zh-CN: 基础 信息 @@ -267,10 +267,10 @@ metrics: url: ^_^url^_^ - name: cache - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue - # 指标组调度优先级(0->127)->(优先级高->低) 优先级低的指标组会等优先级高的指标组采集完成后才会被调度, 相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # 指标采集调度优先级(0->127)->(优先级高->低) 优先级低的指标会等优先级高的指标采集完成后才会被调度, 相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 1 # collect metrics content # 具体监控指标列表 diff --git a/manager/src/main/resources/define/app-nacos.yml b/manager/src/main/resources/define/app-nacos.yml index ffcc353426..0029453bdf 100644 --- a/manager/src/main/resources/define/app-nacos.yml +++ b/manager/src/main/resources/define/app-nacos.yml @@ -72,13 +72,13 @@ params: defaultValue: 8848 # collect metrics config list -# 采集指标组配置列表 +# 采集指标配置列表 metrics: - name: system_cpu_usage - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue - # 指标组调度优先级(0->127)->(优先级高->低) 优先级低的指标组会等优先级高的指标组采集完成后才会被调度, 相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # 指标采集调度优先级(0->127)->(优先级高->低) 优先级低的指标会等优先级高的指标采集完成后才会被调度, 相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 0 fields: - field: usage diff --git a/manager/src/main/resources/define/app-opengauss.yml b/manager/src/main/resources/define/app-opengauss.yml index 38dbb4c7b9..534045ca09 100644 --- a/manager/src/main/resources/define/app-opengauss.yml +++ b/manager/src/main/resources/define/app-opengauss.yml @@ -82,10 +82,10 @@ params: hide: true metrics: - name: basic - # 指标组调度优先级(0-127)越小优先级越高,优先级低的指标组会等优先级高的指标组采集完成后才会被调度,相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # 指标调度优先级(0-127)越小优先级越高,优先级低的指标会等优先级高的指标采集完成后才会被调度,相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 0 - # 指标组中的具体监控指标 + # 具体监控指标列表 fields: # 指标信息 包括 field名称 type字段类型:0-number数字,1-string字符串 label-是否是指标标签字段 unit:指标单位 - field: server_version diff --git a/manager/src/main/resources/define/app-opensuse.yml b/manager/src/main/resources/define/app-opensuse.yml index 76b8a21f0d..ee12f9468c 100644 --- a/manager/src/main/resources/define/app-opensuse.yml +++ b/manager/src/main/resources/define/app-opensuse.yml @@ -155,19 +155,18 @@ params: # 是否隐藏字段 true or false hide: true # collect metrics config list -# 采集指标组配置列表 +# 采集指标配置列表 metrics: # metrics - basic, inner monitoring metrics (responseTime - response time) - # 监控指标组 - basic, 内置监控指标有 (responseTime - 响应时间) + # 监控指标 - basic, 内置监控指标有 (responseTime - 响应时间) - name: basic i18n: zh-CN: 系统基本信息 en-US: Basic Info - # 指标组调度优先级(0-127)越小优先级越高,优先级低的指标组会等优先级高的指标组采集完成后才会被调度,相同优先级的指标组会并行调度采集 - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue - # 指标组调度优先级(0->127)->(优先级高->低) 优先级低的指标组会等优先级高的指标组采集完成后才会被调度, 相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # 指标采集调度优先级(0->127)->(优先级高->低) 优先级低的指标会等优先级高的指标采集完成后才会被调度, 相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 0 # collect metrics content # 具体监控指标列表 diff --git a/manager/src/main/resources/define/app-oracle.yml b/manager/src/main/resources/define/app-oracle.yml index 1ffa7367c7..6b8d727bf5 100644 --- a/manager/src/main/resources/define/app-oracle.yml +++ b/manager/src/main/resources/define/app-oracle.yml @@ -106,15 +106,15 @@ params: hide: true # collect metrics config list -# 采集指标组配置列表 +# 采集指标配置列表 metrics: # metrics - basic - # 监控指标组 - basic + # 监控指标 - basic - name: basic - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue - # 指标组调度优先级(0->127)->(优先级高->低) 优先级低的指标组会等优先级高的指标组采集完成后才会被调度, 相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # 指标采集调度优先级(0->127)->(优先级高->低) 优先级低的指标会等优先级高的指标采集完成后才会被调度, 相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 0 # collect metrics content # 具体监控指标列表 diff --git a/manager/src/main/resources/define/app-ping.yml b/manager/src/main/resources/define/app-ping.yml index 1ddc668318..d920adcd7b 100644 --- a/manager/src/main/resources/define/app-ping.yml +++ b/manager/src/main/resources/define/app-ping.yml @@ -74,20 +74,18 @@ params: # 默认值 6000 defaultValue: 6000 # collect metrics config list -# 采集指标组配置列表 +# 采集指标配置列表 metrics: - # First monitoring metric group "cpu" - # 第一个监控指标组 cpu + # First monitoring metric group summary # Note: The built-in monitoring metrics include (responseTime - response time) - # 注意:内置监控指标有 (responseTime - 响应时间) - name: summary i18n: zh-CN: 概要 en-US: Summary - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue - # 指标组调度优先级(0->127)->(优先级高->低) 优先级低的指标组会等优先级高的指标组采集完成后才会被调度, 相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # 指标采集调度优先级(0->127)->(优先级高->低) 优先级低的指标会等优先级高的指标采集完成后才会被调度, 相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 0 # 指标信息 包括 field名称 type字段类型:0-number数字,1-string字符串 label-是否是指标标签字段 unit:指标单位 # field-metric name, type-metric type(0-number,1-string), unit-metric unit('%','ms','MB'), label-whether it is a metrics label field diff --git a/manager/src/main/resources/define/app-port.yml b/manager/src/main/resources/define/app-port.yml index a8a5941e0f..bbb10d4aca 100644 --- a/manager/src/main/resources/define/app-port.yml +++ b/manager/src/main/resources/define/app-port.yml @@ -90,15 +90,15 @@ params: # 默认值 6000 defaultValue: 6000 # collect metrics config list -# 采集指标组配置列表 +# 采集指标配置列表 metrics: # metrics - summary - # 监控指标组 - summary + # 监控指标 - summary - name: summary - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue - # 指标组调度优先级(0->127)->(优先级高->低) 优先级低的指标组会等优先级高的指标组采集完成后才会被调度, 相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # 指标采集调度优先级(0->127)->(优先级高->低) 优先级低的指标会等优先级高的指标采集完成后才会被调度, 相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 0 # 指标信息 包括 field名称 type字段类型:0-number数字,1-string字符串 label-是否是指标标签字段 unit:指标单位 # field-metric name, type-metric type(0-number,1-string), unit-metric unit('%','ms','MB'), label-whether it is a metrics label field diff --git a/manager/src/main/resources/define/app-postgresql.yml b/manager/src/main/resources/define/app-postgresql.yml index 6b36e6151c..60c6c1bd6d 100644 --- a/manager/src/main/resources/define/app-postgresql.yml +++ b/manager/src/main/resources/define/app-postgresql.yml @@ -107,15 +107,15 @@ params: hide: true # collect metrics config list -# 采集指标组配置列表 +# 采集指标配置列表 metrics: # metrics - basic - # 监控指标组 - basic + # 监控指标 - basic - name: basic - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue - # 指标组调度优先级(0->127)->(优先级高->低) 优先级低的指标组会等优先级高的指标组采集完成后才会被调度, 相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # 指标采集调度优先级(0->127)->(优先级高->低) 优先级低的指标会等优先级高的指标采集完成后才会被调度, 相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 0 # collect metrics content # 具体监控指标列表 diff --git a/manager/src/main/resources/define/app-prometheus.yml b/manager/src/main/resources/define/app-prometheus.yml index 580ca6b924..c79f77e253 100644 --- a/manager/src/main/resources/define/app-prometheus.yml +++ b/manager/src/main/resources/define/app-prometheus.yml @@ -245,15 +245,15 @@ params: # 是否隐藏字段 true or false hide: true # collect metrics config list -# 采集指标组配置列表 +# 采集指标配置列表 metrics: # metrics - cluster_node_status - # 监控指标组 - cluster_node_status + # 监控指标 - cluster_node_status - name: auto - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue - # 指标组调度优先级(0->127)->(优先级高->低) 优先级低的指标组会等优先级高的指标组采集完成后才会被调度, 相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # 指标采集调度优先级(0->127)->(优先级高->低) 优先级低的指标会等优先级高的指标采集完成后才会被调度, 相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 0 # the protocol used for monitoring, eg: sql, ssh, http, telnet, wmi, snmp, sdk protocol: prometheus diff --git a/manager/src/main/resources/define/app-push.yml b/manager/src/main/resources/define/app-push.yml index 3c7a568f7e..6072b2b699 100644 --- a/manager/src/main/resources/define/app-push.yml +++ b/manager/src/main/resources/define/app-push.yml @@ -74,15 +74,15 @@ params: required: true # collect metrics config list -# 采集指标组配置列表 +# 采集指标配置列表 metrics: # metrics - all - # 监控指标组 - all + # 监控指标 - all - name: metrics - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue - # 指标组调度优先级(0->127)->(优先级高->低) 优先级低的指标组会等优先级高的指标组采集完成后才会被调度, 相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # 指标采集调度优先级(0->127)->(优先级高->低) 优先级低的指标会等优先级高的指标采集完成后才会被调度, 相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 0 # the protocol used for monitoring, eg: sql, ssh, http, telnet, wmi, snmp, sdk protocol: push diff --git a/manager/src/main/resources/define/app-rabbitmq.yml b/manager/src/main/resources/define/app-rabbitmq.yml index 96dd8afe3f..31b69f442e 100644 --- a/manager/src/main/resources/define/app-rabbitmq.yml +++ b/manager/src/main/resources/define/app-rabbitmq.yml @@ -136,10 +136,10 @@ metrics: # Note: The built-in monitoring metrics include (responseTime - response time) # 注意:内置监控指标有 (responseTime - 响应时间) - name: overview - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue - # 指标组调度优先级(0->127)->(优先级高->低) 优先级低的指标组会等优先级高的指标组采集完成后才会被调度, 相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # 指标采集调度优先级(0->127)->(优先级高->低) 优先级低的指标会等优先级高的指标采集完成后才会被调度, 相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 0 # collect metrics content # 具体监控指标列表 @@ -184,10 +184,10 @@ metrics: parseType: default - name: object_totals - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue - # 指标组调度优先级(0->127)->(优先级高->低) 优先级低的指标组会等优先级高的指标组采集完成后才会被调度, 相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # 指标采集调度优先级(0->127)->(优先级高->低) 优先级低的指标会等优先级高的指标采集完成后才会被调度, 相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 1 # collect metrics content # 具体监控指标列表 @@ -227,10 +227,10 @@ metrics: parseScript: '$.object_totals' - name: nodes - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue - # 指标组调度优先级(0->127)->(优先级高->低) 优先级低的指标组会等优先级高的指标组采集完成后才会被调度, 相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # 指标采集调度优先级(0->127)->(优先级高->低) 优先级低的指标会等优先级高的指标采集完成后才会被调度, 相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 1 # collect metrics content # 具体监控指标列表 @@ -348,10 +348,10 @@ metrics: parseScript: '$.*' - name: queues - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue - # 指标组调度优先级(0->127)->(优先级高->低) 优先级低的指标组会等优先级高的指标组采集完成后才会被调度, 相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # 指标采集调度优先级(0->127)->(优先级高->低) 优先级低的指标会等优先级高的指标采集完成后才会被调度, 相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 1 # collect metrics content # 具体监控指标列表 diff --git a/manager/src/main/resources/define/app-redhat.yml b/manager/src/main/resources/define/app-redhat.yml index e339e0f0fb..f98e99107b 100644 --- a/manager/src/main/resources/define/app-redhat.yml +++ b/manager/src/main/resources/define/app-redhat.yml @@ -155,19 +155,18 @@ params: # 是否隐藏字段 true or false hide: true # collect metrics config list -# 采集指标组配置列表 +# 采集指标配置列表 metrics: # metrics - basic, inner monitoring metrics (responseTime - response time) - # 监控指标组 - basic, 内置监控指标有 (responseTime - 响应时间) + # 监控指标 - basic, 内置监控指标有 (responseTime - 响应时间) - name: basic i18n: zh-CN: 系统基本信息 en-US: Basic Info - # 指标组调度优先级(0-127)越小优先级越高,优先级低的指标组会等优先级高的指标组采集完成后才会被调度,相同优先级的指标组会并行调度采集 - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue - # 指标组调度优先级(0->127)->(优先级高->低) 优先级低的指标组会等优先级高的指标组采集完成后才会被调度, 相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # 指标采集调度优先级(0->127)->(优先级高->低) 优先级低的指标会等优先级高的指标采集完成后才会被调度, 相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 0 # collect metrics content # 具体监控指标列表 diff --git a/manager/src/main/resources/define/app-redis.yml b/manager/src/main/resources/define/app-redis.yml index 9af4d631cd..cf71878d0f 100644 --- a/manager/src/main/resources/define/app-redis.yml +++ b/manager/src/main/resources/define/app-redis.yml @@ -109,15 +109,15 @@ params: required: false # collect metrics config list -# 采集指标组配置列表 +# 采集指标配置列表 metrics: # metrics - server - # 监控指标组 - server + # 监控指标 - server - name: server - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue - # 指标组调度优先级(0->127)->(优先级高->低) 优先级低的指标组会等优先级高的指标组采集完成后才会被调度, 相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # 指标采集调度优先级(0->127)->(优先级高->低) 优先级低的指标会等优先级高的指标采集完成后才会被调度, 相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 0 fields: # field-metric name, type-metric type(0-number,1-string), unit-metric unit('%','ms','MB'), label-whether it is a metrics label field @@ -192,12 +192,12 @@ metrics: # 超时时间 单位:ms timeout: ^_^timeout^_^ # metrics - clients - # 监控指标组 - clients + # 监控指标 - clients - name: clients - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue - # 指标组调度优先级(0->127)->(优先级高->低) 优先级低的指标组会等优先级高的指标组采集完成后才会被调度, 相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # 指标采集调度优先级(0->127)->(优先级高->低) 优先级低的指标会等优先级高的指标采集完成后才会被调度, 相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 1 # collect metrics content # 具体监控指标列表 @@ -226,12 +226,12 @@ metrics: password: ^_^password^_^ timeout: ^_^timeout^_^ # metrics - memory - # 监控指标组 - memory + # 监控指标 - memory - name: memory - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue - # 指标组调度优先级(0->127)->(优先级高->低) 优先级低的指标组会等优先级高的指标组采集完成后才会被调度, 相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # 指标采集调度优先级(0->127)->(优先级高->低) 优先级低的指标会等优先级高的指标采集完成后才会被调度, 相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 2 # collect metrics content # 具体监控指标列表 @@ -352,12 +352,12 @@ metrics: timeout: ^_^timeout^_^ # metrics - persistence - # 监控指标组 - persistence + # 监控指标 - persistence - name: persistence - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue - # 指标组调度优先级(0->127)->(优先级高->低) 优先级低的指标组会等优先级高的指标组采集完成后才会被调度, 相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # 指标采集调度优先级(0->127)->(优先级高->低) 优先级低的指标会等优先级高的指标采集完成后才会被调度, 相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 3 # collect metrics content # 具体监控指标列表 @@ -433,12 +433,12 @@ metrics: timeout: ^_^timeout^_^ # metrics - stats - # 监控指标组 - stats + # 监控指标 - stats - name: stats - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue - # 指标组调度优先级(0->127)->(优先级高->低) 优先级低的指标组会等优先级高的指标组采集完成后才会被调度, 相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # 指标采集调度优先级(0->127)->(优先级高->低) 优先级低的指标会等优先级高的指标采集完成后才会被调度, 相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 4 # collect metrics content # 具体监控指标列表 @@ -544,12 +544,12 @@ metrics: timeout: ^_^timeout^_^ # metrics - replication - # 监控指标组 - replication + # 监控指标 - replication - name: replication - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue - # 指标组调度优先级(0->127)->(优先级高->低) 优先级低的指标组会等优先级高的指标组采集完成后才会被调度, 相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # 指标采集调度优先级(0->127)->(优先级高->低) 优先级低的指标会等优先级高的指标采集完成后才会被调度, 相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 5 # collect metrics content # 具体监控指标列表 @@ -601,12 +601,12 @@ metrics: timeout: ^_^timeout^_^ # metrics - cpu - # 监控指标组 - cpu + # 监控指标 - cpu - name: cpu - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue - # 指标组调度优先级(0->127)->(优先级高->低) 优先级低的指标组会等优先级高的指标组采集完成后才会被调度, 相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # 指标采集调度优先级(0->127)->(优先级高->低) 优先级低的指标会等优先级高的指标采集完成后才会被调度, 相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 6 # collect metrics content # 具体监控指标列表 @@ -648,12 +648,12 @@ metrics: timeout: ^_^timeout^_^ # metrics - errorstats - # 监控指标组 - errorstats + # 监控指标 - errorstats - name: errorstats - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue - # 指标组调度优先级(0->127)->(优先级高->低) 优先级低的指标组会等优先级高的指标组采集完成后才会被调度, 相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # 指标采集调度优先级(0->127)->(优先级高->低) 优先级低的指标会等优先级高的指标采集完成后才会被调度, 相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 8 # collect metrics content # 具体监控指标列表 @@ -687,7 +687,7 @@ metrics: timeout: ^_^timeout^_^ # metrics - cluster - # 监控指标组 - cluster + # 监控指标 - cluster - name: cluster # collect metrics content # 具体监控指标列表 @@ -720,12 +720,12 @@ metrics: timeout: ^_^timeout^_^ # metrics - commandstats - # 监控指标组 - commandstats + # 监控指标 - commandstats - name: commandstats - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue - # 指标组调度优先级(0->127)->(优先级高->低) 优先级低的指标组会等优先级高的指标组采集完成后才会被调度, 相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # 指标采集调度优先级(0->127)->(优先级高->低) 优先级低的指标会等优先级高的指标采集完成后才会被调度, 相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 9 # collect metrics content # 具体监控指标列表 @@ -775,12 +775,12 @@ metrics: timeout: ^_^timeout^_^ # metrics - keyspace - # 监控指标组 - keyspace + # 监控指标 - keyspace - name: keyspace - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue - # 指标组调度优先级(0->127)->(优先级高->低) 优先级低的指标组会等优先级高的指标组采集完成后才会被调度, 相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # 指标采集调度优先级(0->127)->(优先级高->低) 优先级低的指标会等优先级高的指标采集完成后才会被调度, 相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 9 # collect metrics content # 具体监控指标列表 diff --git a/manager/src/main/resources/define/app-redis_cluster.yml b/manager/src/main/resources/define/app-redis_cluster.yml index cf5634ea05..7255b3930e 100644 --- a/manager/src/main/resources/define/app-redis_cluster.yml +++ b/manager/src/main/resources/define/app-redis_cluster.yml @@ -143,10 +143,10 @@ params: hide: true metrics: - name: server - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue - # 指标组调度优先级(0->127)->(优先级高->低) 优先级低的指标组会等优先级高的指标组采集完成后才会被调度, 相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # 指标采集调度优先级(0->127)->(优先级高->低) 优先级低的指标会等优先级高的指标采集完成后才会被调度, 相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 0 fields: # field-metric name, type-metric type(0-number,1-string), unit-metric unit('%','ms','MB'), label-whether it is a metrics label field @@ -224,10 +224,10 @@ metrics: - name: clients - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue - # 指标组调度优先级(0->127)->(优先级高->低) 优先级低的指标组会等优先级高的指标组采集完成后才会被调度, 相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # 指标采集调度优先级(0->127)->(优先级高->低) 优先级低的指标会等优先级高的指标采集完成后才会被调度, 相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 1 fields: # field-metric name, type-metric type(0-number,1-string), unit-metric unit('%','ms','MB'), label-whether it is a metrics label field @@ -274,10 +274,10 @@ metrics: pattern: ^_^pattern^_^ - name: memory - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue - # 指标组调度优先级(0->127)->(优先级高->低) 优先级低的指标组会等优先级高的指标组采集完成后才会被调度, 相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # 指标采集调度优先级(0->127)->(优先级高->低) 优先级低的指标会等优先级高的指标采集完成后才会被调度, 相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 2 fields: # field-metric name, type-metric type(0-number,1-string), unit-metric unit('%','ms','MB'), label-whether it is a metrics label field @@ -399,10 +399,10 @@ metrics: pattern: ^_^pattern^_^ - name: persistence - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue - # 指标组调度优先级(0->127)->(优先级高->低) 优先级低的指标组会等优先级高的指标组采集完成后才会被调度, 相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # 指标采集调度优先级(0->127)->(优先级高->低) 优先级低的指标会等优先级高的指标采集完成后才会被调度, 相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 3 fields: # field-metric name, type-metric type(0-number,1-string), unit-metric unit('%','ms','MB'), label-whether it is a metrics label field @@ -479,10 +479,10 @@ metrics: pattern: ^_^pattern^_^ - name: stats - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue - # 指标组调度优先级(0->127)->(优先级高->低) 优先级低的指标组会等优先级高的指标组采集完成后才会被调度, 相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # 指标采集调度优先级(0->127)->(优先级高->低) 优先级低的指标会等优先级高的指标采集完成后才会被调度, 相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 4 fields: # field-metric name, type-metric type(0-number,1-string), unit-metric unit('%','ms','MB'), label-whether it is a metrics label field @@ -589,10 +589,10 @@ metrics: pattern: ^_^pattern^_^ - name: replication - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue - # 指标组调度优先级(0->127)->(优先级高->低) 优先级低的指标组会等优先级高的指标组采集完成后才会被调度, 相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # 指标采集调度优先级(0->127)->(优先级高->低) 优先级低的指标会等优先级高的指标采集完成后才会被调度, 相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 5 fields: # field-metric name, type-metric type(0-number,1-string), unit-metric unit('%','ms','MB'), label-whether it is a metrics label field @@ -645,10 +645,10 @@ metrics: pattern: ^_^pattern^_^ - name: cpu - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue - # 指标组调度优先级(0->127)->(优先级高->低) 优先级低的指标组会等优先级高的指标组采集完成后才会被调度, 相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # 指标采集调度优先级(0->127)->(优先级高->低) 优先级低的指标会等优先级高的指标采集完成后才会被调度, 相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 6 fields: # field-metric name, type-metric type(0-number,1-string), unit-metric unit('%','ms','MB'), label-whether it is a metrics label field @@ -691,10 +691,10 @@ metrics: pattern: ^_^pattern^_^ - name: errorstats - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue - # 指标组调度优先级(0->127)->(优先级高->低) 优先级低的指标组会等优先级高的指标组采集完成后才会被调度, 相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # 指标采集调度优先级(0->127)->(优先级高->低) 优先级低的指标会等优先级高的指标采集完成后才会被调度, 相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 8 fields: # field-metric name, type-metric type(0-number,1-string), unit-metric unit('%','ms','MB'), label-whether it is a metrics label field @@ -729,10 +729,10 @@ metrics: pattern: ^_^pattern^_^ - name: cluster - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue - # 指标组调度优先级(0->127)->(优先级高->低) 优先级低的指标组会等优先级高的指标组采集完成后才会被调度, 相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # 指标采集调度优先级(0->127)->(优先级高->低) 优先级低的指标会等优先级高的指标采集完成后才会被调度, 相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 9 fields: # field-metric name, type-metric type(0-number,1-string), unit-metric unit('%','ms','MB'), label-whether it is a metrics label field @@ -797,10 +797,10 @@ metrics: pattern: ^_^pattern^_^ - name: commandstats - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue - # 指标组调度优先级(0->127)->(优先级高->低) 优先级低的指标组会等优先级高的指标组采集完成后才会被调度, 相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # 指标采集调度优先级(0->127)->(优先级高->低) 优先级低的指标会等优先级高的指标采集完成后才会被调度, 相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 9 fields: # field-metric name, type-metric type(0-number,1-string), unit-metric unit('%','ms','MB'), label-whether it is a metrics label field @@ -852,10 +852,10 @@ metrics: - name: keyspace - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue - # 指标组调度优先级(0->127)->(优先级高->低) 优先级低的指标组会等优先级高的指标组采集完成后才会被调度, 相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # 指标采集调度优先级(0->127)->(优先级高->低) 优先级低的指标会等优先级高的指标采集完成后才会被调度, 相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 9 fields: # field-metric name, type-metric type(0-number,1-string), unit-metric unit('%','ms','MB'), label-whether it is a metrics label field diff --git a/manager/src/main/resources/define/app-redis_sentinel.yml b/manager/src/main/resources/define/app-redis_sentinel.yml index 58ca84ce81..72374d9790 100644 --- a/manager/src/main/resources/define/app-redis_sentinel.yml +++ b/manager/src/main/resources/define/app-redis_sentinel.yml @@ -141,10 +141,10 @@ params: hide: true metrics: - name: server - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue - # 指标组调度优先级(0->127)->(优先级高->低) 优先级低的指标组会等优先级高的指标组采集完成后才会被调度, 相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # 指标采集调度优先级(0->127)->(优先级高->低) 优先级低的指标会等优先级高的指标采集完成后才会被调度, 相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 0 fields: # field-metric name, type-metric type(0-number,1-string), unit-metric unit('%','ms','MB'), label-whether it is a metrics label field @@ -221,10 +221,10 @@ metrics: pattern: ^_^pattern^_^ - name: clients - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue - # 指标组调度优先级(0->127)->(优先级高->低) 优先级低的指标组会等优先级高的指标组采集完成后才会被调度, 相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # 指标采集调度优先级(0->127)->(优先级高->低) 优先级低的指标会等优先级高的指标采集完成后才会被调度, 相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 1 fields: # field-metric name, type-metric type(0-number,1-string), unit-metric unit('%','ms','MB'), label-whether it is a metrics label field @@ -269,10 +269,10 @@ metrics: pattern: ^_^pattern^_^ - name: stats - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue - # 指标组调度优先级(0->127)->(优先级高->低) 优先级低的指标组会等优先级高的指标组采集完成后才会被调度, 相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # 指标采集调度优先级(0->127)->(优先级高->低) 优先级低的指标会等优先级高的指标采集完成后才会被调度, 相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 2 fields: # field-metric name, type-metric type(0-number,1-string), unit-metric unit('%','ms','MB'), label-whether it is a metrics label field @@ -377,10 +377,10 @@ metrics: pattern: ^_^pattern^_^ - name: cpu - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue - # 指标组调度优先级(0->127)->(优先级高->低) 优先级低的指标组会等优先级高的指标组采集完成后才会被调度, 相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # 指标采集调度优先级(0->127)->(优先级高->低) 优先级低的指标会等优先级高的指标采集完成后才会被调度, 相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 3 fields: # field-metric name, type-metric type(0-number,1-string), unit-metric unit('%','ms','MB'), label-whether it is a metrics label field @@ -421,10 +421,10 @@ metrics: pattern: ^_^pattern^_^ - name: sentinel - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue - # 指标组调度优先级(0->127)->(优先级高->低) 优先级低的指标组会等优先级高的指标组采集完成后才会被调度, 相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # 指标采集调度优先级(0->127)->(优先级高->低) 优先级低的指标会等优先级高的指标采集完成后才会被调度, 相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 4 fields: # field-metric name, type-metric type(0-number,1-string), unit-metric unit('%','ms','MB'), label-whether it is a metrics label field diff --git a/manager/src/main/resources/define/app-rockylinux.yml b/manager/src/main/resources/define/app-rockylinux.yml index 5d41349091..c52871c13e 100644 --- a/manager/src/main/resources/define/app-rockylinux.yml +++ b/manager/src/main/resources/define/app-rockylinux.yml @@ -155,19 +155,18 @@ params: # 是否隐藏字段 true or false hide: true # collect metrics config list -# 采集指标组配置列表 +# 采集指标配置列表 metrics: # metrics - basic, inner monitoring metrics (responseTime - response time) - # 监控指标组 - basic, 内置监控指标有 (responseTime - 响应时间) + # 监控指标 - basic, 内置监控指标有 (responseTime - 响应时间) - name: basic i18n: zh-CN: 系统基本信息 en-US: Basic Info - # 指标组调度优先级(0-127)越小优先级越高,优先级低的指标组会等优先级高的指标组采集完成后才会被调度,相同优先级的指标组会并行调度采集 - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue - # 指标组调度优先级(0->127)->(优先级高->低) 优先级低的指标组会等优先级高的指标组采集完成后才会被调度, 相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # 指标采集调度优先级(0->127)->(优先级高->低) 优先级低的指标会等优先级高的指标采集完成后才会被调度, 相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 0 # collect metrics content # 具体监控指标列表 diff --git a/manager/src/main/resources/define/app-shenyu.yml b/manager/src/main/resources/define/app-shenyu.yml index c82fd9c1c4..69d44b1f8d 100644 --- a/manager/src/main/resources/define/app-shenyu.yml +++ b/manager/src/main/resources/define/app-shenyu.yml @@ -13,7 +13,7 @@ # See the License for the specific language governing permissions and # limitations under the License. -category: bigdata +category: mid app: shenyu name: zh-CN: Apache ShenYu diff --git a/manager/src/main/resources/define/app-spark.yml b/manager/src/main/resources/define/app-spark.yml index b20eb3e5ed..c1c75cff48 100644 --- a/manager/src/main/resources/define/app-spark.yml +++ b/manager/src/main/resources/define/app-spark.yml @@ -128,15 +128,15 @@ params: # 是否隐藏字段 true or false hide: true # collect metrics config list -# 采集指标组配置列表 +# 采集指标配置列表 metrics: # metrics - basic - # 监控指标组 - basic + # 监控指标 - basic - name: basic - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue - # 指标组调度优先级(0->127)->(优先级高->低) 优先级低的指标组会等优先级高的指标组采集完成后才会被调度, 相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # 指标采集调度优先级(0->127)->(优先级高->低) 优先级低的指标会等优先级高的指标采集完成后才会被调度, 相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 0 # collect metrics content # 具体监控指标列表 @@ -282,7 +282,7 @@ metrics: - name: thread priority: 7 # collect metrics content - # 指标组中的具体监控指标 + # 具体监控指标列表 fields: # field-metric name, type-metric type(0-number,1-string), unit-metric unit('%','ms','MB'), label-whether it is a metrics label field # field-指标名称, type-指标类型(0-number数字,1-string字符串), unit-指标单位('%','ms','MB'), label-是否是指标标签字段 diff --git a/manager/src/main/resources/define/app-spring_gateway.yml b/manager/src/main/resources/define/app-spring_gateway.yml index 79c65c290f..b448d4e6e8 100644 --- a/manager/src/main/resources/define/app-spring_gateway.yml +++ b/manager/src/main/resources/define/app-spring_gateway.yml @@ -15,11 +15,10 @@ # The monitoring type category:service-application service monitoring db-database monitoring custom-custom monitoring os-operating system monitoring # 监控类型所属类别:service-应用服务 program-应用程序 db-数据库 custom-自定义 os-操作系统 bigdata-大数据 mid-中间件 webserver-web服务器 cache-缓存 cn-云原生 network-网络监控等等 -category: program +category: mid # The monitoring type eg: springboot2 linux windows tomcat mysql aws... # 监控类型 eg: springboot2 linux windows tomcat mysql aws... app: spring_gateway - # The monitoring i18n name # 监控类型国际化名称 name: @@ -106,18 +105,18 @@ params: # hide-是否隐藏 true-隐藏 false-不隐藏 hide: true # collect metrics config list -# 采集指标组配置列表 +# 采集指标配置列表 metrics: # metrics - available - # 监控指标组 - available + # 监控指标 - available - name: available - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue - # 指标组调度优先级(0-127)越小优先级越高,优先级低的指标组会等优先级高的指标组采集完成后才会被调度,相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # 指标采集调度优先级(0->127)->(优先级高->低) 优先级低的指标会等优先级高的指标采集完成后才会被调度, 相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 0 # collect metrics content - # 指标组中的具体监控指标 + # 具体监控指标列表 fields: # field-metric name, type-metric type(0-number,1-string), instance-is instance primary key, unit-metric unit # 指标信息 包括 field名称 type字段类型:0-number数字,1-string字符串 instance是否为实例主键 unit:指标单位 @@ -149,12 +148,8 @@ metrics: # 响应数据解析方式: default-系统规则,jsonPath-jsonPath脚本,website-api可用性指标监控 parseType: default - # metrics - environment - # 监控指标组 - environment - name: environment priority: 1 - # The specific monitoring metrics in the metric group. - # 指标组中的具体监控指标 fields: # The metric information, including field name, type of the field (0-number, 1-string), whether it is an instance primary key, and the unit of the metric. # 指标信息 包括 field名称 type字段类型:0-number数字,1-string字符串 label-是否是指标标签字段 unit:指标单位 @@ -356,4 +351,4 @@ metrics: method: GET ssl: ^_^ssl^_^ parseType: jsonPath - parseScript: '$' \ No newline at end of file + parseScript: '$' diff --git a/manager/src/main/resources/define/app-springboot2.yml b/manager/src/main/resources/define/app-springboot2.yml index 0d2438f083..c4870160dd 100644 --- a/manager/src/main/resources/define/app-springboot2.yml +++ b/manager/src/main/resources/define/app-springboot2.yml @@ -105,18 +105,18 @@ params: # hide-是否隐藏 true-隐藏 false-不隐藏 hide: true # collect metrics config list -# 采集指标组配置列表 +# 采集指标配置列表 metrics: # metrics - available - # 监控指标组 - available + # 监控指标 - available - name: available - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue - # 指标组调度优先级(0-127)越小优先级越高,优先级低的指标组会等优先级高的指标组采集完成后才会被调度,相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # 指标调度优先级(0-127)越小优先级越高,优先级低的指标会等优先级高的指标采集完成后才会被调度,相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 0 # collect metrics content - # 指标组中的具体监控指标 + # 具体监控指标列表 fields: # field-metric name, type-metric type(0-number,1-string), instance-is instance primary key, unit-metric unit # 指标信息 包括 field名称 type字段类型:0-number数字,1-string字符串 label-是否是指标标签字段 unit:指标单位 @@ -148,11 +148,11 @@ metrics: # 响应数据解析方式: default-系统规则,jsonPath-jsonPath脚本,website-api可用性指标监控 parseType: default # metrics - environment - # 监控指标组 - environment + # 监控指标 - environment - name: environment priority: 1 # The specific monitoring metrics in the metric group. - # 指标组中的具体监控指标 + # 具体监控指标列表 fields: # The metric information, including field name, type of the field (0-number, 1-string), whether it is an instance primary key, and the unit of the metric. # 指标信息 包括 field名称 type字段类型:0-number数字,1-string字符串 label-是否是指标标签字段 unit:指标单位 @@ -214,13 +214,13 @@ metrics: # 响应数据解析脚本 parseScript: '$' # metrics - thread_state - # 监控指标组 - thread_state + # 监控指标 - thread_state - name: thread_state # Whether to display the metric group in the query result, the default is true - # 是否在查询结果中显示指标组,默认为true + # 是否在查询结果中显示,默认为true visible: false # The specific monitoring metrics in the metric group. - # 指标组中的具体监控指标 + # 具体监控指标列表 priority: 2 fields: - field: state diff --git a/manager/src/main/resources/define/app-springboot3.yml b/manager/src/main/resources/define/app-springboot3.yml index c537b5b3f1..190647360e 100644 --- a/manager/src/main/resources/define/app-springboot3.yml +++ b/manager/src/main/resources/define/app-springboot3.yml @@ -106,18 +106,18 @@ params: # hide-是否隐藏 true-隐藏 false-不隐藏 hide: true # collect metrics config list -# 采集指标组配置列表 +# 采集指标配置列表 metrics: # metrics - available - # 监控指标组 - available + # 监控指标 - available - name: available - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue - # 指标组调度优先级(0-127)越小优先级越高,优先级低的指标组会等优先级高的指标组采集完成后才会被调度,相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # 指标调度优先级(0-127)越小优先级越高,优先级低的指标会等优先级高的指标采集完成后才会被调度,相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 0 # collect metrics content - # 指标组中的具体监控指标 + # 具体监控指标列表 fields: # field-metric name, type-metric type(0-number,1-string), instance-is instance primary key, unit-metric unit # 指标信息 包括 field名称 type字段类型:0-number数字,1-string字符串 label-是否是指标标签字段 unit:指标单位 diff --git a/manager/src/main/resources/define/app-sqlserver.yml b/manager/src/main/resources/define/app-sqlserver.yml index 3450a9d55a..f317563ae8 100644 --- a/manager/src/main/resources/define/app-sqlserver.yml +++ b/manager/src/main/resources/define/app-sqlserver.yml @@ -156,15 +156,15 @@ params: # 是否隐藏字段 true or false hide: true # collect metrics config list -# 采集指标组配置列表 +# 采集指标配置列表 metrics: # metrics - basic - # 监控指标组 - basic + # 监控指标 - basic - name: basic - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue - # 指标组调度优先级(0->127)->(优先级高->低) 优先级低的指标组会等优先级高的指标组采集完成后才会被调度, 相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # 指标采集调度优先级(0->127)->(优先级高->低) 优先级低的指标会等优先级高的指标采集完成后才会被调度, 相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 0 # collect metrics content # 具体监控指标列表 diff --git a/manager/src/main/resources/define/app-ssl_cert.yml b/manager/src/main/resources/define/app-ssl_cert.yml index a5cf620e43..fa3ea22656 100644 --- a/manager/src/main/resources/define/app-ssl_cert.yml +++ b/manager/src/main/resources/define/app-ssl_cert.yml @@ -94,15 +94,15 @@ params: # 是否隐藏字段 true or false hide: true # collect metrics config list -# 采集指标组配置列表 +# 采集指标配置列表 metrics: # metrics - certificate - # 监控指标组 - certificate + # 监控指标 - certificate - name: certificate - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue - # 指标组调度优先级(0->127)->(优先级高->低) 优先级低的指标组会等优先级高的指标组采集完成后才会被调度, 相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # 指标采集调度优先级(0->127)->(优先级高->低) 优先级低的指标会等优先级高的指标采集完成后才会被调度, 相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 0 # collect metrics content # 具体监控指标列表 diff --git a/manager/src/main/resources/define/app-tidb.yml b/manager/src/main/resources/define/app-tidb.yml index 9fd9e9861e..e03e454ca0 100644 --- a/manager/src/main/resources/define/app-tidb.yml +++ b/manager/src/main/resources/define/app-tidb.yml @@ -130,15 +130,15 @@ params: required: false hide: true # collect metrics config list -# 采集指标组配置列表 +# 采集指标配置列表 metrics: # metrics - status - # 监控指标组 - status + # 监控指标 - status - name: status - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue - # 指标组调度优先级(0->127)->(优先级高->低) 优先级低的指标组会等优先级高的指标组采集完成后才会被调度, 相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # 指标采集调度优先级(0->127)->(优先级高->低) 优先级低的指标会等优先级高的指标采集完成后才会被调度, 相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 0 # collect metrics content # 具体监控指标列表 @@ -229,10 +229,10 @@ metrics: parseScript: '$.stores.*' - name: basic - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue - # 指标组调度优先级(0->127)->(优先级高->低) 优先级低的指标组会等优先级高的指标组采集完成后才会被调度, 相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # 指标采集调度优先级(0->127)->(优先级高->低) 优先级低的指标会等优先级高的指标采集完成后才会被调度, 相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 2 # collect metrics content # 具体监控指标列表 diff --git a/manager/src/main/resources/define/app-tomcat.yml b/manager/src/main/resources/define/app-tomcat.yml index e2f23c0cdc..39bc716524 100644 --- a/manager/src/main/resources/define/app-tomcat.yml +++ b/manager/src/main/resources/define/app-tomcat.yml @@ -128,15 +128,15 @@ params: # 是否隐藏字段 true or false hide: true # collect metrics config list -# 采集指标组配置列表 +# 采集指标配置列表 metrics: # metrics - server - # 监控指标组 - server + # 监控指标 - server - name: server - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue - # 指标组调度优先级(0->127)->(优先级高->低) 优先级低的指标组会等优先级高的指标组采集完成后才会被调度, 相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # 指标采集调度优先级(0->127)->(优先级高->低) 优先级低的指标会等优先级高的指标采集完成后才会被调度, 相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 0 # collect metrics content # 具体监控指标列表 diff --git a/manager/src/main/resources/define/app-tplink_switch.yml b/manager/src/main/resources/define/app-tplink_switch.yml index edbdd01d6b..c84c5ce10e 100644 --- a/manager/src/main/resources/define/app-tplink_switch.yml +++ b/manager/src/main/resources/define/app-tplink_switch.yml @@ -135,15 +135,15 @@ params: # 默认值 defaultValue: 6000 # collect metrics config list -# 采集指标组配置列表 +# 采集指标配置列表 metrics: # metrics - system - # 监控指标组 - system + # 监控指标 - system - name: system - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue - # 指标组调度优先级(0->127)->(优先级高->低) 优先级低的指标组会等优先级高的指标组采集完成后才会被调度, 相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # 指标采集调度优先级(0->127)->(优先级高->低) 优先级低的指标会等优先级高的指标采集完成后才会被调度, 相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 0 # collect metrics content # 具体监控指标列表 diff --git a/manager/src/main/resources/define/app-ubuntu.yml b/manager/src/main/resources/define/app-ubuntu.yml index 5bf51762be..f3cc2f5bc5 100644 --- a/manager/src/main/resources/define/app-ubuntu.yml +++ b/manager/src/main/resources/define/app-ubuntu.yml @@ -155,19 +155,18 @@ params: # 是否隐藏字段 true or false hide: true # collect metrics config list -# 采集指标组配置列表 +# 采集指标配置列表 metrics: # metrics - basic, inner monitoring metrics (responseTime - response time) - # 监控指标组 - basic, 内置监控指标有 (responseTime - 响应时间) + # 监控指标 - basic, 内置监控指标有 (responseTime - 响应时间) - name: basic i18n: zh-CN: 系统基本信息 en-US: Basic Info - # 指标组调度优先级(0-127)越小优先级越高,优先级低的指标组会等优先级高的指标组采集完成后才会被调度,相同优先级的指标组会并行调度采集 - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue - # 指标组调度优先级(0->127)->(优先级高->低) 优先级低的指标组会等优先级高的指标组采集完成后才会被调度, 相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # 指标采集调度优先级(0->127)->(优先级高->低) 优先级低的指标会等优先级高的指标采集完成后才会被调度, 相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 0 # collect metrics content # 具体监控指标列表 diff --git a/manager/src/main/resources/define/app-udp_port.yml b/manager/src/main/resources/define/app-udp_port.yml index 115035c6ae..f5118c5555 100644 --- a/manager/src/main/resources/define/app-udp_port.yml +++ b/manager/src/main/resources/define/app-udp_port.yml @@ -99,15 +99,15 @@ params: placeholder: 3025020101040 required: false # collect metrics config list -# 采集指标组配置列表 +# 采集指标配置列表 metrics: # metrics - summary - # 监控指标组 - summary + # 监控指标 - summary - name: summary - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue - # 指标组调度优先级(0->127)->(优先级高->低) 优先级低的指标组会等优先级高的指标组采集完成后才会被调度, 相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # 指标采集调度优先级(0->127)->(优先级高->低) 优先级低的指标会等优先级高的指标采集完成后才会被调度, 相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 0 # 指标信息 包括 field名称 type字段类型:0-number数字,1-string字符串 label-是否是指标标签字段 unit:指标单位 # field-metric name, type-metric type(0-number,1-string), unit-metric unit('%','ms','MB'), label-whether it is a metrics label field diff --git a/manager/src/main/resources/define/app-website.yml b/manager/src/main/resources/define/app-website.yml index d2fc2da9d6..ba899f6042 100644 --- a/manager/src/main/resources/define/app-website.yml +++ b/manager/src/main/resources/define/app-website.yml @@ -204,13 +204,13 @@ params: hide: true metrics: # metrics - summary, inner monitoring metrics (responseTime - response time, keyword - number of keywords) - # 监控指标组 - summary, 内置监控指标有 (responseTime - 响应时间, keyword - 关键字数量) + # 监控指标 - summary, 内置监控指标有 (responseTime - 响应时间, keyword - 关键字数量) - name: summary - # 指标组调度优先级(0-127)越小优先级越高,优先级低的指标组会等优先级高的指标组采集完成后才会被调度,相同优先级的指标组会并行调度采集 - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue - # 指标组调度优先级(0->127)->(优先级高->低) 优先级低的指标组会等优先级高的指标组采集完成后才会被调度, 相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # 指标调度优先级(0-127)越小优先级越高,优先级低的指标会等优先级高的指标采集完成后才会被调度,相同优先级的指标会并行调度采集 + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # 指标采集调度优先级(0->127)->(优先级高->低) 优先级低的指标会等优先级高的指标采集完成后才会被调度, 相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 0 # collect metrics content # 具体监控指标列表 diff --git a/manager/src/main/resources/define/app-windows.yml b/manager/src/main/resources/define/app-windows.yml index 0709107e54..48019f8c71 100644 --- a/manager/src/main/resources/define/app-windows.yml +++ b/manager/src/main/resources/define/app-windows.yml @@ -135,15 +135,15 @@ params: # 默认值 defaultValue: 6000 # collect metrics config list -# 采集指标组配置列表 +# 采集指标配置列表 metrics: # metrics - system - # 监控指标组 - system + # 监控指标 - system - name: system - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue - # 指标组调度优先级(0->127)->(优先级高->低) 优先级低的指标组会等优先级高的指标组采集完成后才会被调度, 相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # 指标采集调度优先级(0->127)->(优先级高->低) 优先级低的指标会等优先级高的指标采集完成后才会被调度, 相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 0 # collect metrics content # 具体监控指标列表 diff --git a/manager/src/main/resources/define/app-zookeeper.yml b/manager/src/main/resources/define/app-zookeeper.yml index 1f909d73c9..3a56b37ee0 100644 --- a/manager/src/main/resources/define/app-zookeeper.yml +++ b/manager/src/main/resources/define/app-zookeeper.yml @@ -91,15 +91,15 @@ params: # 默认值 defaultValue: 6000 # collect metrics config list -# 采集指标组配置列表 +# 采集指标配置列表 metrics: # metrics - cluster - # 监控指标组 - 集群状态 + # 监控指标 - 集群状态 - name: conf - # metrics group scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel - # priority 0's metrics group is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue - # 指标组调度优先级(0->127)->(优先级高->低) 优先级低的指标组会等优先级高的指标组采集完成后才会被调度, 相同优先级的指标组会并行调度采集 - # 优先级为0的指标组为可用性指标组,即它会被首先调度,采集成功才会继续调度其它指标组,采集失败则中断调度 + # metrics scheduling priority(0->127)->(high->low), metrics with the same priority will be scheduled in parallel + # priority 0's metrics is availability metrics, it will be scheduled first, only availability metrics collect success will the scheduling continue + # 指标采集调度优先级(0->127)->(优先级高->低) 优先级低的指标会等优先级高的指标采集完成后才会被调度, 相同优先级的指标会并行调度采集 + # 优先级为0的指标为可用性指标,即它会被首先调度,采集成功才会继续调度其它指标,采集失败则中断调度 priority: 0 # collect metrics content # 具体监控指标列表 diff --git a/pom.xml b/pom.xml index 0aad63104c..0dbecb004e 100644 --- a/pom.xml +++ b/pom.xml @@ -45,7 +45,6 @@ 5.2.7 2.8.9 32.0.0-jre - 0.5.11 3.19.4 3.1.648 2.9.3 diff --git a/warehouse/src/main/java/org/dromara/hertzbeat/warehouse/controller/MetricsDataController.java b/warehouse/src/main/java/org/dromara/hertzbeat/warehouse/controller/MetricsDataController.java index 0ef10781bb..3dbd5fa75d 100644 --- a/warehouse/src/main/java/org/dromara/hertzbeat/warehouse/controller/MetricsDataController.java +++ b/warehouse/src/main/java/org/dromara/hertzbeat/warehouse/controller/MetricsDataController.java @@ -111,7 +111,7 @@ public class MetricsDataController { } { MetricsData.MetricsDataBuilder dataBuilder = MetricsData.builder(); - dataBuilder.id(storageData.getId()).app(storageData.getApp()).metric(storageData.getMetrics()) + dataBuilder.id(storageData.getId()).app(storageData.getApp()).metrics(storageData.getMetrics()) .time(storageData.getTime()); List fields = storageData.getFieldsList().stream().map(tmpField -> Field.builder().name(tmpField.getName()) @@ -145,14 +145,14 @@ public class MetricsDataController { } @GetMapping("/api/monitor/{monitorId}/metric/{metricFull}") - @Operation(summary = "查询监控指标组的指定指标的历史数据", description = "查询监控指标组下的指定指标的历史数据") + @Operation(summary = "查询监控的指定指标的历史数据", description = "查询监控下的指定指标的历史数据") public ResponseEntity> getMetricHistoryData( @Parameter(description = "监控任务ID", example = "343254354") @PathVariable Long monitorId, @Parameter(description = "监控指标全路径", example = "linux.cpu.usage") @PathVariable() String metricFull, - @Parameter(description = "所属实例,默认空", example = "disk2") - @RequestParam(required = false) String instance, + @Parameter(description = "标签过滤,默认空", example = "disk2") + @RequestParam(required = false) String label, @Parameter(description = "查询历史时间段,默认6h-6小时:s-秒、m-分, h-小时, d-天, w-周", example = "6h") @RequestParam(required = false) String history, @Parameter(description = "是否计算聚合数据,需查询时间段大于1周以上,默认不开启,聚合降样时间窗口默认为4小时", example = "false") @@ -183,12 +183,12 @@ public class MetricsDataController { } Map> instanceValuesMap; if (interval == null || !interval) { - instanceValuesMap = historyDataStorage.getHistoryMetricData(monitorId, app, metrics, metric, instance, history); + instanceValuesMap = historyDataStorage.getHistoryMetricData(monitorId, app, metrics, metric, label, history); } else { - instanceValuesMap = historyDataStorage.getHistoryIntervalMetricData(monitorId, app, metrics, metric, instance, history); + instanceValuesMap = historyDataStorage.getHistoryIntervalMetricData(monitorId, app, metrics, metric, label, history); } MetricsHistoryData historyData = MetricsHistoryData.builder() - .id(monitorId).metric(metrics).values(instanceValuesMap) + .id(monitorId).metrics(metrics).values(instanceValuesMap) .field(Field.builder().name(metric).type(CommonConstants.TYPE_NUMBER).build()) .build(); return ResponseEntity.ok(Message.success(historyData)); diff --git a/warehouse/src/main/java/org/dromara/hertzbeat/warehouse/store/AbstractHistoryDataStorage.java b/warehouse/src/main/java/org/dromara/hertzbeat/warehouse/store/AbstractHistoryDataStorage.java index 583dfb6ae4..22ac5a2a48 100644 --- a/warehouse/src/main/java/org/dromara/hertzbeat/warehouse/store/AbstractHistoryDataStorage.java +++ b/warehouse/src/main/java/org/dromara/hertzbeat/warehouse/store/AbstractHistoryDataStorage.java @@ -28,48 +28,47 @@ import java.util.Map; /** * data storage abstract class * - * */ @Slf4j public abstract class AbstractHistoryDataStorage implements DisposableBean { protected boolean serverAvailable; /** - * @return data storage是否可用 + * @return data storage available */ public boolean isServerAvailable() { return serverAvailable; } /** - * 持久化数据 - * @param metricsData 采集数据 + * save metrics data + * @param metricsData metrics data */ abstract void saveData(CollectRep.MetricsData metricsData); /** - * 从时序数据库获取指标历史数据 - * - * @param monitorId 监控任务ID - * @param app 监控类型 - * @param metrics 指标集合名 - * @param metric 指标名 - * @param label 标签 - * @param history 历史范围 - * @return 指标历史数据列表 + * query history range metrics data from tsdb + * @param monitorId monitor id + * @param app monitor type + * @param metrics metrics + * @param metric metric + * @param label label + * @param history range + * @return metrics data */ public abstract Map> getHistoryMetricData( Long monitorId, String app, String metrics, String metric, String label, String history); /** - * 从时序数据库获取指标历史间隔数据 平均值 最大值 最小值 - * @param monitorId 监控任务ID - * @param app 监控类型 - * @param metrics 指标集合名 - * @param metric 指标名 - * @param label 标签 - * @param history 历史范围 - * @return 指标历史数据列表 + * query history range interval metrics data from tsdb + * max min mean metrics value + * @param monitorId monitor id + * @param app monitor type + * @param metrics metrics + * @param metric metric + * @param label label + * @param history history range + * @return metrics data */ public abstract Map> getHistoryIntervalMetricData( Long monitorId, String app, String metrics, String metric, String label, String history); diff --git a/warehouse/src/main/java/org/dromara/hertzbeat/warehouse/store/HistoryJpaDatabaseDataStorage.java b/warehouse/src/main/java/org/dromara/hertzbeat/warehouse/store/HistoryJpaDatabaseDataStorage.java index a810dbd63f..3ff50eb5d0 100644 --- a/warehouse/src/main/java/org/dromara/hertzbeat/warehouse/store/HistoryJpaDatabaseDataStorage.java +++ b/warehouse/src/main/java/org/dromara/hertzbeat/warehouse/store/HistoryJpaDatabaseDataStorage.java @@ -168,18 +168,7 @@ public class HistoryJpaDatabaseDataStorage extends AbstractHistoryDataStorage { log.error(e.getMessage(), e); } } - - /** - * 从数据库获取指标历史数据 - * - * @param monitorId 监控任务ID - * @param app 监控类型 - * @param metrics 指标集合名 - * @param metric 指标名 - * @param label 实例 - * @param history 历史范围 - * @return 指标历史数据列表 - */ + @Override public Map> getHistoryMetricData(Long monitorId, String app, String metrics, String metric, String label, String history) { Map> instanceValuesMap = new HashMap<>(8); diff --git a/warehouse/src/main/java/org/dromara/hertzbeat/warehouse/store/HistoryTdEngineDataStorage.java b/warehouse/src/main/java/org/dromara/hertzbeat/warehouse/store/HistoryTdEngineDataStorage.java index ffc956aa11..b296eccd4a 100644 --- a/warehouse/src/main/java/org/dromara/hertzbeat/warehouse/store/HistoryTdEngineDataStorage.java +++ b/warehouse/src/main/java/org/dromara/hertzbeat/warehouse/store/HistoryTdEngineDataStorage.java @@ -231,18 +231,7 @@ public class HistoryTdEngineDataStorage extends AbstractHistoryDataStorage { hikariDataSource.close(); } } - - /** - * 从TD ENGINE时序数据库获取指标历史数据 - * - * @param monitorId 监控任务ID - * @param app 监控类型 - * @param metrics 指标集合名 - * @param metric 指标名 - * @param label 实例 - * @param history 历史范围 - * @return 指标历史数据列表 - */ + @Override public Map> getHistoryMetricData(Long monitorId, String app, String metrics, String metric, String label, String history) { String table = app + "_" + metrics + "_" + monitorId; diff --git a/warehouse/src/main/java/org/dromara/hertzbeat/warehouse/store/HistoryVictoriaMetricsDataStorage.java b/warehouse/src/main/java/org/dromara/hertzbeat/warehouse/store/HistoryVictoriaMetricsDataStorage.java index 807d9aee87..668cdeebe8 100644 --- a/warehouse/src/main/java/org/dromara/hertzbeat/warehouse/store/HistoryVictoriaMetricsDataStorage.java +++ b/warehouse/src/main/java/org/dromara/hertzbeat/warehouse/store/HistoryVictoriaMetricsDataStorage.java @@ -54,7 +54,6 @@ import java.util.stream.Collectors; /** * tdengine data storage * - * */ @Primary @Component @@ -189,18 +188,7 @@ public class HistoryVictoriaMetricsDataStorage extends AbstractHistoryDataStorag @Override public void destroy() {} - - /** - * 从TD ENGINE时序数据库获取指标历史数据 - * - * @param monitorId 监控任务ID - * @param app 监控类型 - * @param metrics 指标集合名 - * @param metric 指标名 - * @param label 实例 - * @param history 历史范围 - * @return 指标历史数据列表 - */ + @Override public Map> getHistoryMetricData(Long monitorId, String app, String metrics, String metric, String label, String history) { String timeSeriesSelector = NAME_KEY + "=\"" + app + SPILT + metrics + SPILT + metric + "\"" + diff --git a/warehouse/src/test/java/org/dromara/hertzbeat/warehouse/controller/MetricsDataControllerTest.java b/warehouse/src/test/java/org/dromara/hertzbeat/warehouse/controller/MetricsDataControllerTest.java index 71618eda71..e919f90753 100644 --- a/warehouse/src/test/java/org/dromara/hertzbeat/warehouse/controller/MetricsDataControllerTest.java +++ b/warehouse/src/test/java/org/dromara/hertzbeat/warehouse/controller/MetricsDataControllerTest.java @@ -104,7 +104,7 @@ class MetricsDataControllerTest { .andExpect(jsonPath("$.code").value((int) CommonConstants.SUCCESS_CODE)) .andExpect(jsonPath("$.msg").isEmpty()) .andExpect(jsonPath("$.data.id").value(monitorId)) - .andExpect(jsonPath("$.data.metric").value(metric)) + .andExpect(jsonPath("$.data.metrics").value(metric)) .andExpect(jsonPath("$.data.app").value(app)) .andExpect(jsonPath("$.data.time").value(time)) .andReturn(); @@ -160,7 +160,7 @@ class MetricsDataControllerTest { .andExpect(status().isOk()) .andExpect(jsonPath("$.code").value((int) CommonConstants.SUCCESS_CODE)) .andExpect(jsonPath("$.data.id").value(monitorId)) - .andExpect(jsonPath("$.data.metric").value(metrics)) + .andExpect(jsonPath("$.data.metrics").value(metrics)) .andExpect(jsonPath("$.data.field.name").value(metric)) .andExpect(jsonPath("$.data.field.type").value(String.valueOf(CommonConstants.TYPE_NUMBER))) .andExpect(jsonPath("$.msg").isEmpty()) diff --git a/web-app/src/app/routes/alert/alert-notice/alert-notice.component.html b/web-app/src/app/routes/alert/alert-notice/alert-notice.component.html index 9e567c9a65..ee6b9c7d41 100644 --- a/web-app/src/app/routes/alert/alert-notice/alert-notice.component.html +++ b/web-app/src/app/routes/alert/alert-notice/alert-notice.component.html @@ -383,6 +383,7 @@ name="templates" nzPlaceHolder="Select a template" nzShowSearch + nzAllowClear > diff --git a/web-app/src/app/routes/dashboard/ColorTheme.ts b/web-app/src/app/routes/dashboard/ColorTheme.ts index ed2be8cb71..fc553a25b1 100644 --- a/web-app/src/app/routes/dashboard/ColorTheme.ts +++ b/web-app/src/app/routes/dashboard/ColorTheme.ts @@ -22,10 +22,10 @@ export const CoolTheme: ThemeOption = { tooltip: { backgroundColor: 'rgba(0,0,0,0.5)', axisPointer: { - // Axis indicator, coordinate trigger effective + // Axis metric, coordinate trigger effective type: 'line', // The default is a straight line: 'line' | 'shadow' lineStyle: { - // Straight line indicator style settings + // Straight line metric style settings color: '#00aecd', type: 'dashed' }, @@ -33,7 +33,7 @@ export const CoolTheme: ThemeOption = { color: '#00aecd' }, shadowStyle: { - // Shadow indicator style settings + // Shadow metric style settings color: 'rgba(200,200,200,0.3)' } } diff --git a/web-app/src/app/routes/monitor/monitor-detail/monitor-detail.component.ts b/web-app/src/app/routes/monitor/monitor-detail/monitor-detail.component.ts index 29dd52e8c4..accb8d4627 100644 --- a/web-app/src/app/routes/monitor/monitor-detail/monitor-detail.component.ts +++ b/web-app/src/app/routes/monitor/monitor-detail/monitor-detail.component.ts @@ -116,7 +116,6 @@ export class MonitorDetailComponent implements OnInit, OnDestroy { this.isSpinning = true; let id = paramMap.get('monitorId'); this.monitorId = Number(id); - // 查询监控指标组结构信息 return this.monitorSvc.getMonitor(this.monitorId); }) ) diff --git a/web-app/src/assets/i18n/zh-CN.json b/web-app/src/assets/i18n/zh-CN.json index cfa21fe3c9..f38c9e54aa 100644 --- a/web-app/src/assets/i18n/zh-CN.json +++ b/web-app/src/assets/i18n/zh-CN.json @@ -266,6 +266,7 @@ "alert.notice.type.ding": "钉钉机器人", "alert.notice.type.fei-shu": "飞书机器人", "alert.notice.type.fei-shu-key": "飞书机器人KEY", + "alert.notice.type.telegram": "Telegram", "alert.notice.type.telegram-bot": "Telegram机器人", "alert.notice.type.telegram-bot-token": "Telegram Bot Token", "alert.notice.type.telegram-bot-user-id": "Telegram User Id", @@ -281,7 +282,6 @@ "alert.notice.type.smn": "华为云SMN", "alert.notice.type.smn-ak": "AK", "alert.notice.type.smn-sk": "SK", - "alert.notice.type.telegram": "Telegram", "alert.notice.type.smn-projectId": "项目ID", "alert.notice.type.smn-region": "地域", "alert.notice.type.smn-topicUrn": "TopicUrn",