mirror of
https://github.com/continew-org/continew-starter.git
synced 2025-09-09 08:57:17 +08:00
refactor: 统一配置启用属性描述
This commit is contained in:
@@ -28,11 +28,24 @@ import top.continew.starter.core.constant.PropertiesConstants;
|
||||
@ConfigurationProperties(PropertiesConstants.RATE_LIMITER)
|
||||
public class RateLimiterProperties {
|
||||
|
||||
/**
|
||||
* 是否启用
|
||||
*/
|
||||
private boolean enabled = true;
|
||||
|
||||
/**
|
||||
* Key 前缀
|
||||
*/
|
||||
private String keyPrefix = "RateLimiter";
|
||||
|
||||
public boolean isEnabled() {
|
||||
return enabled;
|
||||
}
|
||||
|
||||
public void setEnabled(boolean enabled) {
|
||||
this.enabled = enabled;
|
||||
}
|
||||
|
||||
public String getKeyPrefix() {
|
||||
return keyPrefix;
|
||||
}
|
||||
|
Reference in New Issue
Block a user