Skip to content

Commit

Permalink
[improve] update and fix template yml priority (#2829)
Browse files Browse the repository at this point in the history
Signed-off-by: tomsun28 <[email protected]>
Co-authored-by: Logic <[email protected]>
  • Loading branch information
tomsun28 and zqr10159 authored Nov 24, 2024
1 parent bd937bf commit f0cb2af
Show file tree
Hide file tree
Showing 57 changed files with 290 additions and 288 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -171,6 +171,7 @@ private Statement getConnection(String username, String password, String url, In
}
// renew connection when failed
Connection connection = DriverManager.getConnection(url, username, password);
connection.setReadOnly(true);
statement = connection.createStatement();
int timeoutSecond = timeout / 1000;
timeoutSecond = timeoutSecond <= 0 ? 1 : timeoutSecond;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -143,6 +143,7 @@ public Optional<C> getCache(T key, boolean refreshCache) {
Long[] cacheTime = timeoutMap.get(key);
if (cacheTime == null || cacheTime.length != CACHE_TIME_LENGTH) {
log.info("[connection common cache] not hit the cache, key {}.", key);
removeCache(key);
return Optional.empty();
}
if (cacheTime[0] + cacheTime[1] < System.currentTimeMillis()) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ params:
type: boolean
# required-true or false
required: true
defaultValue: false
defaultValue: true
# field-param field key
- field: username
# name-param field display i18n name
Expand Down
2 changes: 1 addition & 1 deletion hertzbeat-manager/src/main/resources/define/app-centos.yml
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@ params:
type: boolean
# required-true or false
required: true
defaultValue: false
defaultValue: true
# field-param field key
- field: username
# name-param field display i18n name
Expand Down
2 changes: 1 addition & 1 deletion hertzbeat-manager/src/main/resources/define/app-coreos.yml
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ params:
type: boolean
# required-true or false
required: true
defaultValue: false
defaultValue: true
# field-param field key
- field: username
# name-param field display i18n name
Expand Down
2 changes: 1 addition & 1 deletion hertzbeat-manager/src/main/resources/define/app-debian.yml
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ params:
type: boolean
# required-true or false
required: true
defaultValue: false
defaultValue: true
# field-param field key
- field: username
# name-param field display i18n name
Expand Down
8 changes: 4 additions & 4 deletions hertzbeat-manager/src/main/resources/define/app-dns.yml
Original file line number Diff line number Diff line change
Expand Up @@ -185,7 +185,7 @@ metrics:
en-US: Question
# 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
priority: 1
# field-metric name, type-metric type(0-number,1-string), unit-metric unit('%','ms','MB'), label-whether it is a metrics label field
fields:
- field: section
Expand Down Expand Up @@ -217,7 +217,7 @@ metrics:
en-US: Answer
# 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
priority: 2
# field-metric name, type-metric type(0-number,1-string), unit-metric unit('%','ms','MB'), label-whether it is a metrics label field
fields:
- field: section0
Expand Down Expand Up @@ -294,7 +294,7 @@ metrics:
en-US: Authority
# 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
priority: 3
# field-metric name, type-metric type(0-number,1-string), unit-metric unit('%','ms','MB'), label-whether it is a metrics label field
fields:
- field: section0
Expand Down Expand Up @@ -371,7 +371,7 @@ metrics:
en-US: Additional
# 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
priority: 4
# field-metric name, type-metric type(0-number,1-string), unit-metric unit('%','ms','MB'), label-whether it is a metrics label field
fields:
- field: section0
Expand Down
46 changes: 23 additions & 23 deletions hertzbeat-manager/src/main/resources/define/app-doris_be.yml
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@ metrics:
i18n:
zh-CN: Memtable 刷新总数
en-US: Memtable Flush Total
priority: 0
priority: 1
fields:
- field: value
type: 0
Expand All @@ -99,7 +99,7 @@ metrics:
i18n:
zh-CN: Plan Fragment 数量
en-US: Plan Fragment Count
priority: 0
priority: 2
fields:
- field: value
type: 0
Expand All @@ -116,7 +116,7 @@ metrics:
i18n:
zh-CN: 进程线程数
en-US: Process Thread Num
priority: 0
priority: 3
fields:
- field: value
type: 0
Expand All @@ -133,7 +133,7 @@ metrics:
i18n:
zh-CN: 查询扫描行数
en-US: Query Scan Rows
priority: 0
priority: 4
fields:
- field: value
type: 0
Expand All @@ -150,7 +150,7 @@ metrics:
i18n:
zh-CN: 结果缓冲区块数
en-US: Result Buffer Block Count
priority: 0
priority: 5
fields:
- field: value
type: 0
Expand All @@ -167,7 +167,7 @@ metrics:
i18n:
zh-CN: 批量发送线程池队列大小
en-US: Send Batch Thread Pool Queue Size
priority: 0
priority: 6
fields:
- field: value
type: 0
Expand All @@ -184,7 +184,7 @@ metrics:
i18n:
zh-CN: Tablet Base 最大压缩分数
en-US: Tablet Base Max Compaction Score
priority: 0
priority: 7
fields:
- field: value
type: 0
Expand All @@ -201,7 +201,7 @@ metrics:
i18n:
zh-CN: 超时取消的 Fragment 数量
en-US: Timeout Canceled Fragment Count
priority: 0
priority: 8
fields:
- field: value
type: 0
Expand All @@ -218,7 +218,7 @@ metrics:
i18n:
zh-CN: 加载行数
en-US: Load Rows
priority: 0
priority: 9
fields:
- field: value
type: 0
Expand All @@ -235,7 +235,7 @@ metrics:
i18n:
zh-CN: Rowset 总数
en-US: All Rowsets Num
priority: 0
priority: 10
fields:
- field: value
type: 0
Expand All @@ -252,7 +252,7 @@ metrics:
i18n:
zh-CN: Segment 总数
en-US: All Segments Num
priority: 0
priority: 11
fields:
- field: value
type: 0
Expand All @@ -269,7 +269,7 @@ metrics:
i18n:
zh-CN: 繁重工作最大线程数
en-US: Heavy Work Max Threads
priority: 0
priority: 12
fields:
- field: value
type: 0
Expand All @@ -286,7 +286,7 @@ metrics:
i18n:
zh-CN: 轻量工作最大线程数
en-US: Light Work Max Threads
priority: 0
priority: 13
fields:
- field: value
type: 0
Expand All @@ -303,7 +303,7 @@ metrics:
i18n:
zh-CN: 繁重工作池队列大小
en-US: Heavy Work Pool Queue Size
priority: 0
priority: 14
fields:
- field: value
type: 0
Expand All @@ -320,7 +320,7 @@ metrics:
i18n:
zh-CN: 轻量工作池队列大小
en-US: Light Work Pool Queue Size
priority: 0
priority: 15
fields:
- field: value
type: 0
Expand All @@ -337,7 +337,7 @@ metrics:
i18n:
zh-CN: 繁重工作活跃线程数
en-US: Heavy Work Active Threads
priority: 0
priority: 16
fields:
- field: value
type: 0
Expand All @@ -354,7 +354,7 @@ metrics:
i18n:
zh-CN: 轻量工作活跃线程数
en-US: Light Work Active Threads
priority: 0
priority: 17
fields:
- field: value
type: 0
Expand All @@ -371,7 +371,7 @@ metrics:
i18n:
zh-CN: 压缩字节总数
en-US: Compaction Bytes Total
priority: 0
priority: 18
fields:
- field: type
type: 1
Expand All @@ -391,7 +391,7 @@ metrics:
i18n:
zh-CN: 磁盘可用容量
en-US: Disks Avail Capacity
priority: 0
priority: 19
fields:
- field: path
type: 1
Expand All @@ -411,7 +411,7 @@ metrics:
i18n:
zh-CN: 磁盘总容量
en-US: Disks Total Capacity
priority: 0
priority: 20
fields:
- field: path
type: 1
Expand All @@ -431,7 +431,7 @@ metrics:
i18n:
zh-CN: 本地读取字节总数
en-US: Local Bytes Read Total
priority: 0
priority: 21
fields:
- field: value
type: 0
Expand All @@ -449,7 +449,7 @@ metrics:
i18n:
zh-CN: 本地写入字节总数
en-US: Local Bytes Written Total
priority: 0
priority: 22
fields:
- field: value
type: 0
Expand All @@ -467,7 +467,7 @@ metrics:
i18n:
zh-CN: 内存分配字节
en-US: Memory Allocated Bytes
priority: 0
priority: 23
fields:
- field: value
type: 0
Expand Down
Loading

0 comments on commit f0cb2af

Please sign in to comment.