application.yml 1.7 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879
  1. server:
  2. port: 9001
  3. eureka:
  4. client:
  5. serviceUrl:
  6. defaultZone: http://admin:admin123@localhost:8761/eureka/eureka/
  7. spring:
  8. application:
  9. name: student-server
  10. datasource:
  11. name: test
  12. url: jdbc:mysql://47.99.212.176:3306/mec_dev?useUnicode=true&characterEncoding=UTF8&serverTimezone=Asia/Shanghai
  13. username: mec_dev
  14. password: mec_dev
  15. # 使用druid数据源
  16. type: com.alibaba.druid.pool.DruidDataSource
  17. driver-class-name: com.mysql.cj.jdbc.Driver
  18. filters: stat
  19. maxActive: 20
  20. initialSize: 1
  21. maxWait: 60000
  22. minIdle: 1
  23. timeBetweenEvictionRunsMillis: 60000
  24. minEvictableIdleTimeMillis: 300000
  25. validationQuery: select 'x'
  26. testWhileIdle: true
  27. testOnBorrow: false
  28. testOnReturn: false
  29. poolPreparedStatements: true
  30. maxOpenPreparedStatements: 20
  31. redis:
  32. host: 47.99.212.176
  33. port: 6379
  34. password:
  35. database: 0
  36. #连接超时时间(毫秒)
  37. timeout: 10000
  38. pool:
  39. #连接池最大连接数(使用负值表示没有限制)
  40. max-active: 10
  41. #连接池最大阻塞等待时间(使用负值表示没有限制)
  42. max-wait: -1
  43. #连接池中的最大空闲连接
  44. max-idle: 10
  45. #连接池中的最小空闲连接
  46. min-idle: 0
  47. mybatis:
  48. mapperLocations: classpath:config/mybatis/*.xml
  49. swagger:
  50. base-package: com.ym.mec.student.controller
  51. ##认证
  52. security:
  53. oauth2:
  54. client:
  55. client-id: student
  56. client-secret: student
  57. resource:
  58. token-info-uri: http://localhost:8001/oauth/check_token
  59. #spring boot admin 相关配置
  60. management:
  61. endpoints:
  62. web:
  63. exposure:
  64. include: "*"
  65. endpoint:
  66. health:
  67. show-details: ALWAYS
  68. feign:
  69. hystrix:
  70. enabled: true