commit e3e2c0566ab7e8d9e7b264a3070a52f0364967a9
Author: whq <460794335@qq.com>
Date: Tue Mar 21 15:11:58 2023 +0800
初始化项目
diff --git a/.editorconfig b/.editorconfig
new file mode 100644
index 0000000..8cfd370
--- /dev/null
+++ b/.editorconfig
@@ -0,0 +1,21 @@
+# http://editorconfig.org
+root = true
+
+# 空格替代Tab缩进在各种编辑工具下效果一致
+[*]
+indent_style = space
+indent_size = 4
+charset = utf-8
+end_of_line = lf
+trim_trailing_whitespace = true
+insert_final_newline = true
+
+[*.java]
+indent_style = tab
+
+[*.{json,yml}]
+indent_size = 2
+
+[*.md]
+insert_final_newline = false
+trim_trailing_whitespace = false
diff --git a/.gitignore b/.gitignore
new file mode 100644
index 0000000..30e19fb
--- /dev/null
+++ b/.gitignore
@@ -0,0 +1,28 @@
+# maven #
+target
+
+logs
+
+# windows #
+Thumbs.db
+
+# Mac #
+.DS_Store
+
+# eclipse #
+.settings
+.project
+.classpath
+.log
+*.class
+
+# idea #
+.idea
+*.iml
+.flattened-pom.xml
+
+# Package Files #
+*.jar
+*.war
+*.ear
+/target
diff --git a/README.md b/README.md
new file mode 100644
index 0000000..58b0269
--- /dev/null
+++ b/README.md
@@ -0,0 +1,3 @@
+## VoRDM平台
+
+## 模块说明
diff --git a/kn-common/pom.xml b/kn-common/pom.xml
new file mode 100644
index 0000000..137f225
--- /dev/null
+++ b/kn-common/pom.xml
@@ -0,0 +1,57 @@
+
+
+
+ com.kening.platform
+ kn-vordm
+ ${revision}
+
+ 4.0.0
+
+ kn-common
+ ${project.artifactId}
+ ${revision}
+ jar
+
+
+
+ io.swagger
+ swagger-annotations
+ 1.6.2
+
+
+ org.springblade
+ blade-starter-ribbon
+
+
+ org.springblade
+ blade-core-auto
+ provided
+
+
+ org.springblade
+ blade-core-tool
+
+
+ swagger-annotations
+ io.swagger
+
+
+
+
+
+
+
+
+ org.springframework.boot
+ spring-boot-maven-plugin
+
+ true
+ ${project.name}
+
+
+
+
+
+
diff --git a/kn-common/src/main/java/org/springblade/common/cache/CacheNames.java b/kn-common/src/main/java/org/springblade/common/cache/CacheNames.java
new file mode 100644
index 0000000..eecea67
--- /dev/null
+++ b/kn-common/src/main/java/org/springblade/common/cache/CacheNames.java
@@ -0,0 +1,65 @@
+/*
+ * Copyright (c) 2018-2028, Chill Zhuang All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions are met:
+ *
+ * Redistributions of source code must retain the above copyright notice,
+ * this list of conditions and the following disclaimer.
+ * Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in the
+ * documentation and/or other materials provided with the distribution.
+ * Neither the name of the dreamlu.net developer nor the names of its
+ * contributors may be used to endorse or promote products derived from
+ * this software without specific prior written permission.
+ * Author: Chill 庄骞 (smallchill@163.com)
+ */
+package org.springblade.common.cache;
+
+/**
+ * 缓存名
+ *
+ * @author Chill
+ */
+public interface CacheNames {
+
+ /**
+ * 返回拼接后的key
+ *
+ * @param cacheKey 缓存key
+ * @param cacheKeyValue 缓存key值
+ * @return tenantKey
+ */
+ static String cacheKey(String cacheKey, String cacheKeyValue) {
+ return cacheKey.concat(cacheKeyValue);
+ }
+
+ /**
+ * 返回租户格式的key
+ *
+ * @param tenantId 租户编号
+ * @param cacheKey 缓存key
+ * @param cacheKeyValue 缓存key值
+ * @return tenantKey
+ */
+ static String tenantKey(String tenantId, String cacheKey, String cacheKeyValue) {
+ return tenantId.concat(":").concat(cacheKey).concat(cacheKeyValue);
+ }
+
+
+ /**
+ * 短信验证码key
+ */
+ String MOBILE_KEY = "blade:auth::blade:mobile:";
+
+ /**
+ * 验证码key
+ */
+ String CAPTCHA_KEY = "blade:auth::blade:captcha:";
+
+ /**
+ * 登录失败key
+ */
+ String USER_FAIL_KEY = "blade:user::blade:fail:";
+
+}
diff --git a/kn-common/src/main/java/org/springblade/common/config/BladeCommonConfiguration.java b/kn-common/src/main/java/org/springblade/common/config/BladeCommonConfiguration.java
new file mode 100644
index 0000000..345f287
--- /dev/null
+++ b/kn-common/src/main/java/org/springblade/common/config/BladeCommonConfiguration.java
@@ -0,0 +1,12 @@
+package org.springblade.common.config;
+
+import org.springframework.context.annotation.Configuration;
+
+/**
+ * 公共封装包配置类
+ *
+ * @author Chill
+ */
+@Configuration
+public class BladeCommonConfiguration {
+}
diff --git a/kn-common/src/main/java/org/springblade/common/constant/CommonConstant.java b/kn-common/src/main/java/org/springblade/common/constant/CommonConstant.java
new file mode 100644
index 0000000..a8c5697
--- /dev/null
+++ b/kn-common/src/main/java/org/springblade/common/constant/CommonConstant.java
@@ -0,0 +1,56 @@
+package org.springblade.common.constant;
+
+/**
+ * 通用常量
+ *
+ * @author whq
+ */
+public interface CommonConstant {
+
+ /**
+ * 顶级父节点id
+ */
+ Integer TOP_PARENT_ID = 0;
+
+ /**
+ * 顶级父节点名称
+ */
+ String TOP_PARENT_NAME = "顶级";
+
+ /**
+ * 未封存状态值
+ */
+ Integer NOT_SEALED_ID = 0;
+
+ /**
+ * 默认密码
+ */
+ String DEFAULT_PASSWORD = "123456";
+
+ /**
+ * 默认密码参数值
+ */
+ String DEFAULT_PARAM_PASSWORD = "account.initPassword";
+
+ /**
+ * 默认排序字段
+ */
+ String SORT_FIELD = "sort";
+
+ /**
+ * 数据权限类型
+ */
+ Integer DATA_SCOPE_CATEGORY = 1;
+
+ /**
+ * 接口权限类型
+ */
+ Integer API_SCOPE_CATEGORY = 2;
+
+ /**
+ * 对接TB模块的名称
+ */
+ String KN_VORDM_MODULE_NAME = "biz-vordm";
+
+
+}
diff --git a/kn-common/src/main/java/org/springblade/common/constant/TenantConstant.java b/kn-common/src/main/java/org/springblade/common/constant/TenantConstant.java
new file mode 100644
index 0000000..5f6ae79
--- /dev/null
+++ b/kn-common/src/main/java/org/springblade/common/constant/TenantConstant.java
@@ -0,0 +1,66 @@
+/*
+ * Copyright (c) 2018-2028, Chill Zhuang All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions are met:
+ *
+ * Redistributions of source code must retain the above copyright notice,
+ * this list of conditions and the following disclaimer.
+ * Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in the
+ * documentation and/or other materials provided with the distribution.
+ * Neither the name of the dreamlu.net developer nor the names of its
+ * contributors may be used to endorse or promote products derived from
+ * this software without specific prior written permission.
+ * Author: Chill 庄骞 (smallchill@163.com)
+ */
+package org.springblade.common.constant;
+
+import java.util.Arrays;
+import java.util.List;
+
+/**
+ * 租户常量
+ *
+ * @author Chill
+ */
+public interface TenantConstant {
+
+ /**
+ * 租户默认密码KEY
+ */
+ String PASSWORD_KEY = "tenant.default.password";
+
+ /**
+ * 租户默认账号额度KEY
+ */
+ String ACCOUNT_NUMBER_KEY = "tenant.default.accountNumber";
+
+ /**
+ * 租户默认菜单集合KEY
+ */
+ String ACCOUNT_MENU_CODE_KEY = "tenant.default.menuCode";
+
+ /**
+ * 租户默认密码
+ */
+ String DEFAULT_PASSWORD = "123456";
+
+ /**
+ * 租户授权码默认16位密钥
+ */
+ String DES_KEY = "0000000000000000";
+
+ /**
+ * 租户默认账号额度
+ */
+ Integer DEFAULT_ACCOUNT_NUMBER = -1;
+
+ /**
+ * 租户默认菜单集合
+ */
+ List MENU_CODES = Arrays.asList(
+ "desk", "flow", "work", "monitor", "resource", "role", "user", "dept", "dictbiz", "topmenu"
+ );
+
+}
diff --git a/kn-common/src/main/java/org/springblade/common/enums/AlarmEnum.java b/kn-common/src/main/java/org/springblade/common/enums/AlarmEnum.java
new file mode 100644
index 0000000..ae561eb
--- /dev/null
+++ b/kn-common/src/main/java/org/springblade/common/enums/AlarmEnum.java
@@ -0,0 +1,90 @@
+package org.springblade.common.enums;
+
+/**
+ * 事件枚举,报警枚举
+ */
+public enum AlarmEnum {
+// CODE_41 (41,"胁迫报警"),
+// CODE_42 (42,"合法密码开门"),
+// CODE_43 (43,"非法密码开门"),
+// CODE_45 (45,"合法指纹开门"),
+// CODE_46 (46,"非法指纹开门"),
+// CODE_48 (48,"远程开门(室内机/平台),"),
+ CODE_51 (51,"合法刷卡"),
+
+// CODE_52 (52,"非法刷卡"),
+// CODE_53 (53,"门磁报警"),
+// CODE_54 (54,"异常开门"),
+// CODE_55 (55,"异常关门"),
+// CODE_56 (56,"正常关门"),
+// CODE_57 (57,"正常开门"),
+ CODE_61 (61,"合法人脸刷门"),
+// CODE_62 (62,"非法人脸刷门"),
+// CODE_1420 (1420,"超时门未关"),
+// CODE_1430 (1430,"非法闯入"),
+// CODE_1433 (1433,"黑名单报警"),
+// CODE_1434 (1434,"合法二维码开门"),
+// CODE_1435 (1435,"非法二维码开门"),
+// CODE_1436 (1436,"人证合法开门"),
+// CODE_1437 (1437,"人证非法开门"),
+// CODE_1438 (1438,"人证和身份证非法开门"),
+// CODE_1439 (1439,"人证和身份证合法开门"),
+// CODE_1443 (1443,"外部报警"),
+// CODE_1448 (1448,"RFID感应报警"),
+// CODE_1449 (1449,"RFID非法感应报警"),
+// CODE_1450 (1450,"RFID外部报警"),
+// CODE_1455 (1455,"先刷卡后密码合法开门"),
+// CODE_1456 (1456,"先刷卡后密码非法开门"),
+// CODE_1461 (1461,"刷卡+指纹组合合法开门"),
+// CODE_1462 (1462,"刷卡+指纹组合非法开门"),
+// CODE_1463 (1463,"多人合法开门"),
+// CODE_1464 (1464,"多人非法开门"),
+// CODE_1467 (1467,"人员编号+密码合法开门"),
+// CODE_1468 (1468,"人员编号+密码非法开门"),
+// CODE_1469 (1469,"人脸+密码合法开门"),
+// CODE_1470 (1470,"人脸+密码非法开门"),
+// CODE_1471 (1471,"指纹+密码合法开门"),
+// CODE_1472 (1472,"指纹+密码非法开门"),
+// CODE_1473 (1473,"指纹+人脸合法开门"),
+// CODE_1474 (1474,"指纹+人脸非法开门"),
+// CODE_1475 (1475,"刷卡+人脸合法开门"),
+// CODE_1476 (1476,"刷卡+人脸非法开门"),
+// CODE_1487 (1487,"指纹+人脸+密码合法开门"),
+// CODE_1488 (1488,"指纹+人脸+密码非法开门"),
+// CODE_1489 (1489,"刷卡+人脸+密码合法开门"),
+// CODE_1490 (1490,"刷卡+人脸+密码非法开门"),
+// CODE_1491 (1491,"刷卡+指纹+密码合法开门"),
+// CODE_1492 (1492,"刷卡+指纹+密码非法开门"),
+// CODE_1493 (1493,"卡+指纹+人脸合法开门"),
+// CODE_1494 (1494,"卡+指纹+人脸非法开门"),
+// CODE_4603 (4603,"卡+指纹+人脸+密码组合合法开门"),
+// CODE_4604 (4604,"卡+指纹+人脸+密码组合非法开门")
+ CODE_1001005 (1001005 ,"人脸检测"),
+// CODE_1001006 ( 1001006,"人体识别"),
+// CODE_1001004 ( 1001004,"访客报警"),
+// CODE_1001003 (1001003 ,"内部人员报警"),
+ CODE_1001002 (1001002 ,"黑名单库报警"),
+ CODE_1001001 (1001001 ,"白名单库报警"),
+// CODE_1001000 (1001000 ,"陌生人报警"),
+// CODE_1003003 (1003003 ,"访客来访信息下级上报"),
+// CODE_1003002 (1003002 ,"访客区域布控"),
+ CODE_597 (597 ,"离岗报警"),
+ CODE_15670(15670,"睡岗报警"),
+ CODE_16(16,"设备离线"),
+ CODE_15768 (15768 ,"玩手机事件");
+ private int code ;
+ private String msg;
+ AlarmEnum(int code, String msg) {
+ this.code = code ;
+ this.msg = msg;
+ }
+ public static String getValue(int code) {
+ AlarmEnum[] carTypeEnums = values();
+ for (AlarmEnum carTypeEnum : carTypeEnums) {
+ if (carTypeEnum.code==code) {
+ return carTypeEnum.msg;
+ }
+ }
+ return null;
+ }
+}
diff --git a/kn-common/src/main/java/org/springblade/common/enums/BusinessEnum.java b/kn-common/src/main/java/org/springblade/common/enums/BusinessEnum.java
new file mode 100644
index 0000000..f2ba747
--- /dev/null
+++ b/kn-common/src/main/java/org/springblade/common/enums/BusinessEnum.java
@@ -0,0 +1,48 @@
+package org.springblade.common.enums;
+
+/**
+ * 业务处理枚举,针对访客机
+ */
+public enum BusinessEnum {
+ /**
+ * 1。访客 刷访客机,录入访客信息
+ */
+ CODE_THIRD_INFO("visitor.thirdInfo","访客审批"),
+ CODE_VISITOR_STATUS("visitor.status","访客信息变更"),
+ CODE_VISITOR("visitor.record","访客信息");
+ private String code ;
+
+ public String getMsg() {
+ return msg;
+ }
+
+ public void setMsg(String msg) {
+ this.msg = msg;
+ }
+
+ private String msg;
+ public String getCode() {
+ return code;
+ }
+
+ public void setCode(String code) {
+ this.code = code;
+ }
+
+
+ BusinessEnum(String code, String msg) {
+ this.code = code ;
+ this.msg = msg;
+ }
+
+ public static String getValue(String code) {
+ BusinessEnum[] carTypeEnums = values();
+ for (BusinessEnum carTypeEnum : carTypeEnums) {
+ if (carTypeEnum.code.equals(code)) {
+ return carTypeEnum.msg;
+ }
+ }
+ return null;
+ }
+
+}
diff --git a/kn-common/src/main/java/org/springblade/common/utils/CommonUtil.java b/kn-common/src/main/java/org/springblade/common/utils/CommonUtil.java
new file mode 100644
index 0000000..826f87c
--- /dev/null
+++ b/kn-common/src/main/java/org/springblade/common/utils/CommonUtil.java
@@ -0,0 +1,40 @@
+package org.springblade.common.utils;
+
+/**
+ * 通用工具类
+ *
+ * @author Chill
+ */
+public class CommonUtil {
+
+ /**
+ * 通过身份证号获取性别
+ *
+ * @param IdNo String
+ * @return String 男 女
+ */
+ public static String getSexFromId(String IdNo) {
+ try {
+ return (Integer.parseInt(IdNo.substring(16,17)) % 2 == 0 ? "女" : "男");
+ } catch (Exception ignored) {
+ }
+ return "男";
+ }
+
+ /**
+ * 仅用JDK11中的警告
+ */
+ public static void disableWarning() {
+ try {
+ java.lang.reflect.Field theUnsafe = sun.misc.Unsafe.class.getDeclaredField("theUnsafe");
+ theUnsafe.setAccessible(true);
+ sun.misc.Unsafe u = (sun.misc.Unsafe) theUnsafe.get(null);
+ Class> cls = Class.forName("jdk.internal.module.IllegalAccessLogger");
+ java.lang.reflect.Field logger = cls.getDeclaredField("logger");
+ u.putObjectVolatile(cls, u.staticFieldOffset(logger), null);
+ } catch (Exception e) {
+ // ignore
+ }
+ }
+
+}
diff --git a/kn-launcher/pom.xml b/kn-launcher/pom.xml
new file mode 100644
index 0000000..594b281
--- /dev/null
+++ b/kn-launcher/pom.xml
@@ -0,0 +1,50 @@
+
+
+
+ com.kening.platform
+ kn-vordm
+ ${revision}
+
+
+ 4.0.0
+ kn-launcher
+ ${project.artifactId}
+ ${revision}
+
+
+ wildfly-common
+ org.wildfly.common
+ 1.5.2.Final
+
+
+ org.springblade
+ blade-core-launch
+
+
+ wildfly-common
+ org.wildfly.common
+
+
+
+
+ org.springblade
+ blade-core-auto
+ provided
+
+
+
+
+
+
+ org.springframework.boot
+ spring-boot-maven-plugin
+
+ true
+ ${project.name}
+
+
+
+
+
diff --git a/kn-launcher/src/main/java/org/springblade/common/constant/LauncherConstant.java b/kn-launcher/src/main/java/org/springblade/common/constant/LauncherConstant.java
new file mode 100644
index 0000000..14a18e5
--- /dev/null
+++ b/kn-launcher/src/main/java/org/springblade/common/constant/LauncherConstant.java
@@ -0,0 +1,196 @@
+package org.springblade.common.constant;
+
+import org.springblade.core.launch.constant.AppConstant;
+
+import static org.springblade.core.launch.constant.AppConstant.APPLICATION_NAME_PREFIX;
+
+/**
+ * 通用常量
+ *
+ * @author whq
+ */
+public interface LauncherConstant {
+
+ /**
+ * nacos namespace id
+ */
+ String NACOS_NAMESPACE = "62fddd43-b621-43f6-9733-75a6e4d6756b";
+
+ /**
+ * nacos dev 地址
+ * 8.142.16.8(公网)
+ * 172.28.70.132(私网)
+ * 8.142.41.215(公网)
+ * 172.28.70.131(私网)
+ * 39.103.203.80(公网)
+ * 172.29.144.23(私网)
+ */
+ String NACOS_DEV_ADDR = "8.142.41.215:8848";
+
+ /**
+ * nacos prod 地址
+ */
+ String NACOS_PROD_ADDR = "172.24.100.245:8848,172.24.100.246:8848,172.28.70.132:8848";
+
+ /**
+ * nacos test 地址
+ */
+ String NACOS_TEST_ADDR = "172.24.100.245:8848,172.24.100.246:8848,172.28.70.132:8848";
+
+ /**
+ * sentinel dev 地址
+ */
+ String SENTINEL_DEV_ADDR = "192.168.31.14:8858";
+
+ /**
+ * sentinel prod 地址
+ */
+ String SENTINEL_PROD_ADDR = "192.168.31.14:8858";
+
+ /**
+ * sentinel test 地址
+ */
+ String SENTINEL_TEST_ADDR = "192.168.31.14:8858";
+
+ /**
+ * seata dev 地址
+ */
+ String SEATA_DEV_ADDR = "192.168.31.14:8091";
+
+ /**
+ * seata prod 地址
+ */
+ String SEATA_PROD_ADDR = "192.168.31.14:8091";
+
+ /**
+ * seata test 地址
+ */
+ String SEATA_TEST_ADDR = "192.168.31.14:8091";
+
+ /**
+ * dbuuo提供者
+ */
+ String APPLICATION_DUBBO_PROVIDER_NAME = APPLICATION_NAME_PREFIX + "dubbo-provider";
+
+ /**
+ * dbuuo消费者
+ */
+ String APPLICATION_DUBBO_CONSUMER_NAME = APPLICATION_NAME_PREFIX + "dubbo-consumer";
+
+ /**
+ * seata订单
+ */
+ String APPLICATION_SEATA_ORDER_NAME = APPLICATION_NAME_PREFIX + "seata-order";
+
+ /**
+ * seata库存
+ */
+ String APPLICATION_SEATA_STORAGE_NAME = APPLICATION_NAME_PREFIX + "seata-storage";
+
+ /**
+ * easypoi
+ */
+ String APPLICATION_EASYPOI_NAME = APPLICATION_NAME_PREFIX + "easypoi";
+
+ /**
+ * kafka
+ */
+ String APPLICATION_KAFKA_NAME = APPLICATION_NAME_PREFIX + "kafka";
+
+ /**
+ * rabbit
+ */
+ String APPLICATION_RABBIT_NAME = APPLICATION_NAME_PREFIX + "rabbit";
+
+ /**
+ * stream消费者
+ */
+ String APPLICATION_STREAM_CONSUMER_NAME = APPLICATION_NAME_PREFIX + "stream-consumer";
+
+ /**
+ * stream生产者
+ */
+ String APPLICATION_STREAM_PROVIDER_NAME = APPLICATION_NAME_PREFIX + "stream-provider";
+
+ /**
+ * seata file模式
+ */
+ String FILE_MODE = "file";
+
+ /**
+ * seata nacos模式
+ */
+ String NACOS_MODE = "nacos";
+
+ /**
+ * seata default模式
+ */
+ String DEFAULT_MODE = "default";
+
+ /**
+ * seata group后缀
+ */
+ String GROUP_NAME = "-group";
+
+ /**
+ * seata 服务组格式
+ *
+ * @param appName 服务名
+ * @return group
+ */
+ static String seataServiceGroup(String appName) {
+ return appName.concat(GROUP_NAME);
+ }
+
+ /**
+ * 动态获取nacos地址
+ *
+ * @param profile 环境变量
+ * @return addr
+ */
+ static String nacosAddr(String profile) {
+ switch (profile) {
+ case (AppConstant.PROD_CODE):
+ return NACOS_PROD_ADDR;
+ case (AppConstant.TEST_CODE):
+ return NACOS_TEST_ADDR;
+ default:
+ return NACOS_DEV_ADDR;
+ }
+ }
+
+ /**
+ * 动态获取sentinel地址
+ *
+ * @param profile 环境变量
+ * @return addr
+ */
+ static String sentinelAddr(String profile) {
+ switch (profile) {
+ case (AppConstant.PROD_CODE):
+ return SENTINEL_PROD_ADDR;
+ case (AppConstant.TEST_CODE):
+ return SENTINEL_TEST_ADDR;
+ default:
+ return SENTINEL_DEV_ADDR;
+ }
+ }
+
+ /**
+ * 动态获取seata地址
+ *
+ * @param profile 环境变量
+ * @return addr
+ */
+ static String seataAddr(String profile) {
+ switch (profile) {
+ case (AppConstant.PROD_CODE):
+ return SEATA_PROD_ADDR;
+ case (AppConstant.TEST_CODE):
+ return SEATA_TEST_ADDR;
+ default:
+ return SEATA_DEV_ADDR;
+ }
+ }
+
+}
diff --git a/kn-launcher/src/main/java/org/springblade/common/launch/LauncherServiceImpl.java b/kn-launcher/src/main/java/org/springblade/common/launch/LauncherServiceImpl.java
new file mode 100644
index 0000000..96e7cb9
--- /dev/null
+++ b/kn-launcher/src/main/java/org/springblade/common/launch/LauncherServiceImpl.java
@@ -0,0 +1,41 @@
+package org.springblade.common.launch;
+
+import org.springblade.common.constant.LauncherConstant;
+import org.springblade.core.auto.service.AutoService;
+import org.springblade.core.launch.service.LauncherService;
+import org.springblade.core.launch.utils.PropsUtil;
+import org.springframework.boot.builder.SpringApplicationBuilder;
+
+import java.util.Properties;
+
+/**
+ * 启动参数拓展
+ *
+ * @author whq
+ */
+@AutoService(LauncherService.class)
+public class LauncherServiceImpl implements LauncherService {
+
+ @Override
+ public void launcher(SpringApplicationBuilder builder, String appName, String profile, boolean isLocalDev) {
+ Properties props = System.getProperties();
+ // 通用注册
+ PropsUtil.setProperty(props, "spring.cloud.nacos.discovery.server-addr", LauncherConstant.nacosAddr(profile));
+ PropsUtil.setProperty(props, "spring.cloud.nacos.config.server-addr", LauncherConstant.nacosAddr(profile));
+ PropsUtil.setProperty(props, "spring.cloud.sentinel.transport.dashboard", LauncherConstant.sentinelAddr(profile));
+ PropsUtil.setProperty(props, "spring.cloud.nacos.discovery.namespace", LauncherConstant.NACOS_NAMESPACE);
+ PropsUtil.setProperty(props, "spring.cloud.nacos.config.namespace", LauncherConstant.NACOS_NAMESPACE);
+ // seata注册地址
+ PropsUtil.setProperty(props, "seata.service.grouplist.default", LauncherConstant.seataAddr(profile));
+ // seata注册group格式
+ PropsUtil.setProperty(props, "seata.tx-service-group", LauncherConstant.seataServiceGroup(appName));
+ // seata配置服务group
+ PropsUtil.setProperty(props, "seata.service.vgroup-mapping.".concat(LauncherConstant.seataServiceGroup(appName)), LauncherConstant.DEFAULT_MODE);
+ // seata注册模式配置
+ // PropsUtil.setProperty(props, "seata.registry.type", LauncherConstant.NACOS_MODE);
+ // PropsUtil.setProperty(props, "seata.registry.nacos.server-addr", LauncherConstant.nacosAddr(profile));
+ // PropsUtil.setProperty(props, "seata.config.type", LauncherConstant.NACOS_MODE);
+ // PropsUtil.setProperty(props, "seata.config.nacos.server-addr", LauncherConstant.nacosAddr(profile));
+ }
+
+}
diff --git a/kn-service-api/biz-vordm-api/pom.xml b/kn-service-api/biz-vordm-api/pom.xml
new file mode 100644
index 0000000..39dce3b
--- /dev/null
+++ b/kn-service-api/biz-vordm-api/pom.xml
@@ -0,0 +1,22 @@
+
+
+
+ kn-service-api
+ com.kening.platform
+ ${revision}
+
+ 4.0.0
+
+ biz-vordm-api
+
+
+
+ com.kening.platform
+ kn-common
+ ${revision}
+
+
+
+
diff --git a/kn-service-api/pom.xml b/kn-service-api/pom.xml
new file mode 100644
index 0000000..ecc438c
--- /dev/null
+++ b/kn-service-api/pom.xml
@@ -0,0 +1,73 @@
+
+
+
+ com.kening.platform
+ kn-vordm
+ ${revision}
+
+
+ 4.0.0
+ kn-service-api
+ ${project.artifactId}
+ ${revision}
+
+ biz-vordm-api
+
+ pom
+ 微服务API集合
+
+
+
+ org.projectlombok
+ lombok
+
+
+ com.baomidou
+ mybatis-plus-annotation
+ 3.4.2
+
+
+ org.freemarker
+ freemarker
+
+
+ io.swagger
+ swagger-annotations
+ 1.6.2
+
+
+ org.springblade
+ blade-starter-mybatis
+
+
+
+ org.springblade
+ blade-starter-tenant
+
+
+ org.springframework.cloud
+ spring-cloud-starter-openfeign
+
+
+
+ org.springframework.cloud
+ spring-cloud-starter-netflix-hystrix
+
+
+
+
+
+
+ org.springframework.boot
+ spring-boot-maven-plugin
+
+ true
+ ${project.name}
+
+
+
+
+
+
diff --git a/kn-service/biz-vordm/pom.xml b/kn-service/biz-vordm/pom.xml
new file mode 100644
index 0000000..d09ca7f
--- /dev/null
+++ b/kn-service/biz-vordm/pom.xml
@@ -0,0 +1,22 @@
+
+
+
+ kn-service
+ com.kening.platform
+ ${revision}
+
+ 4.0.0
+
+ biz-vordm
+
+
+
+ com.kening.platform
+ biz-vordm-api
+ ${revision}
+
+
+
+
diff --git a/kn-service/biz-vordm/src/main/java/com/kening/vordm/VoRdmApplication.java b/kn-service/biz-vordm/src/main/java/com/kening/vordm/VoRdmApplication.java
new file mode 100644
index 0000000..cd32db5
--- /dev/null
+++ b/kn-service/biz-vordm/src/main/java/com/kening/vordm/VoRdmApplication.java
@@ -0,0 +1,16 @@
+package com.kening.vordm;
+
+import org.springblade.common.constant.CommonConstant;
+import org.springblade.core.launch.BladeApplication;
+import org.springframework.cloud.client.SpringCloudApplication;
+
+/**
+ * @author wanghongqing
+ * @date 2023/3/21 14:24
+ **/
+@SpringCloudApplication
+public class VoRdmApplication {
+ public static void main(String[] args) {
+ BladeApplication.run(CommonConstant.KN_VORDM_MODULE_NAME, VoRdmApplication.class, args);
+ }
+}
diff --git a/kn-service/biz-vordm/src/main/java/com/kening/vordm/config/VoRdmConfig.java b/kn-service/biz-vordm/src/main/java/com/kening/vordm/config/VoRdmConfig.java
new file mode 100644
index 0000000..4a91ba6
--- /dev/null
+++ b/kn-service/biz-vordm/src/main/java/com/kening/vordm/config/VoRdmConfig.java
@@ -0,0 +1,15 @@
+package com.kening.vordm.config;
+
+import org.mybatis.spring.annotation.MapperScan;
+import org.springframework.context.annotation.ComponentScan;
+import org.springframework.context.annotation.Configuration;
+
+/**
+ * @author wanghongqing
+ * @date 2023/3/21 14:32
+ **/
+@Configuration
+@ComponentScan({"org.springblade", "com.kening.vordm"})
+@MapperScan({"org.springblade.**.mapper.**", "com.kening.**.mapper.**"})
+public class VoRdmConfig {
+}
diff --git a/kn-service/biz-vordm/src/main/resources/application-dev.yml b/kn-service/biz-vordm/src/main/resources/application-dev.yml
new file mode 100644
index 0000000..3aef9ec
--- /dev/null
+++ b/kn-service/biz-vordm/src/main/resources/application-dev.yml
@@ -0,0 +1,5 @@
+spring:
+ datasource:
+ url: ${kn.datasource.vordm.url}
+ username: ${kn.datasource.vordm.username}
+ password: ${kn.datasource.vordm.password}
diff --git a/kn-service/biz-vordm/src/main/resources/application-prod.yml b/kn-service/biz-vordm/src/main/resources/application-prod.yml
new file mode 100644
index 0000000..3aef9ec
--- /dev/null
+++ b/kn-service/biz-vordm/src/main/resources/application-prod.yml
@@ -0,0 +1,5 @@
+spring:
+ datasource:
+ url: ${kn.datasource.vordm.url}
+ username: ${kn.datasource.vordm.username}
+ password: ${kn.datasource.vordm.password}
diff --git a/kn-service/biz-vordm/src/main/resources/application-test.yml b/kn-service/biz-vordm/src/main/resources/application-test.yml
new file mode 100644
index 0000000..3aef9ec
--- /dev/null
+++ b/kn-service/biz-vordm/src/main/resources/application-test.yml
@@ -0,0 +1,5 @@
+spring:
+ datasource:
+ url: ${kn.datasource.vordm.url}
+ username: ${kn.datasource.vordm.username}
+ password: ${kn.datasource.vordm.password}
diff --git a/kn-service/biz-vordm/src/main/resources/application.yml b/kn-service/biz-vordm/src/main/resources/application.yml
new file mode 100644
index 0000000..6179445
--- /dev/null
+++ b/kn-service/biz-vordm/src/main/resources/application.yml
@@ -0,0 +1,13 @@
+server:
+ port: 8282
+
+#mybatis-plus配置
+mybatis-plus:
+ mapper-locations: classpath:com/kening/**/mapper/*Mapper.xml
+ #实体扫描,多个package用逗号或者分号分隔
+ typeAliasesPackage: com.kening.**.entity
+
+#swagger扫描路径配置
+swagger:
+ base-packages:
+ - com.kening.vordm
diff --git a/kn-service/pom.xml b/kn-service/pom.xml
new file mode 100644
index 0000000..eb4ec08
--- /dev/null
+++ b/kn-service/pom.xml
@@ -0,0 +1,81 @@
+
+
+ 4.0.0
+
+ biz-vordm
+
+
+
+ com.kening.platform
+ kn-vordm
+ ${revision}
+
+
+ kn-service
+ ${project.artifactId}
+ ${revision}
+ pom
+ 微服务集合
+
+
+
+ org.hdrhistogram
+ HdrHistogram
+ 2.1.12
+
+
+ org.javassist
+ javassist
+ 3.25.0-GA
+
+
+ com.kening.platform
+ kn-launcher
+
+
+ org.springblade
+ blade-core-boot
+
+
+ com.oracle
+ ojdbc7
+
+
+ HdrHistogram
+ org.hdrhistogram
+
+
+ javassist
+ org.javassist
+
+
+ com.microsoft.sqlserver
+ mssql-jdbc
+
+
+ org.postgresql
+ postgresql
+
+
+ fastjson
+ com.alibaba
+
+
+
+
+ com.alibaba
+ fastjson
+
+
+ org.springblade
+ blade-starter-swagger
+
+
+ org.springblade
+ blade-starter-tenant
+
+
+
+
diff --git a/pom.xml b/pom.xml
new file mode 100644
index 0000000..a78703c
--- /dev/null
+++ b/pom.xml
@@ -0,0 +1,227 @@
+
+
+ 4.0.0
+
+ com.kening.platform
+ kn-vordm
+ ${revision}
+ pom
+
+
+ 3.2.2.RELEASE
+ 1.8
+ 1.0.0-SNAPSHOT
+ 1.0.4
+ 3.8.1
+ UTF-8
+ UTF-8
+ 2.3.12.RELEASE
+ Hoxton.SR12
+ Cairo-SR8
+
+ 192.168.31.14:8082
+ true
+ admin
+ Harbor12345
+ iot
+ 1.4.13
+
+
+
+ kn-common
+ kn-launcher
+ kn-service
+ kn-service-api
+
+
+
+
+
+ org.springblade.platform
+ blade-bom
+ ${springblade.project.version}
+ pom
+ import
+
+
+ org.springframework.boot
+ spring-boot-dependencies
+ ${spring.boot.version}
+ pom
+ import
+
+
+ org.springframework.cloud
+ spring-cloud-dependencies
+ ${spring.cloud.version}
+ pom
+ import
+
+
+ io.spring.platform
+ platform-bom
+ ${spring.platform.version}
+ pom
+ import
+
+
+ com.kening.platform
+ kn-launcher
+ ${revision}
+
+
+
+
+
+
+ org.projectlombok
+ lombok
+ provided
+
+
+
+
+ ${project.name}
+
+
+ src/main/resources
+
+
+ src/main/java
+
+ **/*.xml
+
+
+
+
+
+
+ org.codehaus.mojo
+ flatten-maven-plugin
+ 1.1.0
+
+ true
+ resolveCiFriendliesOnly
+
+ expand
+
+
+
+
+ flatten
+ process-resources
+
+ flatten
+
+
+
+ flatten.clean
+ clean
+
+ clean
+
+
+
+
+
+ org.springframework.boot
+ spring-boot-maven-plugin
+ ${spring.boot.version}
+
+ true
+ ${project.build.finalName}
+
+
+
+
+ repackage
+
+
+
+
+
+ com.spotify
+ dockerfile-maven-plugin
+ ${docker.plugin.version}
+
+ ${docker.username}
+ ${docker.password}
+ ${docker.registry.url}/${docker.namespace}/${project.artifactId}
+ ${project.version}
+ true
+
+
+
+
+ default
+
+ build
+ push
+
+ package
+
+
+
+
+
+
+
+ maven-compiler-plugin
+ ${maven.plugin.version}
+
+
+ ${java.version}
+ UTF-8
+
+ -parameters
+
+
+
+
+ org.codehaus.mojo
+ flatten-maven-plugin
+
+
+ org.springframework.boot
+ spring-boot-maven-plugin
+
+
+ com.spotify
+ dockerfile-maven-plugin
+
+ true
+
+
+
+
+
+
+
+ kening-release
+ Release Repository
+ http://47.92.168.204:8081/repository/maven-public/
+
+ true
+
+
+ true
+
+
+
+
+
+
+ kening-plugin
+ http://47.92.168.204:8081/repository/maven-public/
+
+ true
+
+
+ true
+
+
+
+
+
+