Commit f52ba6cc authored by liwenbin's avatar liwenbin

增加条件类型缓存刷新接口

parent 0c5d8d94
......@@ -5,6 +5,7 @@ import com.quantgroup.asset.distribution.model.response.GlobalResponse;
import com.quantgroup.asset.distribution.service.asset.IAssetAttributeExtendConfigService;
import com.quantgroup.asset.distribution.service.authority.IAuthorityService;
import com.quantgroup.asset.distribution.service.distribute.IAssetDistributeRuleConfigService;
import com.quantgroup.asset.distribution.service.funding.IFundModuleLimitTypeService;
import com.quantgroup.asset.distribution.service.redis.IRedisService;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
......@@ -22,7 +23,7 @@ public class RedisFlushController {
private static String authKey="3ruhhdf9924hrodnfjkasdhf8209";
private final static String authKey="3ruhhdf9924hrodnfjkasdhf8209";
@Autowired
......@@ -33,6 +34,8 @@ public class RedisFlushController {
private IAuthorityService authorityService;
@Autowired
private IAssetDistributeRuleConfigService assetDistributeRuleConfigService;
@Autowired
private IFundModuleLimitTypeService limitTypeService;
/**
* 助贷资金池刷新
......@@ -54,7 +57,7 @@ public class RedisFlushController {
@RequestMapping("/authority_flush")
public GlobalResponse authorityFlush(String key, String authKey, String authPass) {
if(authKey.equals(key)) { authorityService.clearCacheByAuthKeyAndAuthPass(authKey, authPass); }
if(this.authKey.equals(key)) { authorityService.clearCacheByAuthKeyAndAuthPass(authKey, authPass); }
return GlobalResponse.success();
}
......@@ -63,4 +66,10 @@ public class RedisFlushController {
if(authKey.equals(key)) { assetDistributeRuleConfigService.clearRuleConfigCache(); }
return GlobalResponse.success();
}
@RequestMapping("/limit_type_flush")
public GlobalResponse limitTypeFlush(String key) {
if(authKey.equals(key)) { limitTypeService.clearCache(); }
return GlobalResponse.success();
}
}
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