> For the complete documentation index, see [llms.txt](https://summerain-1.gitbook.io/summerain/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://summerain-1.gitbook.io/summerain/zh-cn/fa-bu-shuo-ming/v2.0.10.md).

# V2.0.10

> 开发预发布版本。此版本从 `dev` 分支发布，可能会快速接收后续更改，不会被默认的 `latest` 镜像标签选择。

## 概述

v2.0.10 让浏览器上传流水线读取 v2.0.9 新增的配方客户端提示，而不再依赖构建期常量。 最终并发与源文件体积上限取「服务端提示、设备能力、前端安全上限」三者的最小值：运维人员无需 重新发布前端即可从服务端降低浏览器侧负载，同时性能较弱或内存受限的设备仍保持自身的下限。 未下发这些提示的服务端则完全保持原有行为。

配方版本不再是前端常量：客户端会回传服务端给出的版本，并在版本变化时重新处理已持久化的结果。

## 变更内容

### 生效的上传限制

* `client_pipeline_concurrency` 与 `client_active_session_concurrency` 分别决定上传流水线 并发和活跃服务端会话闸门，且都不会超过前端上限 2 与 4。
* `client_max_native_concurrency` 会与设备能力（上报核心数的一半，取值 1 到 2）取最小值， 弱设备不会以超过自身承受能力的 Worker 数处理图片。
* `max_source_bytes` 取代固定的 15 MiB 预检查，并在添加文件时与预检阶段各校验一次， 因此在配方返回之前加入的文件同样会按服务端策略被拒绝。
* 提示缺失时沿用随客户端发布的默认值，这正是旧版服务端所期望的行为。提示存在但不可用 （为零、负数、小数或非数字）时回退到上限，并弹出一条列出字段名的告警提示， 而不是静默忽略配置错误。
* 前端绝不会把限制提高到服务端取值或自身上限之上。

### 动态配方版本

* 移除了原生处理器、WASM Worker、预检、共享类型与配方解析中硬编码的 `2.0.0`。
* 当配方的流水线版本或变体尺寸超出客户端能力时仍会拒绝，且错误现在会带上服务端的 `recipe_version` 与 `pipeline_version`。
* 服务端配方版本变化后，已持久化的处理结果会被丢弃并重新生成。上传队列恢复、租约与 重试语义保持不变。

## 验证

* 前端 ESLint：通过。
* 前端 `tsc -b` 类型检查与 Vite 生产构建：通过。
* 前端 Vitest：18 个测试文件、148 个测试通过（此前为 17 个文件、131 个测试）。
* 新增覆盖：限制解析（默认值、服务端更小、服务端更大、设备更低、提示不可用）、 动态配方版本接受、错误详情上报，以及预检阶段的源文件体积拒绝。
* 后端 `go build ./...`、`go vet ./...`、`go test ./...`：通过（后端未改动）。
* Python requirements lock 验证与 GitBook 文档验证：通过。

## 安装

必须显式拉取开发镜像：

```bash
docker pull jaykserks/summerain:dev-v2.0.10
```

等效的精确开发标签：

```
jaykserks/summerain:dev-2.0.10
```

移动的 `dev` 标签也指向最新的成功开发构建。`latest`、`main` 和稳定的语义版本别名 不受此版本影响。

从 v2.0.9 升级不需要数据库迁移或 API 迁移。

## 已知限制

* 这些提示仍是建议值：服务端依然独立校验每次上传，未下发提示的服务端保持此前的浏览器行为。
* 根目录 README 仍按默认流水线并发描述；文档打磨安排在部署阶段一并完成。
* 动画图像支持仍计划在后续版本中实现。

## 相关工作

此版本实现了 `PHASES-2-8-PLAN-v2.md` 的**阶段 5**。

**下一阶段**：阶段 6（v2.0.11）完成 Docker 部署方案与配方文件的三语文档。


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://summerain-1.gitbook.io/summerain/zh-cn/fa-bu-shuo-ming/v2.0.10.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
