diff --git a/hzims-service/middle/.gitignore b/hzims-service/middle/.gitignore new file mode 100644 index 0000000..063d31d --- /dev/null +++ b/hzims-service/middle/.gitignore @@ -0,0 +1,38 @@ +HELP.md +target/ +!.mvn/wrapper/maven-wrapper.jar +!**/src/main/**/target/ +!**/src/test/**/target/ + +### STS ### +.apt_generated +.classpath +.factorypath +.project +.settings +.springBeans +.sts4-cache + +### IntelliJ IDEA ### +.idea +*.iws +*.iml +*.ipr + +### NetBeans ### +/nbproject/private/ +/nbbuild/ +/dist/ +/nbdist/ +/.nb-gradle/ +build/ +!**/src/main/**/build/ +!**/src/test/**/build/ + +### VS Code ### +.vscode/ + +*.md +target/** +**/test/ +.gitignore diff --git a/hzims-service/middle/pom.xml b/hzims-service/middle/pom.xml new file mode 100644 index 0000000..d4f8665 --- /dev/null +++ b/hzims-service/middle/pom.xml @@ -0,0 +1,69 @@ + + + + hzims-service + com.hnac.hzims + 4.0.0-SNAPSHOT + + 4.0.0 + com.hnac.hzims + hzims-middle + 4.0.0-SNAPSHOT + middle + middle + + 1.8 + UTF-8 + UTF-8 + 2.6.13 + + + + + org.springblade + blade-common + ${bladex.projet.common.version} + + + org.springblade + blade-core-boot + + + org.springblade + blade-starter-swagger + + + org.springblade + blade-core-test + test + + + org.springblade + blade-core-auto + provided + + + + + ${project.name}-${project.version} + + + com.spotify + dockerfile-maven-plugin + + ${docker.username} + ${docker.password} + ${docker.registry.url}/${docker.namespace}/${project.artifactId} + ${project.version} + true + + target/${project.build.finalName}.jar + + false + + + + + + diff --git a/hzims-service/middle/src/main/java/com/hnac/hzims/middle/MiddleApplication.java b/hzims-service/middle/src/main/java/com/hnac/hzims/middle/MiddleApplication.java new file mode 100644 index 0000000..4b48c6c --- /dev/null +++ b/hzims-service/middle/src/main/java/com/hnac/hzims/middle/MiddleApplication.java @@ -0,0 +1,21 @@ +package com.hnac.hzims.middle; + +import org.mybatis.spring.annotation.MapperScan; +import org.springblade.core.cloud.feign.EnableBladeFeign; +import org.springblade.core.launch.BladeApplication; +import org.springframework.boot.SpringApplication; +import org.springframework.boot.autoconfigure.SpringBootApplication; +import org.springframework.cloud.client.SpringCloudApplication; +import org.springframework.context.annotation.ComponentScan; + +@EnableBladeFeign +@SpringCloudApplication +@MapperScan("com.hnac.hzims.*.**.mapper.**") +@ComponentScan(basePackages = {"com.hnac.*"}) +public class MiddleApplication { + + public static void main(String[] args) { + BladeApplication.run("hzims-middle", MiddleApplication.class, args); + } + +} diff --git a/hzims-service/middle/src/main/resources/application.yml b/hzims-service/middle/src/main/resources/application.yml new file mode 100644 index 0000000..575c445 --- /dev/null +++ b/hzims-service/middle/src/main/resources/application.yml @@ -0,0 +1,36 @@ +#服务器端口 +server: + port: 8400 + +#数据源配置 +spring: + #排除DruidDataSourceAutoConfigure + autoconfigure: + exclude: com.alibaba.druid.spring.boot.autoconfigure.DruidDataSourceAutoConfigure + datasource: + url: jdbc:mysql://192.168.1.20:3576/dev_hzims_assets?useSSL=false&useUnicode=true&characterEncoding=utf-8&zeroDateTimeBehavior=convertToNull&transformedBitIsBoolean=true&tinyInt1isBit=false&allowMultiQueries=true&serverTimezone=GMT%2B8&nullCatalogMeansCurrent=true&allowPublicKeyRetrieval=true + username: root + password: 123 + + +#mybatis-plus配置 +mybatis-plus: + mapper-locations: classpath:com/hnac/hzims/**/mapper/*Mapper.xml + #实体扫描,多个package用逗号或者分号分隔 + typeAliasesPackage: com.hnac.hzims.**.entity + +#swagger扫描路径配置 +swagger: + base-packages: + - org.springbalde + - com.hnac + +blade: + data-scope: + enabled: false + lock: + enabled: true + address: redis://192.168.1.20:3577 + password: 1qaz2WSX@redis + database: 0 + ssl: false diff --git a/hzims-service/middle/src/test/java/com/hnac/hzims/middle/MiddleApplicationTests.java b/hzims-service/middle/src/test/java/com/hnac/hzims/middle/MiddleApplicationTests.java new file mode 100644 index 0000000..05189d9 --- /dev/null +++ b/hzims-service/middle/src/test/java/com/hnac/hzims/middle/MiddleApplicationTests.java @@ -0,0 +1,13 @@ +package com.hnac.hzims.middle; + +import org.junit.jupiter.api.Test; +import org.springframework.boot.test.context.SpringBootTest; + +@SpringBootTest +class MiddleApplicationTests { + + @Test + void contextLoads() { + } + +}