🎨 改进结构和代码格式, 缓存常量配置 #32、删除无用引入
This commit is contained in:
1 parent
d85e7e721e
commit
bd2984164f
17 files changed
+79
-51
No files matched your search
+2
-2
@@ -18,7 +18,7 @@
|
||||
package com.pig4cloud.pigx.monitor.support;
|
||||
|
||||
import cn.hutool.core.util.StrUtil;
|
||||
import com.pig4cloud.pigx.common.core.constant.CommonConstants;
|
||||
import com.pig4cloud.pigx.common.core.constant.CacheConstants;
|
||||
import de.codecentric.boot.admin.server.domain.events.InstanceEvent;
|
||||
import de.codecentric.boot.admin.server.eventstore.InMemoryEventStore;
|
||||
import lombok.AllArgsConstructor;
|
||||
@@ -51,7 +51,7 @@ public class RedisEventStore extends InMemoryEventStore {
|
||||
log.info("保存实例事件的KEY:{},EVENT: {}", key, event.getType());
|
||||
redisTemplate.setKeySerializer(new StringRedisSerializer());
|
||||
redisTemplate.setHashValueSerializer(new Jackson2JsonRedisSerializer<>(InstanceEvent.class));
|
||||
redisTemplate.opsForHash().put(CommonConstants.EVENT_KEY, key, event);
|
||||
redisTemplate.opsForHash().put(CacheConstants.EVENT_KEY, key, event);
|
||||
});
|
||||
return super.append(events);
|
||||
}
|
||||
|
||||
-1
@@ -18,7 +18,6 @@ package com.pig4cloud.pigx.mp.entity;
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.TableId;
|
||||
import com.baomidou.mybatisplus.annotation.TableLogic;
|
||||
import com.baomidou.mybatisplus.annotation.TableName;
|
||||
import com.baomidou.mybatisplus.extension.activerecord.Model;
|
||||
import lombok.Data;
|
||||
import lombok.EqualsAndHashCode;
|
||||
|
||||
Reference in new issue
Block a user