Add ReadLimit to Option structs
未关闭
还没有人认领这个 Issue。
enhancement
- 主要语言
- Go
- 星标
- 5.5k
- 派生
- 376
- PR 合并指标
- 30 天内没有已合并 PR
描述
Would it be possible to add a field to `AcceptOptions` and to `DialOptions` that sets the read limit on the created connection? It's not as convenient to have to call the `SetReadLimit()`. If the field is 0 then a default limit can be applied.
Is there a need to change the limit dynamically? I mean, why is it a method (i.e. can be called multiple times) vs a field in those option setting structs?
贡献指南
这个仓库没有索引到贡献指南
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
调研方向
首先定位 AcceptOptions 和 DialOptions 的定义以及 SetReadLimit 方法,然后追踪每个选项如何创建连接。确定零值字段应如何与默认限制交互,以及该方法是否必须继续可用于动态更改。完成标准是:两个选项结构体都可以配置初始读取限制,同时不移除该方法现有的行为。
由索引模型根据 Issue 内容生成。
评估
- 技术栈
- go
- 领域
- backend-api-design, networking
- Issue 类型
- 功能
- 难度
- 3/5
- 预计耗时
- 1-2 天
- 活跃度
- 停滞
- 描述清晰度
- 基本清楚
- 新手友好度
- 38/100