Skip to content

Commit 5162b99

Browse files
authored
Merge pull request #155 from dromara/dev
Dev
2 parents fbf4299 + 2634364 commit 5162b99

File tree

183 files changed

+496
-613
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

183 files changed

+496
-613
lines changed

.env.example

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,8 @@ SPRING_PROFILES_ACTIVE=prod
66
DEMO_MODE=false
77

88
API_CORS=true
9+
API_HOST=0.0.0.0
10+
# API_URL=http://127.0.0.1:9700/orion-visor/api
911
API_IP_HEADERS=X-Forwarded-For,X-Real-IP
1012
API_EXPOSE_TOKEN=pmqeHOyZaumHm0Wt
1113
SECRET_KEY=uQeacXV8b3isvKLK

.github/ISSUE_TEMPLATE/bug_report.yaml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,8 @@ body:
1717
required: true
1818
- label: 我已搜索 [issue](https://github.com/dromara/orion-visor/issues) 并没有找到相关问题
1919
required: true
20+
- label: 我已 star 了此项目, 否则可能会被自动关闭
21+
required: true
2022
- type: input
2123
id: version
2224
attributes:

docker-compose.yaml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
version: '3.3'
22

3-
# latest = 2.5.5
3+
# latest = 2.5.6
44

55
# 支持以下源
66
# lijiahangmax/*
@@ -50,6 +50,7 @@ services:
5050
SECRET_KEY: ${SECRET_KEY:-uQeacXV8b3isvKLK}
5151
API_EXPOSE_TOKEN: ${API_EXPOSE_TOKEN:-pmqeHOyZaumHm0Wt}
5252
API_IP_HEADERS: ${API_IP_HEADERS:-X-Forwarded-For,X-Real-IP}
53+
API_HOST: ${API_HOST:-0.0.0.0}
5354
API_CORS: ${API_CORS:-true}
5455
DEMO_MODE: ${DEMO_MODE:-false}
5556
volumes:

docker/docker-build.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ set -e
77
source ./project-build.sh "$@"
88

99
# 版本号
10-
version=2.5.5
10+
version=2.5.6
1111
# 是否推送镜像
1212
push_image=false
1313
# 是否构建 latest

docker/project-build.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ set -e
44
# DockerContext: orion-visor
55

66
# 版本号
7-
version=2.5.5
7+
version=2.5.6
88
# 是否构建 service
99
export build_service=false
1010
# 是否构建 ui

orion-visor-common/src/main/java/org/dromara/visor/common/constant/AppConst.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ public interface AppConst extends OrionConst {
3636
/**
3737
* 同 ${orion.version} 迭代时候需要手动更改
3838
*/
39-
String VERSION = "2.5.5";
39+
String VERSION = "2.5.6";
4040

4141
/**
4242
* 同 ${spring.application.name}

orion-visor-common/src/main/java/org/dromara/visor/common/constant/Const.java

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -55,4 +55,6 @@ public interface Const extends cn.orionsec.kit.lang.constant.Const, FieldConst,
5555

5656
int BATCH_COUNT = 500;
5757

58+
String IP_0000 = "0.0.0.0";
59+
5860
}

orion-visor-common/src/main/java/org/dromara/visor/common/constant/ErrorMessage.java

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -210,6 +210,10 @@ public interface ErrorMessage {
210210

211211
String PLEASE_SELECT_SUFFIX_FILE = "请选择 {} 类型的文件";
212212

213+
String SPEC_FORMAT_INCORRECT = "规格格式不正确";
214+
215+
String INFLUXDB_UNSUPPORTED = "InfluxDB 服务未开启";
216+
213217
/**
214218
* 是否为业务异常
215219
*

orion-visor-dependencies/pom.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@
1414
<url>https://github.com/dromara/orion-visor</url>
1515

1616
<properties>
17-
<revision>2.5.5</revision>
17+
<revision>2.5.6</revision>
1818
<spring.boot.version>2.7.17</spring.boot.version>
1919
<spring.boot.admin.version>2.7.15</spring.boot.admin.version>
2020
<flatten.maven.plugin.version>1.5.0</flatten.maven.plugin.version>

orion-visor-framework/orion-visor-spring-boot-starter-influxdb/src/main/java/org/dromara/visor/framework/influxdb/core/utils/InfluxdbUtils.java

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,9 @@
3030
import com.influxdb.query.FluxRecord;
3131
import com.influxdb.query.FluxTable;
3232
import org.dromara.visor.common.constant.Const;
33+
import org.dromara.visor.common.constant.ErrorMessage;
3334
import org.dromara.visor.common.entity.chart.TimeChartSeries;
35+
import org.dromara.visor.common.utils.Assert;
3436
import org.dromara.visor.framework.influxdb.core.query.FluxQueryBuilder;
3537

3638
import java.time.Instant;
@@ -66,6 +68,7 @@ private InfluxdbUtils() {
6668
* @param points points
6769
*/
6870
public static void writePoints(List<Point> points) {
71+
Assert.notNull(client, ErrorMessage.INFLUXDB_UNSUPPORTED);
6972
try (WriteApi api = client.makeWriteApi()) {
7073
// 写入指标
7174
api.writePoints(points);
@@ -79,6 +82,7 @@ public static void writePoints(List<Point> points) {
7982
* @return points
8083
*/
8184
public static List<FluxTable> queryTable(String query) {
85+
Assert.notNull(client, ErrorMessage.INFLUXDB_UNSUPPORTED);
8286
return client.getQueryApi().query(query);
8387
}
8488

0 commit comments

Comments
 (0)