修改yml文件

parent 019c2aa2
server:
port: 8181 # 修改为你想要的端口号
spring:
servlet:
multipart:
max-file-size: 10MB
max-request-size: 10MB
mvc:
pathmatch:
matching-strategy: ant_path_matcher # Spring Boot 2.6+ 需要这个配置
redis:
host: 192.168.0.181
port: 6380
timeout: 120000
database: 10
password: redis@228!
# Swagger 配置
doc:
swagger-ui:
path: /swagger-ui.html
api-docs:
path: /v3/api-docs
# Jackson配置 - 添加这里
jackson:
# 全局日期时间格式
date-format: yyyy-MM-dd'T'HH:mm:ss.SSS'Z'
time-zone: UTC
serialization:
write-dates-as-timestamps: false
write-dates-with-zone-id: true
write-durations-as-timestamps: false
deserialization:
adjust-dates-to-context-time-zone: false
fail-on-unknown-properties: false
default-property-inclusion: non_null
parser:
allow-non-numeric-numbers: true
generator:
write-numbers-as-strings: false
datasource:
dynamic:
primary: oracle
# 默认数据源
strict: false # 关闭严格模式
datasource:
# # MySQL数据源
# mysql:
# driver-class-name: com.mysql.cj.jdbc.Driver
# url: jdbc:mysql://192.168.0.181:3310/mes?useSSL=false&serverTimezone=UTC
# username: root # 替换为你的MySQL用户名
# password: root_mes@123456~ # 替换为你的MySQL密码
# Oracle数据源
oracle:
driver-class-name: oracle.jdbc.OracleDriver
url: jdbc:oracle:thin:@//192.168.0.181:1522/ORCLPDB1 # ORCL为你的Oracle实例名
username: mes # 替换为你的Oracle用户名
password: root_mes123456 # 替换为你的Oracle密码
# sqlserver:
# driver-class-name: com.microsoft.sqlserver.jdbc.SQLServerDriver
# url: jdbc:sqlserver://192.168.0.181:1434;databaseName=mes;encrypt=false
# username: sa
# password: root_mes123456
# 文件上传配置
file:
upload:
dir: uploads
mybatis-plus:
mapper-locations: classpath:mapper/**/*.xml # Mapper XML路径
type-aliases-package: com.aps.entity # 实体类包路径
configuration:
# 开启自动转义关键字
auto-delimited-keywords: true
map-underscore-to-camel-case: true # 下划线转驼峰
log-impl: org.apache.ibatis.logging.nologging.NoLoggingImpl # 打印SQL日志(调试用)
# log-impl: org.apache.ibatis.logging.stdout.StdOutImpl # 开启SQL打印
global-config:
db-config:
id-type: auto # 主键自增策略
table-underline: true
capital-mode: false
# 应用配置
app:
# 时区配置
timezone: UTC
# 跨域配置
cors:
allowed-origins: "*"
allowed-methods: "*"
allowed-headers: "*"
allow-credentials: true
# 文件上传
upload:
max-size: 10MB
allowed-extensions: .jpg,.jpeg,.png,.gif,.pdf,.doc,.docx,.xls,.xlsx
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment