Retry-After parser accepts invalid delay-seconds values
维护者通常 2 天内回复
评估
- 难度
- 2/5
- 预计耗时
- 1-3 小时
- 新手友好度
- 82/100
- Issue 类型
- 缺陷
- 描述清晰度
- 描述清楚
- 活跃度
- 活跃
- 技术栈
- java
调研方向
从 RetryUtil.retryAfterNanos 及其在 io.opentelemetry.exporter.internal.RetryUtilTest 中的现有测试开始。检查解析器如何处理 +30、-0 和 ٣٠,然后运行该测试类。完成标准是每个格式错误的值都返回 OptionalLong.empty(),而有效的 ASCII 延迟秒数值仍能继续解析。
由索引模型根据 Issue 内容生成。
描述
Describe the bug
The internal RetryUtil.retryAfterNanos parser accepts +30 as a 30-second delay and -0 as zero. Long.parseLong also accepts non-ASCII decimal digits. These values do not match the HTTP Retry-After delay-seconds grammar (1*DIGIT, ASCII 0–9).
The JDK and OkHttp HTTP senders use this parser. An accepted malformed value overrides their ordinary retry backoff instead of being ignored.
Steps to reproduce
In the existing io.opentelemetry.exporter.internal.RetryUtilTest, pass +30, -0, or ٣٠ to RetryUtil.retryAfterNanos(value, Instant.EPOCH).
What did you expect to see?
OptionalLong.empty(), as for other malformed values, so the ordinary retry policy applies.
What did you see instead?
OptionalLong.of(30000000000L) for +30; OptionalLong.of(0L) for -0; non-ASCII decimal digits are also parsed as a delay.
What version and what artifacts are you using?
Artifacts: exporters/common (used by the JDK and OkHttp senders)
Version: source checkout at f02bddc
How referenced: direct source checkout
Environment
Compiler: Temurin 25.0.5
OS: macOS 15.5
Additional context
The HTTP grammar is defined in RFC 9110 section 10.2.3.
- 主要语言
- Java
- 星标
- 2.5k
- 派生
- 1k
- 平均合并
- 4 天 3 小时
- 30 天内合并 PR
- 49
环境准备
- 没有 Dockerfile 或 Docker Compose 文件
- 没有 Pull Request 模板
- 阅读贡献指南
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
open-telemetry/opentelemetry-java 的其他 Issue
-
PrometheusComponentProvider promotes all resource attributes when resource_constant_labels is empty ({})可能已有人在做 @rooks-ns 于 1 天前认领。 未关闭
难度 2/5 1-3 小时 新手友好度 72/100
open-telemetry/opentelemetry-java#9014 ·
维护者通常 2 天内回复
-
MetricReusableDataMarshaler passes MetricData count instead of data point count to otel.sdk.exporter.metric_data_point.{inflight,exported}可能已有人在做 @goutamadwant 今天认领。 未关闭
难度 2/5 1-3 小时 新手友好度 76/100
open-telemetry/opentelemetry-java#9011 · 1 条评论 ·
维护者通常 2 天内回复
-
Fix `otel.sdk.log.created` counting semantics可能已有人在做 @anuraaga 于 94 天前认领。 未关闭
难度 2/5 1-3 小时 新手友好度 76/100
open-telemetry/opentelemetry-java#8688 ·
维护者通常 2 天内回复
-
Add experimental view_matching_mode (composable metric views) support可能已有人在做 @rooks-ns 今天认领。 未关闭
难度 5/5 一周以上 新手友好度 35/100
open-telemetry/opentelemetry-java#9013 ·
维护者通常 2 天内回复
-
Span/log processors and PeriodicMetricReader use static ComponentId, causing all instances to share otel.component.name "<type>/0"可能已有人在做 @goutamadwant 今天认领。 未关闭
难度 3/5 1-2 天 新手友好度 68/100
open-telemetry/opentelemetry-java#9012 ·
维护者通常 2 天内回复
查看 open-telemetry/opentelemetry-java 的全部 Issue
相似的 Issue
-
hermes-queue
难度 1/5 1 小时以内 新手友好度 72/100
chrisalunlloyd2-sudo/mindpalace#349 ·
维护者通常 1 天内回复
-
bug priority: medium Review effort [1-5]: 2 status: needs-triage type: bug
难度 2/5 1-3 小时 新手友好度 78/100
carlos-emr/carlos#5818 ·
维护者通常 1 天内回复
-
bug good first issue help wanted tooling
难度 2/5 1-3 小时 新手友好度 78/100
appmonster007/kmip-adapter#100 ·
-
accepted good first issue java
难度 1/5 1 小时以内 新手友好度 88/100
维护者通常 1 天内回复
-
bug main ui
难度 2/5 1-3 小时 新手友好度 78/100
openhab/openhab-webui#4671 ·
维护者通常 1 天内回复