From eabe83f5448ea722165cf22f1075e304f834d687 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=BB=84=E9=A3=9E=E8=99=B9?= Date: Fri, 9 Oct 2026 11:44:11 +0800 Subject: [PATCH] chore(release): prepare v1.52.0 --- AGENTS.md | 2 +- CHANGELOG.md | 30 +++++++++++++++++++ Dockerfile | 2 +- Makefile | 2 +- README.md | 14 ++++----- README_zh.md | 14 ++++----- cmd/hotplex/doc.go | 2 +- cmd/hotplex/main.go | 2 +- docs/swagger/swagger.json | 2 +- examples/java-client/README.md | 10 +++++-- examples/java-client/pom.xml | 2 +- .../python-client/hotplex_client/__init__.py | 2 +- examples/python-client/pyproject.toml | 2 +- examples/typescript-client/package-lock.json | 4 +-- examples/typescript-client/package.json | 2 +- webchat/package.json | 2 +- 16 files changed, 64 insertions(+), 30 deletions(-) diff --git a/AGENTS.md b/AGENTS.md index 3621226aa..03432cfe2 100644 --- a/AGENTS.md +++ b/AGENTS.md @@ -1,6 +1,6 @@ # HotPlex 项目知识库 -**最后更新**: 2026-10-04 · **分支**: main · **版本**: v1.51.0 · **提交**: 6255138b +**最后更新**: 2026-10-09 · **分支**: main · **版本**: v1.52.0 · **提交**: 4119b288 --- diff --git a/CHANGELOG.md b/CHANGELOG.md index 4468fb18a..89c0a8b0b 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,35 @@ # Changelog +## [1.52.0] - 2026-10-09 + +### Summary + +v1.52.0 是一次 minor 版本更新,核心主题是 **数据生命周期与可核验交付**。运行资源回收与历史数据保留分开计时,让不占运行资源的会话保留更久;效果对账、围栏和队列终态进入执行时间线,并修复会话清理、事件顺序、PostgreSQL 队列和关闭竞态等可靠性问题。 + +### Added + +- **分层生命周期**:新会话默认使用 `v2` 策略,最近有效输入后 7 天标记归档、180 天到期;归档后仍可查看和续聊。每条新消息正文独立保留 180 天,投递正文在结算后保留 7 天,已结算投递/执行明细保留 90 天后清理或压缩,并保留去重根事实。v2 无正文审计事实默认保留 180 天,媒体缓存 24 小时,已关闭 ACP trace 48 小时。期限、扫描间隔、批量大小和积压告警均可配置。 +- **生命周期迁移与删除进度**:管理员可通过 `preview` / `apply` 预览并分批延长存量会话期限;用户删除后的异步清理进度可查询。不支持远端清理的 Worker 会明确返回 unsupported,并保留 blocked 状态。 +- **效果对账与运行时事件**:效果账本增加 reconciled / fenced 终态,执行时间线区分对账结果与围栏;新增效果计划、对账、围栏和操作员动作事件,排队输入取消、清空与过期也产生终态事实。Go、TypeScript、Python、Java SDK 与 AEP 文档同步扩展。 +- **Worker 隔离能力报告**:四种 Worker 如实报告可提供的隔离能力和限制,区分 Agent 配置约束与操作系统级隔离。 +- **显式云端交付工具**:指定 Issue 后顺序执行受限实施、质量门和草稿 PR 发布;支持过期验证检测、提交/推送检查点恢复、已有 PR 复用和必须执行的 Git hooks,不增加自动合并或部署能力。 + +### Fixed + +- **会话续期与迁移**:已迁移会话在持久受理新输入时正确续期;热/冷缓存路径保留已保存的策略版本与更长期限,迁移候选和 readiness 使用一致规则,分批操作能够收敛。重复输入不续期,生命周期写入失败的排队输入不会被误确认或退回易失队列。 +- **留存窗口不随新配置缩短**:投递与执行记录在创建时保存窗口和策略版本,按各自结算时钟计算清理期限;缺少快照、未结算、状态未知或仍有活动义务的记录继续受保护。审计哈希链按已到期连续前缀清理,legacy 与 v2 链独立保留。 +- **PostgreSQL 清理与队列**:删除会话后先关闭 `RETURNING` 结果集再入队远端清理,保持同一事务的原子性;修复队列预算、领取、结算及深度查询的占位符转换,以及留存窗口和结算时间的 BIGINT 类型推断。 +- **事件顺序与消息身份**:`done` 先于运行时终态事实送达,seq 与送达顺序一致;delta 合并保留消息身份与 metadata,超时回调不再修改转发器拥有的文本聚合状态。 +- **关闭竞态**:Repairer 仅在后台处理循环退出后执行单一 drain,整个关闭过程受同一个时间预算约束;取消/超时不会启动并发重试,回调重入和关闭后的 Start 不会死锁或创建新处理循环。 +- **原生 SDK 与诊断**:固定 Origin 白名单下允许不携带 Origin 的原生客户端,仍拒绝携带未授权 Origin 的请求;诊断检查改用明确注入的状态与配置根目录。Cron 在计划阶段拒绝不安全的工作目录。 + +### Upgrade Notes + +- 启动时会自动应用 SQLite / PostgreSQL 成对迁移 039–045;升级前备份数据库,涉及数据格式的回退按 `docs/guides/developer/release-recovery.md` 的恢复流程执行。 +- 已有 legacy 会话不会自动切换到 v2,历史期限不会因升级或缩短配置被重算。需要迁移时先预览,再由管理员显式 apply;迁移不会缩短期限或复活已删除记录。 +- `session.retention_period` 继续表示兼容的运行资源期限,不是聊天正文保留期。生命周期清理参数调整后需重启 Gateway;备份、用户工作文件及聊天平台自身的消息不属于本地清理范围。 +- 审计正文采集仍关闭,`lifecycle.audit.capture_content: true` 会校验失败;`audit.content_retention` 是预留项。云端自动实施需要有效 Codex 认证,认证失败时停止并保留现场。 + ## [1.51.0] - 2026-10-04 ### Summary diff --git a/Dockerfile b/Dockerfile index 7e4aed5a9..cf0c4a605 100644 --- a/Dockerfile +++ b/Dockerfile @@ -72,7 +72,7 @@ ARG DEBIAN_MIRROR LABEL org.opencontainers.image.title="HotPlex Worker Gateway" LABEL org.opencontainers.image.description="AI Coding Agent access layer" -LABEL org.opencontainers.image.version="1.51.0" +LABEL org.opencontainers.image.version="1.52.0" LABEL org.opencontainers.image.source="https://github.com/hotplex/hotplex" LABEL org.opencontainers.image.revision="${GIT_SHA}" LABEL org.opencontainers.image.created="${BUILD_TIME}" diff --git a/Makefile b/Makefile index 7f265fb72..5c9105877 100644 --- a/Makefile +++ b/Makefile @@ -21,7 +21,7 @@ GOOS := $(shell go env GOOS) GOARCH := $(shell go env GOARCH) GIT_SHA := $(shell git rev-parse --short=8 HEAD 2>/dev/null || echo "unknown") BUILD_TIME := $(shell date '+%Y-%m-%dT%H:%M:%S%z') -VERSION := v1.51.0 +VERSION := v1.52.0 LDFLAGS := -s -w -X main.version=$(VERSION) -X main.buildTime=$(BUILD_TIME) BUILD_OPTS := -trimpath diff --git a/README.md b/README.md index 0ad8a3b57..4efb5c9a7 100644 --- a/README.md +++ b/README.md @@ -15,7 +15,7 @@

CI - Version + Version License Go AEP v1 @@ -135,13 +135,13 @@ See the [worker and channel reliability audit](docs/architecture/worker-channel- Worker choice can be set per bot or platform, with shared defaults for the rest of the deployment. -## ✨ Latest release: v1.51.0 +## ✨ Latest release: v1.52.0 -- **可证明的输入生命周期。** 输入先持久化受理再投递 Worker,由 owner 租约与 active gate 保证同一轮次只有一次有效执行;租约过期置为 `unknown` 并围栏,`unknown` 永不自动重投。 -- **权威运行时计划。** 每次会话启动都记录带指纹的 launch plan,事后可回答"实际生效的是哪份配置",而不是靠复现推测。 -- **交付与 Agent 完成分离。** 执行记录与投递效果各自持久化:Agent 的 `done` 不等于用户已收到结果,投递回执独立可查。 -- **执行台。** Admin 控制台基于同一份运行时存储提供执行列表、时间线与队列操作。 -- **真实链路验证。** 本版本在真实 PostgreSQL 与真实 Claude Code Worker 上完成端到端运行,并据此修复了终态事件丢失与多回合不可观测两个缺陷。 +- **Longer-lived conversations.** Runtime resources, conversation history and message content have separate clocks. New conversations default to 7-day archive marking and 180-day history/content retention, with configurable limits. +- **Safe lifecycle upgrades.** Existing sessions retain their policy. Administrators can preview and apply bounded migrations that extend deadlines; duplicate inputs and configuration changes do not shorten stored retention windows. +- **Visible delivery outcomes.** Reconciled and fenced effects, operator actions and queued-input terminal events are exposed in the execution timeline and all four SDKs. +- **Reliable shutdown and cleanup.** Fixes Repairer shutdown races, PostgreSQL cleanup and queue queries, terminal event ordering, and native SDK connections under an Origin allowlist. +- **Explicit cloud delivery.** A selected Issue can proceed through scoped implementation, validation and a draft PR, with resumable checkpoints and mandatory hooks. See the [changelog](CHANGELOG.md) for the complete release history. diff --git a/README_zh.md b/README_zh.md index 52940397e..63bee458b 100644 --- a/README_zh.md +++ b/README_zh.md @@ -15,7 +15,7 @@

CI - Version + Version License Go AEP v1 @@ -135,13 +135,13 @@ HotPlex 把“用户在哪里对话”和“哪个 Agent 执行任务”分离 Worker 可以按 Bot 或平台指定,其余场景继承部署级共享默认值。 -## ✨ 最新版本:v1.51.0 +## ✨ 最新版本:v1.52.0 -- **输入生命周期可证明。** 输入先持久化受理再投递 Worker,由 owner 租约与 active gate 保证同一轮次只有一次有效执行;租约过期置为 `unknown` 并围栏,`unknown` 永不自动重投。 -- **权威运行时计划。** 每次会话启动都记录带指纹的 launch plan,事后可回答"实际生效的是哪份配置",而不是靠复现推测。 -- **交付与 Agent 完成分离。** 执行记录与投递效果各自持久化:Agent 的 `done` 不等于用户已收到结果,投递回执独立可查。 -- **执行台。** Admin 控制台基于同一份运行时存储提供执行列表、时间线与队列操作。 -- **真实链路验证。** 本版本在真实 PostgreSQL 与真实 Claude Code Worker 上完成端到端运行,并据此修复了终态事件丢失与多回合不可观测两个缺陷。 +- **历史会话保留更久。** 运行资源、会话历史与消息正文分别计时。新会话默认 7 天标记归档、历史和正文保留 180 天,期限均可配置。 +- **存量迁移保护。** 已有会话保留原策略;管理员可先预览再分批延长期限。重复输入和配置调整不会缩短已记录的留存窗口。 +- **交付结果可见。** 效果对账与围栏状态、操作员决策和排队输入终态进入执行时间线,并同步四种 SDK。 +- **关闭与清理更可靠。** 修复 Repairer 关闭竞态、PostgreSQL 清理与队列查询、终态事件顺序,以及固定 Origin 白名单下原生 SDK 连接。 +- **明确的云端交付流程。** 指定 Issue 后依次完成实施、验证与草稿 PR,保留可恢复检查点并强制执行 Git hooks。 完整版本历史见[更新记录](CHANGELOG.md)。 diff --git a/cmd/hotplex/doc.go b/cmd/hotplex/doc.go index f077e6bcb..95ebc2a4f 100644 --- a/cmd/hotplex/doc.go +++ b/cmd/hotplex/doc.go @@ -1,7 +1,7 @@ // Package main is the entry point for the HotPlex Worker Gateway. // // @title HotPlex API -// @version 1.51.0 +// @version 1.52.0 // @description HotPlex Worker Gateway — unified access layer for AI Coding Agent sessions. // @contact.name HotPlex // @contact.url https://github.com/hrygo/hotplex/issues diff --git a/cmd/hotplex/main.go b/cmd/hotplex/main.go index 549fa211e..adbf9794e 100644 --- a/cmd/hotplex/main.go +++ b/cmd/hotplex/main.go @@ -11,7 +11,7 @@ import ( ) var ( - version = "v1.51.0" + version = "v1.52.0" buildTime = "unknown" ) diff --git a/docs/swagger/swagger.json b/docs/swagger/swagger.json index 640927872..000b80977 100644 --- a/docs/swagger/swagger.json +++ b/docs/swagger/swagger.json @@ -11,7 +11,7 @@ "name": "Apache 2.0", "url": "https://github.com/hrygo/hotplex/blob/main/LICENSE" }, - "version": "1.51.0" + "version": "1.52.0" }, "host": "localhost:8888", "basePath": "/", diff --git a/examples/java-client/README.md b/examples/java-client/README.md index 9cfd9dc3e..57340cb13 100644 --- a/examples/java-client/README.md +++ b/examples/java-client/README.md @@ -22,26 +22,30 @@ ## Installation +Build this reference SDK from source with `mvn clean install` before using the +coordinates below. This installs `1.52.0-SNAPSHOT` in your local Maven repository; +the Gateway release does not publish SDK packages to Maven Central. + ### Maven ```xml dev.hotplex hotplex-client - 1.8.0 + 1.52.0-SNAPSHOT ``` ### Gradle (Groovy) ```groovy -implementation 'dev.hotplex:hotplex-client:1.8.0' +implementation 'dev.hotplex:hotplex-client:1.52.0-SNAPSHOT' ``` ### Gradle (Kotlin) ```kotlin -implementation("dev.hotplex:hotplex-client:1.8.0") +implementation("dev.hotplex:hotplex-client:1.52.0-SNAPSHOT") ``` --- diff --git a/examples/java-client/pom.xml b/examples/java-client/pom.xml index e0fb0669a..d12906072 100644 --- a/examples/java-client/pom.xml +++ b/examples/java-client/pom.xml @@ -13,7 +13,7 @@ dev.hotplex hotplex-client - 1.51.0-SNAPSHOT + 1.52.0-SNAPSHOT jar HotPlex Client diff --git a/examples/python-client/hotplex_client/__init__.py b/examples/python-client/hotplex_client/__init__.py index c4e8b14cb..13a825106 100644 --- a/examples/python-client/hotplex_client/__init__.py +++ b/examples/python-client/hotplex_client/__init__.py @@ -4,7 +4,7 @@ A Python client library for interacting with HotPlex Gateway via AEP v1 protocol. """ -__version__ = "1.51.0" +__version__ = "1.52.0" __author__ = "HotPlex Team" # 导出公共 API diff --git a/examples/python-client/pyproject.toml b/examples/python-client/pyproject.toml index 153b41ed4..4a3424210 100644 --- a/examples/python-client/pyproject.toml +++ b/examples/python-client/pyproject.toml @@ -1,6 +1,6 @@ [project] name = "hotplex-client" -version = "1.51.0" +version = "1.52.0" description = "Python client example for HotPlex Gateway (AEP v1)" requires-python = ">=3.10" dependencies = [ diff --git a/examples/typescript-client/package-lock.json b/examples/typescript-client/package-lock.json index 4daefafdd..9fde22387 100644 --- a/examples/typescript-client/package-lock.json +++ b/examples/typescript-client/package-lock.json @@ -1,12 +1,12 @@ { "name": "hotplex-client", - "version": "1.51.0", + "version": "1.52.0", "lockfileVersion": 3, "requires": true, "packages": { "": { "name": "hotplex-client", - "version": "1.51.0", + "version": "1.52.0", "license": "Apache-2.0", "dependencies": { "eventemitter3": "^5.0.1", diff --git a/examples/typescript-client/package.json b/examples/typescript-client/package.json index 45d9b39db..024e97e81 100644 --- a/examples/typescript-client/package.json +++ b/examples/typescript-client/package.json @@ -1,6 +1,6 @@ { "name": "hotplex-client", - "version": "1.51.0", + "version": "1.52.0", "description": "TypeScript client SDK for HotPlex Gateway (AEP v1)", "type": "module", "main": "./dist/index.js", diff --git a/webchat/package.json b/webchat/package.json index e0cce4750..721819cb2 100644 --- a/webchat/package.json +++ b/webchat/package.json @@ -1,6 +1,6 @@ { "name": "hotplex-webchat", - "version": "1.51.0", + "version": "1.52.0", "private": true, "packageManager": "pnpm@11.4.0", "scripts": {