有效期配置和读取
- shopTNT中涉及到有效期设置应该定义在application.properties中
- 以shopTNT.timeout开头
- 相应的功能、配置项及默认值:
功能 | 配置项 | 默认值 | 单位 |
---|---|---|---|
access_token有效期 | access_token | 15 | 分钟 |
refresh_token有效期 | refresh_token | 30 | 分钟 |
图片验证码有效期 | captcha | 10 | 分钟 |
短信验证码有效期 | smscode | 10 | 分钟 |
相关类规定
相关类的定义在:
com.enation.app.shopTNT.framework.shopTNTConfig
相应的属性名
class shopTNTConfig{
int accessTokenTimeout;
int refreshTokenTimeout;
int captchaTimout;
int smscodeTimout;
//other config
}
参考文档
https://docs.spring.io/spring-boot/docs/current/reference/html/boot-features-external-config.html
参考类:
com.enation.app.shopTNT.framework.redis.configure.RedisConnectionConfig