优化监听事件加载,对Cloud应用更友好。

This commit is contained in:
thinkgem
2019-07-24 23:09:18 +08:00
parent 687d11fecb
commit fa5523650c

View File

@@ -39,8 +39,9 @@ public class CacheController extends BaseController {
@PostConstruct @PostConstruct
public void postConstruct(){ public void postConstruct(){
String rebel = System.getProperty("rebel.base"); String rebel = System.getProperty("rebel.base");
if (StringUtils.isNotBlank(rebel)){ if (StringUtils.isNotBlank(rebel) && Global
logger.debug("JRebel: 清理系统缓存..."); .getPropertyToBoolean("spring.cache.isClusterMode", "false")){
logger.info("JRebel: Cache clear...");
CacheUtils.clearCache(); CacheUtils.clearCache();
} }
} }