#配置日志 logging: config : classpath:logback-spring.xml dirpath: D:/xlyweberp/logs/xlyAi level: root: info com.xly: debug org.springframework: warn dev.langchain4j: DEBUG server: port: 8099 servlet: context-path: /xlyAi encoding: charset: UTF-8 enabled: true spring: application: name: xlyAi version: 1.0.0 thymeleaf: prefix: classpath:/templates/ suffix: .html mode: HTML encoding: UTF-8 cache: false # 开发时关闭缓存 datasource: driver-class-name: com.mysql.cj.jdbc.Driver # 连接串与口令一律来自环境变量(DB_URL/DB_USERNAME/DB_PASSWORD)——仓库里不放任何生产凭据。 # 单语句执行:allowMultiQueries 关闭,堆叠语句在驱动层就被拒。 url: ${DB_URL:jdbc:mysql://127.0.0.1:33307/xlyweberp_saas?allowPublicKeyRetrieval=true&keepAlive=true&autoReconnect=true&autoReconnectForPools=true&connectTimeout=30000&socketTimeout=180000&nullCatalogMeansCurrent=true&allowMultiQueries=false&useSSL=false&useUnicode=true&characterEncoding=utf-8&failOverReadOnly=false&serverTimezone=Asia/Shanghai&zeroDateTimeBehavior=CONVERT_TO_NULL} username: ${DB_USERNAME:} password: ${DB_PASSWORD:} # 连接池配置(使用HikariCP) hikari: maximum-pool-size: 20 minimum-idle: 10 connection-timeout: 30000 idle-timeout: 600000 max-lifetime: 1800000 # REDIS (RedisProperties) data: redis: host: ${REDIS_HOST:127.0.0.1} password: ${REDIS_PASSWORD:} port: ${REDIS_PORT:16379} database: 0 # index timeout: 30000ms # 连接超时时长(毫秒) block-when-exhausted: true lettuce: pool: max-active: 8 # 连接池最大连接数 max-idle: 8 # 连接池最大空闲连接 min-idle: 0 # 连接池最小空闲连接 # Actuator配置 management: endpoints: web: exposure: include: health,info,metrics endpoint: health: show-details: always # LLM:OpenAI 兼容协议(Ollama /v1、vLLM、云端网关皆可,换供应商只改这里) llm: base-url: ${LLM_BASE_URL:http://112.82.245.194:41434/v1} api-key: ${LLM_API_KEY:ollama} # Ollama 不校验(任意非空);云端填真实 key chat-model: ${LLM_CHAT_MODEL:qwen3.6-27b-iq3:latest} erp: baseurl: ${ERP_BASEURL:http://118.178.19.35:8080/xlyEntry_saas} # dev-login = 无 token 时以 dev 账号(管理员)执行。生产必须保持 false, # 否则任何未登录请求都会拿到管理员身份。本地开发在 application-saaslocal.yml 里开。 dev-login: enabled: false