初始化代码

This commit is contained in:
lpd
2026-04-09 11:52:02 +08:00
parent bb5937c5b7
commit 8319ac9516
565 changed files with 965 additions and 658 deletions

View File

@@ -10,7 +10,7 @@ import org.springframework.context.annotation.Bean;
/**
* RabbitMQ 消息队列配置类
*
* @author lyz源码
* @author 芋道源码
*/
@AutoConfiguration
@Slf4j

View File

@@ -34,7 +34,7 @@ import java.util.Properties;
/**
* Redis 消息队列 Consumer 配置类
*
* @author lyz源码
* @author 芋道源码
*/
@Slf4j
@EnableScheduling // 启用定时任务,用于 RedisPendingMessageResendJob 重发消息

View File

@@ -13,7 +13,7 @@ import java.util.List;
/**
* Redis 消息队列 Producer 配置类
*
* @author lyz源码
* @author 芋道源码
*/
@Slf4j
@AutoConfiguration(after = LyzsysRedisAutoConfiguration.class)

View File

@@ -17,7 +17,7 @@ import java.util.List;
/**
* Redis MQ 操作模板类
*
* @author lyz源码
* @author 芋道源码
*/
@AllArgsConstructor
public class RedisMQTemplate {

View File

@@ -7,7 +7,7 @@ import cn.iocoder.lyzsys.framework.mq.redis.core.message.AbstractRedisMessage;
* 通过拦截器,作为插件机制,实现拓展。
* 例如说,多租户场景下的 MQ 消息处理
*
* @author lyz源码
* @author 芋道源码
*/
public interface RedisMessageInterceptor {

View File

@@ -17,7 +17,7 @@ import java.util.List;
*
* @see <a href="https://www.cnblogs.com/nanxiang/p/16179519.html">记一次 redis stream 数据类型内存不释放问题</a>
*
* @author lyz源码
* @author 芋道源码
*/
@Slf4j
@AllArgsConstructor

View File

@@ -8,7 +8,7 @@ import java.util.Map;
/**
* Redis 消息抽象基类
*
* @author lyz源码
* @author 芋道源码
*/
@Data
public abstract class AbstractRedisMessage {

View File

@@ -6,7 +6,7 @@ import com.fasterxml.jackson.annotation.JsonIgnore;
/**
* Redis Channel Message 抽象类
*
* @author lyz源码
* @author 芋道源码
*/
public abstract class AbstractRedisChannelMessage extends AbstractRedisMessage {

View File

@@ -18,7 +18,7 @@ import java.util.List;
*
* @param <T> 消息类型。一定要填写噢,不然会报错
*
* @author lyz源码
* @author 芋道源码
*/
public abstract class AbstractRedisChannelMessageListener<T extends AbstractRedisChannelMessage> implements MessageListener {

View File

@@ -6,7 +6,7 @@ import com.fasterxml.jackson.annotation.JsonIgnore;
/**
* Redis Stream Message 抽象类
*
* @author lyz源码
* @author 芋道源码
*/
public abstract class AbstractRedisStreamMessage extends AbstractRedisMessage {

View File

@@ -20,7 +20,7 @@ import java.util.List;
*
* @param <T> 消息类型。一定要填写噢,不然会报错
*
* @author lyz源码
* @author 芋道源码
*/
public abstract class AbstractRedisStreamMessageListener<T extends AbstractRedisStreamMessage>
implements StreamListener<String, ObjectRecord<String, String>> {
@@ -69,7 +69,7 @@ public abstract class AbstractRedisStreamMessageListener<T extends AbstractRedis
this.onMessage(messageObj);
// ack 消息消费完成
redisMQTemplate.getRedisTemplate().opsForStream().acknowledge(group, message);
// TODO 鹭鹭:需要额外考虑以下几个点:
// TODO 芋艿:需要额外考虑以下几个点:
// 1. 处理异常的情况
// 2. 发送日志;以及事务的结合
// 3. 消费日志;以及通用的幂等性