Skip to content

Commit d619b89

Browse files
committed
docs(kitex): clarify io.EOF meaning in streaming documentation
1 parent 5578781 commit d619b89

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

content/en/docs/kitex/Tutorials/advanced-feature/generic-call/generic_streaming.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -154,7 +154,7 @@ strResp, ok := resp.(string) // response is json string
154154

155155
### Server Streaming
156156

157-
Note: A non-nil error (including `io.EOF`) returned by `Recv` indicates that the server has finished sending (or encountered an error)
157+
Note: An `io.EOF` error returned by `Recv` indicates that the server has finished sending and normally closed the stream, while other non-nil errors indicate actual errors.
158158

159159
Example:
160160

content/zh/docs/kitex/Tutorials/advanced-feature/generic-call/generic_streaming.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
---
22
title: "流式泛化调用用户指南"
3-
date: 2025-05-09
3+
date: 2025-05-12
44
weight: 6
55
keywords: ["流式泛化调用用户指南"]
66
description: ""
@@ -159,7 +159,7 @@ strResp, ok := resp.(string) // 响应为 json 字符串
159159

160160
### 服务端流(Server Streaming)
161161

162-
注意:`Recv` 返回非 nil 错误(包括 `io.EOF`)表示服务端已发送完毕或出错
162+
注意:`Recv` 返回 `io.EOF` 错误表示服务端已发送完毕并正常关闭流,其它非 nil 错误表示出错
163163

164164
示例:
165165

0 commit comments

Comments
 (0)