commit 28a44061a7fcfe490aa0950ce6d79b75d2106269 Author: xuyang <748613696@qq.com> Date: Mon May 22 13:27:22 2023 +0800 新建治理项目 diff --git a/cs_device/cs_device_api/pom.xml b/cs_device/cs_device_api/pom.xml new file mode 100644 index 0000000..cd39e5d --- /dev/null +++ b/cs_device/cs_device_api/pom.xml @@ -0,0 +1,22 @@ + + + + + cs_device + com.njcn + 1.0.0 + + 4.0.0 + + cs_device_api + 1.0.0 + + cs_device_api + + + UTF-8 + 8 + 8 + + diff --git a/cs_device/cs_device_boot/pom.xml b/cs_device/cs_device_boot/pom.xml new file mode 100644 index 0000000..e8423c1 --- /dev/null +++ b/cs_device/cs_device_boot/pom.xml @@ -0,0 +1,110 @@ + + + + + cs_device + com.njcn + 1.0.0 + + 4.0.0 + + cs_device_boot + 1.0.0 + + cs_device_boot + + + UTF-8 + 8 + 8 + + + + + com.njcn + common-web + ${project.version} + + + com.njcn + common-swagger + ${project.version} + + + org.mybatis + mybatis-spring + 2.0.5 + + + com.njcn + common-db + ${project.version} + + + + + csDeviceBoot + + + org.apache.maven.plugins + maven-compiler-plugin + 3.8.0 + + -Xlint:unchecked + + + + org.springframework.boot + spring-boot-maven-plugin + + + package + + repackage + + + + + + + com.spotify + docker-maven-plugin + 1.0.0 + + + + build-image + ${docker.operate} + + build + + + + + + http://${docker.repostory} + + ${docker.repostory}/${docker.registry.name}/${project.artifactId} + + + latest + + + ${docker.url} + ${basedir}/ + + + + /ROOT + + ${project.build.directory} + + ${project.build.finalName}.jar + + + + + + + diff --git a/cs_device/cs_device_boot/src/main/java/com/njcn/device/CsDeviceBootApplication.java b/cs_device/cs_device_boot/src/main/java/com/njcn/device/CsDeviceBootApplication.java new file mode 100644 index 0000000..43f7a06 --- /dev/null +++ b/cs_device/cs_device_boot/src/main/java/com/njcn/device/CsDeviceBootApplication.java @@ -0,0 +1,25 @@ +package com.njcn.device; + +import lombok.extern.slf4j.Slf4j; +import org.mybatis.spring.annotation.MapperScan; +import org.springframework.boot.SpringApplication; +import org.springframework.boot.autoconfigure.SpringBootApplication; +import org.springframework.cloud.openfeign.EnableFeignClients; + + +/** + * @author hongawen + * @version 1.0.0 + * @date 2021年12月09日 20:59 + */ +@Slf4j +@MapperScan("com.njcn.**.mapper") +@EnableFeignClients(basePackages = "com.njcn") +@SpringBootApplication(scanBasePackages = "com.njcn") +public class CsDeviceBootApplication { + + public static void main(String[] args) { + SpringApplication.run(CsDeviceBootApplication.class, args); + } + +} diff --git a/cs_device/cs_device_boot/src/main/resources/bootstrap.yml b/cs_device/cs_device_boot/src/main/resources/bootstrap.yml new file mode 100644 index 0000000..5526a64 --- /dev/null +++ b/cs_device/cs_device_boot/src/main/resources/bootstrap.yml @@ -0,0 +1,51 @@ +#当前服务的基本信息 +microservice: + ename: @artifactId@ + name: '@name@' + version: @version@ + sentinel: + url: @sentinel.url@ + gateway: + url: @gateway.url@ +server: + port: 10210 +#feign接口开启服务熔断降级处理 +feign: + sentinel: + enabled: true +spring: + application: + name: @artifactId@ + cloud: + nacos: + discovery: + ip: @service.server.url@ + server-addr: @nacos.url@ + namespace: @nacos.namespace@ + config: + server-addr: @nacos.url@ + namespace: @nacos.namespace@ + file-extension: yaml + shared-configs: + - data-id: share-config.yaml + refresh: true + - data-Id: algorithm-config.yaml + refresh: true + main: + allow-bean-definition-overriding: true + + +#项目日志的配置 +logging: + config: http://@nacos.url@/nacos/v1/cs/configs?tenant=@nacos.namespace@&group=DEFAULT_GROUP&dataId=logback.xml + level: + root: info + + +#mybatis配置信息 +mybatis-plus: + #别名扫描 + type-aliases-package: com.njcn.device.pojo + +mqtt: + client-id: @artifactId@${random.value} \ No newline at end of file diff --git a/cs_device/cs_device_boot/src/test/java/com/njcn/AppTest.java b/cs_device/cs_device_boot/src/test/java/com/njcn/AppTest.java new file mode 100644 index 0000000..a7e14d2 --- /dev/null +++ b/cs_device/cs_device_boot/src/test/java/com/njcn/AppTest.java @@ -0,0 +1,20 @@ +package com.njcn; + +import static org.junit.Assert.assertTrue; + +import org.junit.Test; + +/** + * Unit test for simple App. + */ +public class AppTest +{ + /** + * Rigorous Test :-) + */ + @Test + public void shouldAnswerWithTrue() + { + assertTrue( true ); + } +} diff --git a/cs_device/cs_device_boot/target/classes/bootstrap.yml b/cs_device/cs_device_boot/target/classes/bootstrap.yml new file mode 100644 index 0000000..519e563 --- /dev/null +++ b/cs_device/cs_device_boot/target/classes/bootstrap.yml @@ -0,0 +1,51 @@ +#当前服务的基本信息 +microservice: + ename: cs_device_boot + name: 'cs_device_boot' + version: 1.0.0 + sentinel: + url: 192.168.1.13:8080 + gateway: + url: 192.168.1.139:10215 +server: + port: 10210 +#feign接口开启服务熔断降级处理 +feign: + sentinel: + enabled: true +spring: + application: + name: cs_device_boot + cloud: + nacos: + discovery: + ip: 192.168.1.139 + server-addr: 192.168.1.13:18848 + namespace: 415a1c87-33aa-47bd-8e25-13cc456c87ed + config: + server-addr: 192.168.1.13:18848 + namespace: 415a1c87-33aa-47bd-8e25-13cc456c87ed + file-extension: yaml + shared-configs: + - data-id: share-config.yaml + refresh: true + - data-Id: share-config-datasource-db.yaml + refresh: true + main: + allow-bean-definition-overriding: true + + +#项目日志的配置 +logging: + config: http://192.168.1.13:18848/nacos/v1/cs/configs?tenant=415a1c87-33aa-47bd-8e25-13cc456c87ed&group=DEFAULT_GROUP&dataId=logback.xml + level: + root: info + + +#mybatis配置信息 +mybatis-plus: + #别名扫描 + type-aliases-package: com.njcn.device.pojo + +mqtt: + client-id: cs_device_boot${random.value} \ No newline at end of file diff --git a/cs_device/cs_device_boot/target/classes/com/njcn/device/CsDeviceBootApplication.class b/cs_device/cs_device_boot/target/classes/com/njcn/device/CsDeviceBootApplication.class new file mode 100644 index 0000000..a335cb9 Binary files /dev/null and b/cs_device/cs_device_boot/target/classes/com/njcn/device/CsDeviceBootApplication.class differ diff --git a/cs_device/cs_device_boot/target/test-classes/com/njcn/AppTest.class b/cs_device/cs_device_boot/target/test-classes/com/njcn/AppTest.class new file mode 100644 index 0000000..7a2ca25 Binary files /dev/null and b/cs_device/cs_device_boot/target/test-classes/com/njcn/AppTest.class differ diff --git a/cs_device/pom.xml b/cs_device/pom.xml new file mode 100644 index 0000000..83ed7c3 --- /dev/null +++ b/cs_device/pom.xml @@ -0,0 +1,28 @@ + + + + + govern + com.njcn + 1.0.0 + + 4.0.0 + + cs_device + pom + + cs_device + 治理台账模块 + + cs_device_api + cs_device_boot + + + + UTF-8 + 8 + 8 + + + diff --git a/pom.xml b/pom.xml new file mode 100644 index 0000000..193a600 --- /dev/null +++ b/pom.xml @@ -0,0 +1,390 @@ + + + + 4.0.0 + + com.njcn + govern + 1.0.0 + + cs_device + + + govern + 治理项目 + pom + + + 192.168.1.13 + + 192.168.1.139 + + 192.168.1.13 + + ${middle.server.url}:18848 + + + 415a1c87-33aa-47bd-8e25-13cc456c87ed + + ${middle.server.url}:8080 + + ${service.server.url}:10215 + + http://${docker.server.url}:2375 + + ${docker.server.url}:8090 + + njcn + + common-microservice + + site + 1.8 + 8 + 8 + + 2.3.12.RELEASE + + Hoxton.SR12 + 2.2.7.RELEASE + 5.7.9 + 3.0.2 + 2.0.8 + 1.18.18 + 2.1.3 + 1.2.5 + 8.0.19 + 2.4.0 + 21.6.0.0 + 21.1.0.0 + 3.4.2 + 3.5.1 + 1.5.1-RELEASE + 3.5.1 + 2.3 + 0.9.1 + 11.2 + 1.6.4 + 2.3.2 + 1.68 + 3.12.0 + 2.8.0 + 1.15 + 1.8.1 + 2.12.4 + 2.2.6 + 2.18 + 3.0.0.6 + 2.8.9 + 2.3.0 + 1.2.7 + 4.4.0 + 0.5.3 + 4.8.1 + 8.2.1 + 1.7.0-Hoxton + + + + nexus-releases + Nexus Release Repository + http://192.168.1.13:8001/nexus/content/repositories/releases/ + + + nexus-snapshots + Nexus Snapshot Repository + http://192.168.1.13:8001/nexus/content/repositories/snapshots/ + + + + + + + org.springframework.boot + spring-boot-dependencies + ${springboot.version} + pom + import + + + org.springframework.cloud + spring-cloud-dependencies + ${springcloud.version} + pom + import + + + com.alibaba.cloud + spring-cloud-alibaba-dependencies + ${springcloud.alibaba.version} + pom + import + + + + com.huaweicloud + spring-cloud-huawei-dependencies + ${spring-cloud-huawei.version} + pom + import + + + + + cn.hutool + hutool-all + ${hutool.version} + + + + org.projectlombok + lombok + ${lombok.version} + + + + com.github.xiaoymin + knife4j-spring-boot-starter + ${knife4j.version} + + + com.github.xiaoymin + knife4j-spring-ui + ${knife4j.version} + + + com.github.xiaoymin + knife4j-aggregation-spring-boot-starter + + ${knife4j.aggregation.version} + + + + org.mybatis.spring.boot + mybatis-spring-boot-starter + ${mybatis.version} + + + + com.alibaba + druid-spring-boot-starter + ${druid.version} + + + + mysql + mysql-connector-java + ${mysql.version} + + + + org.mariadb.jdbc + mariadb-java-client + ${mariadb.version} + + + + com.oracle.database.jdbc + ojdbc8 + ${oracle.version} + + + + com.oracle.database.nls + orai18n + ${orai18n.version} + + + + com.baomidou + mybatis-plus-boot-starter + ${mybatis-plus.version} + + + com.baomidou + mybatis-plus-generator + ${mybatis-plus-generator.version} + + + com.github.jeffreyning + mybatisplus-plus + ${mybatis-plus.jeffreyning.version} + + + org.apache.velocity + velocity-engine-core + ${velocity.version} + + + + + io.jsonwebtoken + jjwt + ${jjwt.version} + + + + io.github.openfeign + feign-okhttp + ${feignOkhttp.version} + + + + org.owasp.antisamy + antisamy + ${antisamy.version} + + + + com.github.penggle + kaptcha + ${kaptcha.version} + + + + org.bouncycastle + bcprov-jdk15on + ${bcprov-jdk15on.version} + + + + org.apache.commons + commons-lang3 + ${commons-lang3.version} + + + commons-io + commons-io + ${commons-io.version} + + + commons-codec + commons-codec + ${commons-codec.version} + + + com.alibaba.csp + sentinel-datasource-nacos + ${sentinel.datasource.nacos.version} + + + + com.fasterxml.jackson.core + jackson-databind + ${jackson} + + + + com.fasterxml.jackson.core + jackson-core + ${jackson} + + + com.fasterxml.jackson.core + jackson-annotations + ${jackson} + + + com.fasterxml.jackson.datatype + jackson-datatype-jsr310 + ${jackson} + + + com.alibaba + easyexcel + ${easyexcel} + + + com.github.abel533 + ECharts + ${echarts.version} + + + + com.google.code.gson + gson + ${gson.version} + + + + com.xuxueli + xxl-job-core + ${xxl-job.version} + + + com.github.tocrhz + mqtt-spring-boot-starter + ${mqtt.version} + + + cn.afterturn + easypoi-spring-boot-starter + ${easypoi.version} + + + + me.tongfei + progressbar + ${progressbar.version} + + + com.squareup.okhttp3 + okhttp + ${okhttp.version} + + + io.minio + minio + ${minio.version} + + + com.squareup.okhttp3 + okhttp + + + + + + com.baomidou + dynamic-datasource-spring-boot-starter + ${dynamic-datasource.version} + + + + + + + + org.springframework.boot + spring-boot-maven-plugin + 2.2.2.RELEASE + + true + true + + + + org.apache.maven.plugins + maven-compiler-plugin + 3.1 + + 1.8 + 1.8 + + + + + + src/main/resources + true + + + src/main/java + + **/*.xml + + + + +