From 97da6e9b7ab555d9e7efc39dc9609e156e92f7fa Mon Sep 17 00:00:00 2001 From: cxh Date: Fri, 8 Nov 2024 09:16:27 +0800 Subject: [PATCH 01/11] =?UTF-8?q?chore=20from=E5=B1=9E=E6=80=A7=E6=B7=BB?= =?UTF-8?q?=E5=8A=A0=E6=9B=B4=E5=8A=A0=E8=AF=A6=E7=BB=86=E7=9A=84=E6=B3=A8?= =?UTF-8?q?=E9=87=8A?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../common/mail/config/properties/MailProperties.java | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/ruoyi-common/ruoyi-common-mail/src/main/java/org/dromara/common/mail/config/properties/MailProperties.java b/ruoyi-common/ruoyi-common-mail/src/main/java/org/dromara/common/mail/config/properties/MailProperties.java index d0e78a2ca..e44aa3da3 100644 --- a/ruoyi-common/ruoyi-common-mail/src/main/java/org/dromara/common/mail/config/properties/MailProperties.java +++ b/ruoyi-common/ruoyi-common-mail/src/main/java/org/dromara/common/mail/config/properties/MailProperties.java @@ -43,7 +43,13 @@ public class MailProperties { private String pass; /** - * 发送方,遵循RFC-822标准 + * 发送方,遵循RFC-822标准
+ * 发件人可以是以下形式: + * + *
+     * 1. user@xxx.xx
+     * 2.  name <user@xxx.xx>
+     * 
*/ private String from; -- Gitee From 7fc2d31e9bd478c1c6a911adc97f4dae89826e05 Mon Sep 17 00:00:00 2001 From: cxh Date: Fri, 8 Nov 2024 09:17:27 +0800 Subject: [PATCH 02/11] =?UTF-8?q?update=20lambada=E4=BC=98=E5=8C=96?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../dromara/common/sse/core/SseEmitterManager.java | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/ruoyi-common/ruoyi-common-sse/src/main/java/org/dromara/common/sse/core/SseEmitterManager.java b/ruoyi-common/ruoyi-common-sse/src/main/java/org/dromara/common/sse/core/SseEmitterManager.java index 0bfe0ca76..fd1401d06 100644 --- a/ruoyi-common/ruoyi-common-sse/src/main/java/org/dromara/common/sse/core/SseEmitterManager.java +++ b/ruoyi-common/ruoyi-common-sse/src/main/java/org/dromara/common/sse/core/SseEmitterManager.java @@ -124,10 +124,10 @@ public class SseEmitterManager { SseMessageDto broadcastMessage = new SseMessageDto(); broadcastMessage.setMessage(sseMessageDto.getMessage()); broadcastMessage.setUserIds(sseMessageDto.getUserIds()); - RedisUtils.publish(SSE_TOPIC, broadcastMessage, consumer -> { + RedisUtils.publish(SSE_TOPIC, broadcastMessage, consumer -> log.info("SSE发送主题订阅消息topic:{} session keys:{} message:{}", - SSE_TOPIC, sseMessageDto.getUserIds(), sseMessageDto.getMessage()); - }); + SSE_TOPIC, sseMessageDto.getUserIds(), sseMessageDto.getMessage()) + ); } /** @@ -138,8 +138,8 @@ public class SseEmitterManager { public void publishAll(String message) { SseMessageDto broadcastMessage = new SseMessageDto(); broadcastMessage.setMessage(message); - RedisUtils.publish(SSE_TOPIC, broadcastMessage, consumer -> { - log.info("SSE发送主题订阅消息topic:{} message:{}", SSE_TOPIC, message); - }); + RedisUtils.publish(SSE_TOPIC, broadcastMessage, consumer -> + log.info("SSE发送主题订阅消息topic:{} message:{}", SSE_TOPIC, message) + ); } } -- Gitee From a06246b0e540a5939c0b2729e43c0c24504e579d Mon Sep 17 00:00:00 2001 From: cxh Date: Fri, 8 Nov 2024 09:18:11 +0800 Subject: [PATCH 03/11] =?UTF-8?q?update=20lambada=E4=BC=98=E5=8C=96?= =?UTF-8?q?=E4=BB=A3=E7=A0=81=EF=BC=8C=E6=9B=BF=E6=8D=A2=E7=A1=AC=E7=BC=96?= =?UTF-8?q?=E7=A0=81=E5=AD=97=E6=AE=B5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../org/dromara/system/service/impl/SysOperLogServiceImpl.java | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/ruoyi-modules/ruoyi-system/src/main/java/org/dromara/system/service/impl/SysOperLogServiceImpl.java b/ruoyi-modules/ruoyi-system/src/main/java/org/dromara/system/service/impl/SysOperLogServiceImpl.java index 750e455ac..27c2f32d5 100644 --- a/ruoyi-modules/ruoyi-system/src/main/java/org/dromara/system/service/impl/SysOperLogServiceImpl.java +++ b/ruoyi-modules/ruoyi-system/src/main/java/org/dromara/system/service/impl/SysOperLogServiceImpl.java @@ -53,8 +53,7 @@ public class SysOperLogServiceImpl implements ISysOperLogService { public TableDataInfo selectPageOperLogList(SysOperLogBo operLog, PageQuery pageQuery) { LambdaQueryWrapper lqw = buildQueryWrapper(operLog); if (StringUtils.isBlank(pageQuery.getOrderByColumn())) { - pageQuery.setOrderByColumn("oper_id"); - pageQuery.setIsAsc("desc"); + lqw.orderByDesc(SysOperLog::getOperId); } Page page = baseMapper.selectVoPage(pageQuery.build(), lqw); return TableDataInfo.build(page); -- Gitee From 2e47ddf634929933226da8d77f754d171d61ef2a Mon Sep 17 00:00:00 2001 From: cxh Date: Tue, 19 Nov 2024 09:54:19 +0800 Subject: [PATCH 04/11] =?UTF-8?q?refactor=20ThreadUtil.sleep=E4=BB=A3?= =?UTF-8?q?=E6=9B=BFThread.sleep=EF=BC=8C=E5=87=8F=E5=B0=91=E5=A4=AAtry=20?= =?UTF-8?q?catch?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../java/org/dromara/common/core/utils/Threads.java | 12 ------------ .../demo/controller/RedisCacheController.java | 7 ++----- 2 files changed, 2 insertions(+), 17 deletions(-) diff --git a/ruoyi-common/ruoyi-common-core/src/main/java/org/dromara/common/core/utils/Threads.java b/ruoyi-common/ruoyi-common-core/src/main/java/org/dromara/common/core/utils/Threads.java index ae6cfa322..82ea5caf1 100644 --- a/ruoyi-common/ruoyi-common-core/src/main/java/org/dromara/common/core/utils/Threads.java +++ b/ruoyi-common/ruoyi-common-core/src/main/java/org/dromara/common/core/utils/Threads.java @@ -14,18 +14,6 @@ import java.util.concurrent.*; @Slf4j @NoArgsConstructor(access = AccessLevel.PRIVATE) public class Threads { - - /** - * sleep等待,单位为毫秒 - */ - public static void sleep(long milliseconds) { - try { - Thread.sleep(milliseconds); - } catch (InterruptedException e) { - return; - } - } - /** * 停止线程池 * 先使用shutdown, 停止接收新任务并尝试完成所有已存在任务. diff --git a/ruoyi-modules/ruoyi-demo/src/main/java/org/dromara/demo/controller/RedisCacheController.java b/ruoyi-modules/ruoyi-demo/src/main/java/org/dromara/demo/controller/RedisCacheController.java index 341880c5d..303cf885d 100644 --- a/ruoyi-modules/ruoyi-demo/src/main/java/org/dromara/demo/controller/RedisCacheController.java +++ b/ruoyi-modules/ruoyi-demo/src/main/java/org/dromara/demo/controller/RedisCacheController.java @@ -1,5 +1,6 @@ package org.dromara.demo.controller; +import cn.hutool.core.thread.ThreadUtil; import org.dromara.common.core.constant.CacheNames; import org.dromara.common.core.domain.R; import org.dromara.common.redis.utils.RedisUtils; @@ -83,11 +84,7 @@ public class RedisCacheController { RedisUtils.setCacheObject(key, value); boolean flag = RedisUtils.expire(key, Duration.ofSeconds(10)); System.out.println("***********" + flag); - try { - Thread.sleep(11 * 1000); - } catch (InterruptedException e) { - e.printStackTrace(); - } + ThreadUtil.sleep(11 * 1000); Object obj = RedisUtils.getCacheObject(key); return R.ok(value.equals(obj)); } -- Gitee From d84a0ecfac75b9d8e233377ac3b7138ba23ea83b Mon Sep 17 00:00:00 2001 From: cxh Date: Tue, 19 Nov 2024 09:55:18 +0800 Subject: [PATCH 05/11] =?UTF-8?q?refactor=20ThreadUtil.sleep=E4=BB=A3?= =?UTF-8?q?=E6=9B=BFThread.sleep=EF=BC=8C=E5=87=8F=E5=B0=91=E5=A4=AAtry=20?= =?UTF-8?q?catch?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 去掉多余的toString,+ 拼接LocalTime.now()已自动转字符串 --- .../demo/controller/RedisLockController.java | 17 +++++------------ 1 file changed, 5 insertions(+), 12 deletions(-) diff --git a/ruoyi-modules/ruoyi-demo/src/main/java/org/dromara/demo/controller/RedisLockController.java b/ruoyi-modules/ruoyi-demo/src/main/java/org/dromara/demo/controller/RedisLockController.java index b7e096266..237b6ee2d 100644 --- a/ruoyi-modules/ruoyi-demo/src/main/java/org/dromara/demo/controller/RedisLockController.java +++ b/ruoyi-modules/ruoyi-demo/src/main/java/org/dromara/demo/controller/RedisLockController.java @@ -1,5 +1,6 @@ package org.dromara.demo.controller; +import cn.hutool.core.thread.ThreadUtil; import com.baomidou.lock.LockInfo; import com.baomidou.lock.LockTemplate; import com.baomidou.lock.annotation.Lock4j; @@ -33,13 +34,9 @@ public class RedisLockController { @Lock4j(keys = {"#key"}) @GetMapping("/testLock4j") public R testLock4j(String key, String value) { - System.out.println("start:" + key + ",time:" + LocalTime.now().toString()); - try { - Thread.sleep(10000); - } catch (InterruptedException e) { - e.printStackTrace(); - } - System.out.println("end :" + key + ",time:" + LocalTime.now().toString()); + System.out.println("start:" + key + ",time:" + LocalTime.now()); + ThreadUtil.sleep(10000); + System.out.println("end :" + key + ",time:" + LocalTime.now()); return R.ok("操作成功", value); } @@ -54,11 +51,7 @@ public class RedisLockController { } // 获取锁成功,处理业务 try { - try { - Thread.sleep(8000); - } catch (InterruptedException e) { - // - } + ThreadUtil.sleep(8000); System.out.println("执行简单方法1 , 当前线程:" + Thread.currentThread().getName()); } finally { //释放锁 -- Gitee From 3aabcef9016ca817d2221dc7b96d225b7aff558c Mon Sep 17 00:00:00 2001 From: cxh Date: Wed, 11 Dec 2024 17:47:29 +0800 Subject: [PATCH 06/11] =?UTF-8?q?update=20=E4=BD=BF=E7=94=A8StreamUtils?= =?UTF-8?q?=E5=B7=A5=E5=85=B7=E7=B1=BB=E6=96=B9=E6=B3=95=E6=9B=BF=E6=8D=A2?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../org/dromara/system/service/impl/SysDeptServiceImpl.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ruoyi-modules/ruoyi-system/src/main/java/org/dromara/system/service/impl/SysDeptServiceImpl.java b/ruoyi-modules/ruoyi-system/src/main/java/org/dromara/system/service/impl/SysDeptServiceImpl.java index eb95a48fe..1d6da45da 100644 --- a/ruoyi-modules/ruoyi-system/src/main/java/org/dromara/system/service/impl/SysDeptServiceImpl.java +++ b/ruoyi-modules/ruoyi-system/src/main/java/org/dromara/system/service/impl/SysDeptServiceImpl.java @@ -112,7 +112,7 @@ public class SysDeptServiceImpl implements ISysDeptService, DeptService { .setName(dept.getDeptName()) .setWeight(dept.getOrderNum()) .putExtra("disabled", SystemConstants.DISABLE.equals(dept.getStatus()))); - Tree tree = trees.stream().filter(it -> it.getId().longValue() == d.getDeptId()).findFirst().get(); + Tree tree = StreamUtils.findFirst(trees, it -> it.getId().longValue() == d.getDeptId()); treeList.add(tree); } } -- Gitee From 74c37f774eb46fffe40ff364f200a74f67aaf9ef Mon Sep 17 00:00:00 2001 From: cxh Date: Wed, 11 Dec 2024 18:09:00 +0800 Subject: [PATCH 07/11] =?UTF-8?q?refactor=20=E4=BC=98=E5=8C=96=EF=BC=8C?= =?UTF-8?q?=E4=B8=80=E6=A0=B7=E6=95=88=E6=9E=9C=EF=BC=8C=E5=87=8F=E5=B0=91?= =?UTF-8?q?=E4=B8=80=E8=A1=8C=E4=BB=A3=E7=A0=81?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../dromara/system/service/impl/SysLogininforServiceImpl.java | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/ruoyi-modules/ruoyi-system/src/main/java/org/dromara/system/service/impl/SysLogininforServiceImpl.java b/ruoyi-modules/ruoyi-system/src/main/java/org/dromara/system/service/impl/SysLogininforServiceImpl.java index b95baf44b..72b497eca 100644 --- a/ruoyi-modules/ruoyi-system/src/main/java/org/dromara/system/service/impl/SysLogininforServiceImpl.java +++ b/ruoyi-modules/ruoyi-system/src/main/java/org/dromara/system/service/impl/SysLogininforServiceImpl.java @@ -118,8 +118,7 @@ public class SysLogininforServiceImpl implements ISysLogininforService { .between(params.get("beginTime") != null && params.get("endTime") != null, SysLogininfor::getLoginTime, params.get("beginTime"), params.get("endTime")); if (StringUtils.isBlank(pageQuery.getOrderByColumn())) { - pageQuery.setOrderByColumn("info_id"); - pageQuery.setIsAsc("desc"); + lqw.orderByDesc(SysLogininfor::getInfoId); } Page page = baseMapper.selectVoPage(pageQuery.build(), lqw); return TableDataInfo.build(page); -- Gitee From b90f30dbe49ca3b2dfaf4dd5bd206edffbff9aae Mon Sep 17 00:00:00 2001 From: cxh Date: Wed, 11 Dec 2024 18:10:19 +0800 Subject: [PATCH 08/11] Update SysUserController.java --- .../org/dromara/system/controller/system/SysUserController.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ruoyi-modules/ruoyi-system/src/main/java/org/dromara/system/controller/system/SysUserController.java b/ruoyi-modules/ruoyi-system/src/main/java/org/dromara/system/controller/system/SysUserController.java index d4cecbe14..e1e868a6e 100644 --- a/ruoyi-modules/ruoyi-system/src/main/java/org/dromara/system/controller/system/SysUserController.java +++ b/ruoyi-modules/ruoyi-system/src/main/java/org/dromara/system/controller/system/SysUserController.java @@ -218,7 +218,7 @@ public class SysUserController extends BaseController { @GetMapping("/optionselect") public R> optionselect(@RequestParam(required = false) Long[] userIds, @RequestParam(required = false) Long deptId) { - return R.ok(userService.selectUserByIds(userIds == null ? null : List.of(userIds), deptId)); + return R.ok(userService.selectUserByIds(ArrayUtil.isEmpty(userIds) ? null : List.of(userIds), deptId)); } /** -- Gitee From fadaf3efc65cc6b6a8e667aa033db7b94be9ac78 Mon Sep 17 00:00:00 2001 From: cxh Date: Thu, 12 Dec 2024 10:11:11 +0800 Subject: [PATCH 09/11] =?UTF-8?q?update=20updateUserStatus>updateClientSta?= =?UTF-8?q?tus=20=E6=AD=A3=E7=A1=AE=E5=91=BD=E5=90=8D=E6=96=B9=E6=B3=95?= =?UTF-8?q?=EF=BC=8C=E5=AE=9E=E9=99=85=E4=BF=AE=E6=94=B9=E7=9A=84=E6=98=AF?= =?UTF-8?q?client?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../dromara/system/controller/system/SysClientController.java | 2 +- .../main/java/org/dromara/system/service/ISysClientService.java | 2 +- .../org/dromara/system/service/impl/SysClientServiceImpl.java | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/ruoyi-modules/ruoyi-system/src/main/java/org/dromara/system/controller/system/SysClientController.java b/ruoyi-modules/ruoyi-system/src/main/java/org/dromara/system/controller/system/SysClientController.java index 13be4a4a9..eaed06847 100644 --- a/ruoyi-modules/ruoyi-system/src/main/java/org/dromara/system/controller/system/SysClientController.java +++ b/ruoyi-modules/ruoyi-system/src/main/java/org/dromara/system/controller/system/SysClientController.java @@ -97,7 +97,7 @@ public class SysClientController extends BaseController { @Log(title = "客户端管理", businessType = BusinessType.UPDATE) @PutMapping("/changeStatus") public R changeStatus(@RequestBody SysClientBo bo) { - return toAjax(sysClientService.updateUserStatus(bo.getClientId(), bo.getStatus())); + return toAjax(sysClientService.updateClientStatus(bo.getClientId(), bo.getStatus())); } /** diff --git a/ruoyi-modules/ruoyi-system/src/main/java/org/dromara/system/service/ISysClientService.java b/ruoyi-modules/ruoyi-system/src/main/java/org/dromara/system/service/ISysClientService.java index d0f8a3cbe..546c3f33a 100644 --- a/ruoyi-modules/ruoyi-system/src/main/java/org/dromara/system/service/ISysClientService.java +++ b/ruoyi-modules/ruoyi-system/src/main/java/org/dromara/system/service/ISysClientService.java @@ -50,7 +50,7 @@ public interface ISysClientService { /** * 修改状态 */ - int updateUserStatus(String clientId, String status); + int updateClientStatus(String clientId, String status); /** * 校验并批量删除客户端管理信息 diff --git a/ruoyi-modules/ruoyi-system/src/main/java/org/dromara/system/service/impl/SysClientServiceImpl.java b/ruoyi-modules/ruoyi-system/src/main/java/org/dromara/system/service/impl/SysClientServiceImpl.java index 1c6924320..4f6e676df 100644 --- a/ruoyi-modules/ruoyi-system/src/main/java/org/dromara/system/service/impl/SysClientServiceImpl.java +++ b/ruoyi-modules/ruoyi-system/src/main/java/org/dromara/system/service/impl/SysClientServiceImpl.java @@ -123,7 +123,7 @@ public class SysClientServiceImpl implements ISysClientService { */ @CacheEvict(cacheNames = CacheNames.SYS_CLIENT, key = "#clientId") @Override - public int updateUserStatus(String clientId, String status) { + public int updateClientStatus(String clientId, String status) { return baseMapper.update(null, new LambdaUpdateWrapper() .set(SysClient::getStatus, status) -- Gitee From 271c4c2bfcde64efd4cb155bebcdd6658fa988d2 Mon Sep 17 00:00:00 2001 From: cxh Date: Sat, 28 Dec 2024 16:56:44 +0800 Subject: [PATCH 10/11] =?UTF-8?q?update=20=E4=BC=98=E5=8C=96=E5=A4=9A?= =?UTF-8?q?=E7=A7=9F=E6=88=B7=E6=8F=92=E4=BB=B6=E5=88=9D=E5=A7=8B=E5=8C=96?= =?UTF-8?q?=E6=B5=81=E7=A8=8B?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 启用多租户才需要初始化,不启用则不初始化 --- .../dromara/common/mybatis/config/MybatisPlusConfig.java | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/ruoyi-common/ruoyi-common-mybatis/src/main/java/org/dromara/common/mybatis/config/MybatisPlusConfig.java b/ruoyi-common/ruoyi-common-mybatis/src/main/java/org/dromara/common/mybatis/config/MybatisPlusConfig.java index 00c26912e..83d29b5e9 100644 --- a/ruoyi-common/ruoyi-common-mybatis/src/main/java/org/dromara/common/mybatis/config/MybatisPlusConfig.java +++ b/ruoyi-common/ruoyi-common-mybatis/src/main/java/org/dromara/common/mybatis/config/MybatisPlusConfig.java @@ -37,8 +37,11 @@ public class MybatisPlusConfig { MybatisPlusInterceptor interceptor = new MybatisPlusInterceptor(); // 多租户插件 必须放到第一位 try { - TenantLineInnerInterceptor tenant = SpringUtils.getBean(TenantLineInnerInterceptor.class); - interceptor.addInnerInterceptor(tenant); + boolean enableTenant = Boolean.parseBoolean(SpringUtils.getProperty("tenant.enable")); + if (enableTenant) { + TenantLineInnerInterceptor tenant = SpringUtils.getBean(TenantLineInnerInterceptor.class); + interceptor.addInnerInterceptor(tenant); + } } catch (BeansException ignore) { } // 数据权限处理 -- Gitee From 1565f4037bd592f3d1bd9127d237d03431036ce2 Mon Sep 17 00:00:00 2001 From: cxh Date: Sat, 28 Dec 2024 17:05:23 +0800 Subject: [PATCH 11/11] =?UTF-8?q?=E5=90=8C=E6=AD=A5=E5=AE=98=E6=96=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../dromara/common/sse/core/SseEmitterManager.java | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/ruoyi-common/ruoyi-common-sse/src/main/java/org/dromara/common/sse/core/SseEmitterManager.java b/ruoyi-common/ruoyi-common-sse/src/main/java/org/dromara/common/sse/core/SseEmitterManager.java index a9a367627..ba1ce5696 100644 --- a/ruoyi-common/ruoyi-common-sse/src/main/java/org/dromara/common/sse/core/SseEmitterManager.java +++ b/ruoyi-common/ruoyi-common-sse/src/main/java/org/dromara/common/sse/core/SseEmitterManager.java @@ -131,10 +131,10 @@ public class SseEmitterManager { SseMessageDto broadcastMessage = new SseMessageDto(); broadcastMessage.setMessage(sseMessageDto.getMessage()); broadcastMessage.setUserIds(sseMessageDto.getUserIds()); - RedisUtils.publish(SSE_TOPIC, broadcastMessage, consumer -> + RedisUtils.publish(SSE_TOPIC, broadcastMessage, consumer -> { log.info("SSE发送主题订阅消息topic:{} session keys:{} message:{}", - SSE_TOPIC, sseMessageDto.getUserIds(), sseMessageDto.getMessage()) - ); + SSE_TOPIC, sseMessageDto.getUserIds(), sseMessageDto.getMessage()); + }); } /** @@ -145,8 +145,8 @@ public class SseEmitterManager { public void publishAll(String message) { SseMessageDto broadcastMessage = new SseMessageDto(); broadcastMessage.setMessage(message); - RedisUtils.publish(SSE_TOPIC, broadcastMessage, consumer -> - log.info("SSE发送主题订阅消息topic:{} message:{}", SSE_TOPIC, message) - ); + RedisUtils.publish(SSE_TOPIC, broadcastMessage, consumer -> { + log.info("SSE发送主题订阅消息topic:{} message:{}", SSE_TOPIC, message); + }); } } -- Gitee