Skip to content

release: prepare v0.1.3-rc.11#41

Merged
vansour merged 1 commit intomainfrom
release/v0.1.3-rc.11
Apr 13, 2026
Merged

release: prepare v0.1.3-rc.11#41
vansour merged 1 commit intomainfrom
release/v0.1.3-rc.11

Conversation

@vansour
Copy link
Copy Markdown
Owner

@vansour vansour commented Apr 13, 2026

Summary

  • prepare the v0.1.3-rc.11 release candidate
  • complete HTTP/3 Phase 6 and Phase 7 implementation, telemetry, and release-gate assets
  • bump the workspace version to 0.1.3-rc.11 and add repository release notes

Highlights

  • add downstream HTTP/3 0-RTT support with route-level replay safety
  • add listener-level HTTP/3 / QUIC runtime telemetry to status, traffic, and admin snapshot output
  • add focused HTTP/3 soak and release-gate scripts
  • update release preflight and GitHub release workflow to run the HTTP/3 release gate
  • clean up old HTTP/3 remediation/plan docs in favor of the nginx-alignment plan and phase docs

Release Notes

Validation

  • ./scripts/prepare-release.sh --tag v0.1.3-rc.11 --allow-dirty

Copilot AI review requested due to automatic review settings April 13, 2026 07:52
@chatgpt-codex-connector
Copy link
Copy Markdown

You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard.

@vansour vansour enabled auto-merge (squash) April 13, 2026 07:52
@coderabbitai
Copy link
Copy Markdown

coderabbitai Bot commented Apr 13, 2026

Caution

Review failed

Pull request was closed or merged during review

📝 Walkthrough

Summary by CodeRabbit

发布说明 v0.1.3-rc.11

  • 新增功能

    • HTTP/3 0-RTT 早期数据支持:可通过 server.http3.early_data 启用,并使用 location.allow_early_data 控制路由的重放安全性,不安全路由返回 425 Too Early 响应
    • HTTP/3 运行时遥测:新增连接/流活跃计数、重试统计、请求处理错误和连接关闭原因计数,在 statuscounters 和快照输出中可见
    • HTTP/3 发布验证闸门:新增专用脚本用于回归测试和压力测试
  • 改进

    • 管理员快照架构版本升级至 v13,新增 HTTP/3 配置和运行时字段
    • 扩展 checkstatuscounters 命令输出,包含 HTTP/3 监听器配置和活动指标

总体概览

本变更实现了HTTP/3 Phase 7发布,包括0-RTT早期数据支持、连接重试、运行时遥测和配置验证。更新了版本至0.1.3-rc.11,添加了多个发布门控脚本,扩展了管理员接口以报告HTTP/3相关指标。

变更清单

群组 / 文件 摘要
版本和文档更新
Cargo.toml, README.md, RELEASE_NOTES_v0.1.3-rc.11.md, ARCHITECTURE_*.md
将工作区版本从0.1.3-rc.10升级至0.1.3-rc.11;删除了HTTP/3规划相关的旧文档;添加了v0.1.3-rc.11发布说明,记录early-data、重试和运行时遥测功能;更新README以反映新的HTTP/3基准和发布脚本。
工作流和发布脚本
.github/workflows/release.yml, scripts/run-http3-*.sh, scripts/prepare-release.sh
在发布验证流程中添加了HTTP/3发布门控步骤;新增专用脚本run-http3-gate.shrun-http3-soak.shrun-http3-release-gate.shrun-http3-phase0.sh用于HTTP/3回归测试、压力测试和发布协调。
配置模型和验证
crates/rginx-config/src/model.rs, crates/rginx-config/src/compile/server.rs, crates/rginx-config/src/validate/server.rs, crates/rginx-config/src/compile/tests.rs, crates/rginx-config/src/validate/tests.rs
扩展Http3ConfigLocationConfig结构体,添加early-data、重试、GSO和主机密钥路径等配置字段;实现相应编译逻辑并添加全面的验证规则(包括early-data与TLS会话恢复的兼容性检查)。
核心配置和数据结构
crates/rginx-core/src/config.rs, crates/rginx-core/src/config/route.rs, crates/rginx-core/src/config/tests.rs
ListenerHttp3ListenerTransportBindingRoute添加新字段以支持HTTP/3参数和early-data路由决策。
管理员CLI和状态报告
crates/rginx-app/src/admin_cli/status.rs, crates/rginx-app/src/admin_cli/counters.rs, crates/rginx-app/src/admin_cli/traffic.rs, crates/rginx-app/src/main.rs
扩展状态/计数器/流量输出以包含HTTP/3运行时遥测、配置参数和early-data计数器;添加了顶级检查摘要字段用于early-data启用的监听器数。
HTTP/3服务器实现
crates/rginx-http/src/server/http3.rs, crates/rginx-http/src/proxy/clients/http3.rs
实现early-data握手流程、QUIC重试发行、主机密钥持久化(带原子文件操作)、连接关闭跟踪和各类请求错误记录;将HTTP/3上游客户端重构为缓存的端点和会话,支持流式响应体。
请求处理和TLS
crates/rginx-http/src/handler/dispatch.rs, crates/rginx-http/src/handler/response.rs, crates/rginx-http/src/handler/mod.rs, crates/rginx-http/src/tls/acceptor.rs, crates/rginx-http/src/client_ip.rs
添加early-data路由检查和425 Too Early拒绝响应;通过TLS配置设置max_early_data_size;在连接元数据中传播early-data标志;支持客户证书和early-data的TLS服务器配置。
状态管理和遥测
crates/rginx-http/src/state/connections.rs, crates/rginx-http/src/state/counters.rs, crates/rginx-http/src/state/snapshots.rs, crates/rginx-http/src/state/lifecycle.rs, crates/rginx-http/src/state/traffic.rs, crates/rginx-http/src/state/helpers.rs, crates/rginx-http/src/state/tls_runtime/listeners.rs
添加HTTP/3活跃连接/请求流管理、early-data接受/拒绝计数、重试发行/失败、各类请求/响应错误、连接关闭原因分类遥测;扩展快照结构以包含HTTP/3运行时数据。
运行时和启动
crates/rginx-runtime/src/bootstrap/listeners.rs, crates/rginx-runtime/src/restart.rs, crates/rginx-runtime/src/admin.rs, crates/rginx-http/Cargo.toml, crates/rginx-runtime/Cargo.toml
将UDP套接字管理从单个套接字扩展到向量(支持SO_REUSEPORT多工作进程绑定);更新HTTP/3端点管理以支持多套接字;将快照架构版本从12升级到13;添加依赖项(aws-lc-rs, quinn-proto, socket2)。
测试覆盖
crates/rginx-app/tests/admin/commands.rs, crates/rginx-app/tests/admin/snapshot.rs, crates/rginx-app/tests/check.rs, crates/rginx-app/tests/http3.rs, crates/rginx-http/src/state/tests.rs, crates/rginx-http/src/handler/tests.rs, crates/rginx-http/src/router.rs, crates/rginx-http/src/transition.rs, crates/rginx-http/src/server/connection.rs, crates/rginx-runtime/src/bootstrap/shutdown.rs, crates/rginx-http/src/support/mod.rs
大幅扩展测试以覆盖HTTP/3早期数据路由、重试行为、mTLS身份验证模式、运行时遥测、快照模式变更、流式响应解析和继承的UDP套接字处理。

序列图

sequenceDiagram
    participant Client
    participant ServerAccept as HTTP/3 Accept<br/>Loop
    participant KeyMgmt as Host Key<br/>Management
    participant TlsLayer as TLS<br/>Handshake
    participant EarlyData as Early Data<br/>Check
    participant Router as Route<br/>Dispatch
    participant Response as Response<br/>Handler

    Client->>ServerAccept: QUIC Initial Packet
    ServerAccept->>KeyMgmt: Load/Create host key
    KeyMgmt->>KeyMgmt: Persist to disk<br/>(atomic rename)
    KeyMgmt-->>ServerAccept: Key material ready
    
    ServerAccept->>ServerAccept: Issue QUIC retry<br/>(if configured)
    ServerAccept->>TlsLayer: TLS 1.3 handshake
    
    alt Early Data Enabled
        Client->>TlsLayer: 0-RTT with early data
        TlsLayer->>EarlyData: Check route.allow_early_data
        
        alt Route allows early data
            EarlyData->>Router: Route request
            Router->>Response: Generate response
            Response-->>Client: 200 OK
            Note over EarlyData: Record accepted
        else Route rejects early data
            EarlyData-->>Client: 425 Too Early
            Note over EarlyData: Record rejected
        end
    else Early Data Disabled or No Early Data
        Client->>TlsLayer: Regular handshake completion
        TlsLayer->>Router: Route request normally
        Router->>Response: Generate response
        Response-->>Client: 200 OK
    end
    
    ServerAccept->>ServerAccept: Record connection close reason
    Note over ServerAccept: Telemetry: active connections,<br/>retry issued/failed, request errors
Loading

估计代码审查工作量

🎯 5 (Critical) | ⏱️ ~120 分钟

可能相关的PR

  • refactor: split large modules into directories #36: 修改了管理员CLI模块布局和子模块(如admin_cli/mod.rs、counters.rs、status.rs),与本PR的HTTP/3管理员/状态/计数器添加直接相关。
  • Prepare v0.1.3-rc.5 release #34: 修改了仓库发布/CI协调(GitHub Actions验证工作流和发布前检查脚本),与本PR添加的HTTP/3发布门控步骤相关。
  • Prepare v0.1.3-rc.9 #39: 是发布前准备更新,修改发布门控/脚本、管理员快照架构和README/版本管理,作为HTTP/3发布进展的一部分。

诗歌

🐰 早期数据在0-RTT中飞舞,
重试机制让连接更稳妥,
多套接字绑定承载新流量,
遥测闪闪发光映照途径,
HTTP/3 Phase 7齐聚一堂,
兔兔欢欣鼓舞庆贺时刻!🥕✨

🚥 Pre-merge checks | ✅ 2 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 34.94% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (2 passed)
Check name Status Explanation
Title check ✅ Passed PR标题准确概括了主要变更:发布v0.1.3-rc.11版本候选版本,直接反映了PR目标。
Description check ✅ Passed PR描述充分解释了变更内容,包括HTTP/3实现、遥测、发布脚本和版本更新等关键信息,与变更集合紧密相关。

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch release/v0.1.3-rc.11

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@vansour vansour merged commit ee8d7f9 into main Apr 13, 2026
7 of 8 checks passed
@vansour vansour deleted the release/v0.1.3-rc.11 branch April 13, 2026 07:56
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Prepares the v0.1.3-rc.11 release candidate by finishing HTTP/3 Phase 6/7 work (0-RTT + replay-safety, QUIC/HTTP/3 runtime telemetry, retry/host-key support), adding dedicated HTTP/3 release-gate/soak automation, and updating operator-facing outputs (status/traffic/snapshot/check) plus release docs/workflows.

Changes:

  • Add HTTP/3 0-RTT support with route-level replay-safety enforcement and new counters/telemetry surfaced via admin/status/traffic/snapshot.
  • Add QUIC runtime configuration controls (streams/buffers/CID limits/migration, retry + host key material) and improve listener UDP socket handling for accept-workers/reuseport.
  • Add HTTP/3-focused gate/soak scripts and wire them into release preparation + GitHub release workflow; update release notes/docs accordingly.

Reviewed changes

Copilot reviewed 56 out of 57 changed files in this pull request and generated 5 comments.

Show a summary per file
File Description
scripts/run-http3-soak.sh New focused HTTP/3 soak runner with optional netem/MTU fault injection.
scripts/run-http3-release-gate.sh New Phase 7 release-gate wrapper (gate + soak + optional nginx compare).
scripts/run-http3-phase0.sh New baseline runner for Phase 0 style HTTP/3 smoke/soak subset.
scripts/run-http3-gate.sh New dedicated HTTP/3 regression gate test matrix runner.
scripts/prepare-release.sh Runs the HTTP/3 release gate during release preflight.
RELEASE_NOTES_v0.1.3-rc.11.md Adds release notes for v0.1.3-rc.11.
README.md Bumps displayed version and updates HTTP/3 plan/gate command documentation.
crates/rginx-runtime/src/restart.rs Extends restart FD inheritance to handle multiple UDP sockets per HTTP/3 listener.
crates/rginx-runtime/src/bootstrap/shutdown.rs Updates test fixtures for the new allow_early_data route field.
crates/rginx-runtime/src/bootstrap/listeners.rs Binds per-worker UDP sockets (reuseport) and starts multiple HTTP/3 accept workers/endpoints.
crates/rginx-runtime/src/admin.rs Bumps admin snapshot schema version to 13.
crates/rginx-runtime/Cargo.toml Adds socket2 dependency for UDP socket options/binding.
crates/rginx-http/src/transition.rs Updates tests to include newly added HTTP/3 listener config fields.
crates/rginx-http/src/tls/acceptor.rs Enables HTTP/3 early-data via rustls config and relaxes prior client-auth restriction.
crates/rginx-http/src/state/traffic.rs Adds listener-level HTTP/3 runtime telemetry to traffic snapshots.
crates/rginx-http/src/state/tls_runtime/listeners.rs Adds HTTP/3 transport/runtime config fields to TLS listener status snapshots.
crates/rginx-http/src/state/tests.rs Adds/updates tests for HTTP/3 runtime telemetry and early-data counters.
crates/rginx-http/src/state/snapshots.rs Extends snapshot schema with HTTP/3 telemetry, early-data counters, and binding metadata.
crates/rginx-http/src/state/lifecycle.rs Populates new HTTP/3 telemetry fields in runtime status snapshots.
crates/rginx-http/src/state/helpers.rs Adds helper to render HTTP/3 runtime telemetry snapshots from counters.
crates/rginx-http/src/state/counters.rs Adds HTTP/3 active/total counters and early-data accepted/rejected counters.
crates/rginx-http/src/state/connections.rs Adds guards and recorders for HTTP/3 active streams/connections, retry/errors, and early-data acceptance/rejection.
crates/rginx-http/src/server/http3.rs Implements downstream HTTP/3 retry, host-key material, QUIC runtime tuning, early-data tracking, and richer telemetry.
crates/rginx-http/src/server/connection.rs Adds early_data into connection metadata; exposes TLS handshake failure classifier to HTTP/3 path.
crates/rginx-http/src/router.rs Updates tests for the new allow_early_data route field.
crates/rginx-http/src/proxy/clients/http3.rs Reworks upstream HTTP/3 client to reuse endpoints/sessions and stream response bodies (avoid full buffering).
crates/rginx-http/src/handler/tests.rs Updates handler tests for the new allow_early_data route field and connection metadata.
crates/rginx-http/src/handler/response.rs Adds a 425 Too Early response helper.
crates/rginx-http/src/handler/mod.rs Injects early-data boolean into request extensions for downstream dispatch decisions.
crates/rginx-http/src/handler/dispatch.rs Enforces replay-safe routing for 0-RTT and records accepted/rejected early-data metrics.
crates/rginx-http/src/client_ip.rs Extends connection peer metadata with early_data.
crates/rginx-http/Cargo.toml Adds aws-lc-rs and quinn-proto for QUIC token/reset/CID generation support.
crates/rginx-core/src/config/tests.rs Updates config tests for enriched HTTP/3 binding fields and allow_early_data.
crates/rginx-core/src/config/route.rs Adds allow_early_data to compiled Route model.
crates/rginx-core/src/config.rs Extends ListenerHttp3 + ListenerTransportBinding with QUIC runtime settings and early-data flags.
crates/rginx-config/src/validate/tests.rs Adds validation coverage for new HTTP/3 transport settings and early-data constraints.
crates/rginx-config/src/validate/server.rs Validates new HTTP/3 fields (streams/buffers/CID limit/retry/host-key/early-data prerequisites).
crates/rginx-config/src/model.rs Extends config model for HTTP/3 tuning and route-level allow_early_data.
crates/rginx-config/src/compile/tests.rs Adds compile tests for HTTP/3 defaults and host-key path resolution; updates fixtures for new route field.
crates/rginx-config/src/compile/server.rs Compiles HTTP/3 tuning fields with defaults; resolves host-key paths relative to base dir.
crates/rginx-config/src/compile/route.rs Compiles allow_early_data into runtime Route.
crates/rginx-app/tests/support/mod.rs Improves test HTTP response parsing (content-length + chunked decoding).
crates/rginx-app/tests/http3.rs Adds end-to-end HTTP/3 tests for mTLS, retry/host-key persistence, early-data replay gating, and telemetry.
crates/rginx-app/tests/check.rs Updates check integration test expectations for new HTTP/3 fields/output.
crates/rginx-app/tests/admin/snapshot.rs Updates snapshot tests for schema v13 and new HTTP/3 snapshot fields.
crates/rginx-app/tests/admin/commands.rs Updates admin CLI tests for new HTTP/3 telemetry and counters output.
crates/rginx-app/src/main.rs Extends check summary output with HTTP/3 early-data enabled listener count + per-binding metadata.
crates/rginx-app/src/admin_cli/traffic.rs Prints HTTP/3 runtime telemetry in traffic output.
crates/rginx-app/src/admin_cli/status.rs Prints HTTP/3 summary metrics, per-binding metadata, and per-listener HTTP/3 telemetry in status output.
crates/rginx-app/src/admin_cli/counters.rs Prints new HTTP/3 early-data counters in counters output.
Cargo.toml Bumps workspace version to 0.1.3-rc.11.
Cargo.lock Updates lockfile for new/updated dependencies and version bump.
ARCHITECTURE_REMEDIATION_RELEASE_NOTE.md Removes obsolete remediation release note doc.
ARCHITECTURE_REMEDIATION_PLAN.md Removes obsolete remediation plan doc.
ARCHITECTURE_HTTP3_PLAN.md Removes older HTTP/3 plan doc in favor of nginx-alignment plan/phase docs.
ARCHITECTURE_HTTP3_PHASE0_FREEZE.md Removes older Phase 0 freeze doc in favor of updated docs.
.github/workflows/release.yml Runs HTTP/3 release gate during release verification.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread scripts/run-http3-soak.sh
Comment on lines +98 to +102
if [[ "${need_privileged}" -eq 1 ]]; then
have tc || die "tc is required when --netem-profile is used"
have ip || die "ip is required when --mtu is used"
[[ "${EUID}" -eq 0 ]] || die "root privileges are required for netem/mtu operations"
fi
Copy link

Copilot AI Apr 13, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The privileged-tool checks are slightly inconsistent: need_privileged becomes true when only --mtu is set, but the script still hard-requires tc and will run tc qdisc del ... in clear_faults even though netem isn't in use. This makes --mtu unnecessarily depend on tc (and can break on minimal systems). Consider gating the tc requirement/usage on NETEM_PROFILE != none and only requiring ip/doing MTU work when --mtu is set.

Copilot uses AI. Check for mistakes.
Comment on lines 26 to 30
rustls-native-certs.workspace = true
serde.workspace = true
serde_json.workspace = true
socket2 = "0.5.10"
tokio = { workspace = true, features = ["io-util", "process"] }
Copy link

Copilot AI Apr 13, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This adds a direct socket2 = "0.5.10" dependency, but the workspace already pulls in socket2 0.6.x transitively (e.g., via tokio/quinn), so this introduces a second socket2 version in the build. To reduce compile time and dependency duplication, consider adding socket2 to [workspace.dependencies] and using socket2.workspace = true here (matching the existing version), unless there is a specific reason to pin 0.5.x.

Copilot uses AI. Check for mistakes.
Comment on lines +175 to +183
let size_hint = response_size_hint(&parts.headers);
let expect_trailers = response_expects_trailers(&parts.headers);
let body = streaming_response_body(
request_stream,
session,
peer.url.clone(),
size_hint,
expect_trailers,
);
Copy link

Copilot AI Apr 13, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The new upstream HTTP/3 path only calls recv_trailers() when Content-Type looks like gRPC. Previously trailers were always read and forwarded; with this change, any non-gRPC response trailers will be silently dropped, and (depending on h3/quinn semantics) the stream may not be fully driven to completion which can interfere with session reuse. Consider always draining/reading trailers (and forwarding them when present), even if you don’t expect them for most content-types.

Copilot uses AI. Check for mistakes.
Comment on lines 154 to +158
config.alpn_protocols = alpn_protocols.into_iter().map(String::into_bytes).collect();
apply_session_policy(&mut config, default_tls)?;
if http3_only && http3_early_data_enabled {
config.max_early_data_size = u32::MAX;
}
Copy link

Copilot AI Apr 13, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Setting config.max_early_data_size = u32::MAX enables up to ~4GB of 0-RTT data per connection, which is a very permissive default and can have DoS / memory-pressure implications. Consider bounding this to a reasonable limit (e.g., derived from the configured max request body size) and/or disabling early data automatically when client auth is configured so the advertised early_data capability matches actual runtime behavior.

Copilot uses AI. Check for mistakes.
Comment on lines +504 to +508
let mtls_configured =
current_listener.server.tls.as_ref().and_then(|tls| tls.client_auth.as_ref()).is_some();
let early_data_enabled =
current_listener.http3.as_ref().is_some_and(|http3| http3.early_data_enabled);
let connecting = match incoming.accept() {
Copy link

Copilot AI Apr 13, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

early_data_enabled is read from listener config, but 0-RTT is skipped whenever downstream mTLS is configured (!mtls_configured). This means a config can advertise/enable HTTP/3 early data while the server will silently never use 0-RTT for that listener. Consider either rejecting http3.early_data when tls.client_auth is set (validation) or making the effective early-data state explicit in status/snapshot so operators aren’t misled.

Copilot uses AI. Check for mistakes.
vansour added a commit that referenced this pull request Apr 13, 2026
@vansour vansour mentioned this pull request Apr 13, 2026
@vansour
Copy link
Copy Markdown
Owner Author

vansour commented Apr 13, 2026

@coderabbitai review

@coderabbitai
Copy link
Copy Markdown

coderabbitai Bot commented Apr 13, 2026

✅ Actions performed

Review triggered.

Note: CodeRabbit is an incremental review system and does not re-review already reviewed commits. This command is applicable only when automatic reviews are paused.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants