diff --git a/config/application_oracle.yml b/config/application_oracle.yml new file mode 100644 index 0000000..1045143 --- /dev/null +++ b/config/application_oracle.yml @@ -0,0 +1,207 @@ +#上传文件的路径,要带斜杠 +web: + upload-path: /Users/mrz/Pictures/ +server: + port: 10001 + servlet: + context-path: ${SERVER_CONTEXTPATH:} +spring: + profiles: + active: dev + mvc: + #静态资源,设置上传文件的访问, + static-path-pattern: /** + thymeleaf: + cache: false + encoding: UTF-8 + mode: XML + suffix: .xml + prefix: classpath:/templates/ + resources: + static-locations: classpath:/META-INF/resources/,classpath:/static,classpath:/resources/,file:${web.upload-path} + + application: + name: wlpt-nmms-manage + + jackson: + serialization: + FAIL_ON_EMPTY_BEANS: false + #springboot2.0之后会把Date类型字段自动给转成UTC字符串 如:1990-11-26T16:00:00.000+0000,如果想转成时间戳在application.properties配置文件增加以下配置 + date-format: yyyy-MM-dd HH:mm:ss + #时区必须要设置 + time-zone: GMT+8 + #ALWAYS的意思是即时属性为null,仍然也会输出这个key + default-property-inclusion: always + + cloud: + #eureka主机名,会在控制页面中显示 + #DEV环境关闭注册。 + features: + enabled: false + discovery: + enabled: false + service-registry: + auto-registration: + enabled: false + + datasource: + type: com.alibaba.druid.pool.DruidDataSource + #oracle + driver-class-name: oracle.jdbc.OracleDriver +# url: jdbc:oracle:thin:@192.168.1.199:10069:CGODB +# username: CGONMS +# password: 1q2w3e4r + url: jdbc:oracle:thin:@192.168.1.253:1522:ORCLL + username: CGONMS + password: vmvnv1v2 + #spring datasource mysql,注意编码配置,缺少数据库编码配置容易引起中文入库乱码 +# url: jdbc:mysql://127.0.0.1:3307/statistics?useUnicode=true&characterEncoding=utf8 +# username: root +# password: +# driver-class-name: com.mysql.jdbc.Driver + max-idle: 20 + max-wait: 10000 + min-idle: 5 + initial-size: 5 + #配置初始化大小/最小/最大 + druid: + initial-size: 1 + min-idle: 1 + #最大并发连接数 + max-active: 40 + #获取连接等待超时时间 + max-wait: 60000 + #一个连接在池中最小生存的时间 + min-evictable-idle-time-millis: 300000 + #间隔多久进行一次检测,检测需要关闭的空闲连接 + time-between-eviction-runs-millis: 60000 + #mysql +# validation-query: SELECT 1 FROM DUAL + #oracle + validation-query: SELECT 'x' FROM DUAL + test-while-idle: true + test-on-borrow: false + test-on-return: false + default-auto-commit: true + +eureka: + instance: + #eureka服务器页面中status的请求路径 + status-page-url: http://${eureka.instance.hostname}:${server.port}/ + prefer-ip-address: true + instance-id: ${spring.cloud.client.ip-address}:${server.port} + hostname: ${spring.cloud.client.ip-address} + client: + #eureka注册中心服务器地址 + service-url: +# defaultZone: http://10.50.7.70:12345/eureka/ + defaultZone: http://192.168.1.53:12345/eureka/ + registry-fetch-interval-seconds: 30 + lease-renewal-interval-in-seconds: 15 + lease-expiration-duration-in-seconds: 45 + +mybatis: + mapper-locations: classpath:mapping/*.xml + type-aliases-package: com.tianbo.warehouse.model +pagehelper: + #auto-dialect: true + #auto-runtime-dialect: true + helper-dialect: oracle + reasonable: true + support-methods-arguments: true + params: count=countSql + +#debug配置,debug或者为true的时候,logback才会记录和写入日志文件 +trace: false +debug: true + +swagger: + production: false + basic: + enable: true + username: jack + password: Admin2021@999 + +logging: + file: + path: ./logs/ + name: system.log + config: config/logback-dev.xml + #转移到logback配置文件中 + #level: + #org.apache.tomcat: info + #com.tianbo.warehouse.dao: DEBUG + #org.springframework.security: trace + #日志配置,输出到文本, +#Java Web Token 时效时间,单位秒 +jwt: + max-alive: 300 +# 舱单生成配置 +customs: + # 操作员IC卡姓名 + inputOpName: 翟梦一 + # 操作员IC卡号 + inputOpId: 8930000085548 + # 报关公司 + applyName: 河南航空货运发展有限公司 + # 报关公司海关十位编码 + applyCode: 4101888126 + # 报关公司组织机构代码 + copCode: 70678920X + #生成报文文件夹路径,尾部要带斜杠/ + xml-path: customTemplate/ + # 海关通道数据传输人识别号 + transport-number: 460470678920X + # 转关运抵相关配置 + transarrive: + #生成报文文件夹路径,尾部要带斜杠/ + xml-save: transarriveSend/ + # 客户端统一编号 +# clientSeqno: "000000000000002050" + clientSeqno: "000000000000057246" +# clientSeqno: 460470678920X_DXPENT0000460002 + # 邮箱客户端id + hostId: DXPENT0000460002 + # 当前操作员ic卡证书号 + certNo: DXPENT0000460002 + +sso: + witheIP: 10.5.14.108,10.5.14.109,10.5.14.110 +mq: + dir: + # 从mq队列读取存储到本地的路径 + saveXml-dir: + # 从本地路径读取报文路径 发送的MQ队列 + sendXml-dir: send + needSend: true + queue: + #发送mq队列名称 + send-to-mq: response + #读取mq队列名称 + read-from-mq: send + exchange: + #TCS回执发送到此交换,交换再把回执消息同步到其他配置的回执订阅队列 + #交换名称 + name: send.broadcast + #交换类型 + type: fanout + #routing key名称,此处为空,所有绑定交换的队列都被广播 + routing-key: transarrive + connection: + # ip: 218.28.199.134 + # port: 8004 + # vHost: NMMS + # username: tianbo + # password: vmvnv1v2VV + ip: 192.168.1.63 + port: 5672 + vHost: NMMS + username: admin + password: admin +feign: + hystrix: + enabled: true +inport-url: http://nmms1.15miaoo.com:17999 +info: + version: 1.0 + description: "新舱单辅助管理服务-统一认证、转运管理、提前运抵等" diff --git a/src/main/java/com/tianbo/analysis/SwaggerConfig.java b/src/main/java/com/tianbo/analysis/SwaggerConfig.java index 92f3f17..281d531 100755 --- a/src/main/java/com/tianbo/analysis/SwaggerConfig.java +++ b/src/main/java/com/tianbo/analysis/SwaggerConfig.java @@ -1,5 +1,6 @@ package com.tianbo.analysis; +import com.github.xiaoymin.swaggerbootstrapui.annotations.EnableSwaggerBootstrapUI; import com.google.common.base.Predicates; import org.springframework.context.annotation.Bean; import org.springframework.context.annotation.Configuration; @@ -13,6 +14,7 @@ import springfox.documentation.spring.web.plugins.Docket; import springfox.documentation.swagger2.annotations.EnableSwagger2; @Configuration +@EnableSwaggerBootstrapUI @EnableSwagger2 // Swagger的开关,表示已经启用Swagger public class SwaggerConfig { @Bean