Hacktoberfest 2026:维护者为十月标记出来的 issue,仍然开放、适合新手。 浏览 Hacktoberfest issue

[Enhancement] Enhance the send delayed message interface to include a message send timeout.

未关闭
#676 1 条评论 35 个 reaction 已指派 0 人 在 GitHub 查看

还没有人认领这个 Issue。

评估

难度
3/5
预计耗时
1-2 天
新手友好度
55/100
Issue 类型
功能
描述清晰度
基本清楚
活跃度
冷清
技术栈
java

调研方向

首先定位 RocketMQTemplate 和 syncSendDelayTimeSeconds 的重载,然后阅读 issue 中展示的 private syncSend 方法,以了解 timeout 和 delay mode 如何传递。检查现有的延迟发送行为以及相关测试(如果有)。当延迟消息调用方可以通过 public interface 提供自定义的 send timeout,并且所选择的 API 方案已通过测试加以记录时,即表示完成。

由索引模型根据 Issue 内容生成。

描述

Before Creating the Enhancement Request
  • I have confirmed that this should be classified as an enhancement rather than a bug/feature.
Summary

Multiple overloaded methods of RocketMQTemplate#syncSendDelayTimeSeconds do not support a custom timeout parameter.

The RocketMQTemplate#syncSend method that supports custom configurations is private.

/**
 * Same to {@link #syncSend(String, Message)} with send timeout and delay time specified in addition.
 * This function is only valid when the broker version is 5.0 or above
 *
 * @param destination formats: `topicName:tags`
 * @param message {@link org.springframework.messaging.Message}
 * @param timeout send timeout with millis
 * @param delayTime delay time for message
 * @return {@link SendResult}
 */
private SendResult syncSend(String destination, Message<?> message, long timeout, long delayTime, DelayMode mode) {
    // ......
}
Motivation

Hope to include a custom timeout parameter when sending any delayed messages.

Describe the Solution You'd Like

Add an additional overloaded method for RocketMQTemplate#syncSendDelayTimeSeconds, or change the visibility of the RocketMQTemplate#syncSend method to public.

If you agree with this enhancement, I can submit a PR.

Describe Alternatives You've Considered

Add an additional overloaded method for RocketMQTemplate#syncSendDelayTimeSeconds, or change the visibility of the RocketMQTemplate#syncSend method to public.

If you agree with this enhancement, I can submit a PR.

Additional Context

No response

主要语言
Java
星标
2.3k
派生
941
PR 合并指标
30 天内没有已合并 PR

环境准备

  • 没有 Dockerfile 或 Docker Compose 文件
  • 有 Pull Request 模板
  • 没有贡献指南

从这里开始

  1. 先读完整个 Issue,再读项目的贡献指南。
  2. 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
  3. Fork 仓库,在一个分支上完成修改。
  4. 提交 Pull Request,并在描述里引用这个 Issue 编号。

apache/rocketmq-spring 的其他 Issue

查看 apache/rocketmq-spring 的全部 Issue

相似的 Issue

更多 Java Issue

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。