升级到 Apache HttpClient 5.x 作为默认 HTTP 客户端 #3824
Draft
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Apache HttpClient 4.x 已进入维护模式。项目已有完整的 HttpClient 5.x 实现(
hc/目录),但配置为providedscope。本 PR 将 HttpClient 5.x 设为默认,同时保持 4.x 兼容。依赖变更
httpclient5.version=5.5属性httpclient5从provided改为默认依赖httpclient4.5.13 作为默认依赖(向后兼容)默认配置
对已有
*HttpComponentsImpl实现的模块,将默认 HTTP 客户端改为HttpComponents(5.x):HttpComponentsHttpClient(4.x),暂无 5.x 实现更新所有
HttpClientType枚举添加HttpComponents选项。配置示例
文档
兼容性
Original prompt
💡 You can make Copilot smarter by setting up custom instructions, customizing its development environment and configuring Model Context Protocol (MCP) servers. Learn more Copilot coding agent tips in the docs.