README 内容修改

Signed-off-by: hu-kai45 <hukai45@huawei.com>
This commit is contained in:
hu-kai45 2023-07-04 15:29:20 +08:00
parent 8d3054a324
commit 51052c9456
7 changed files with 16 additions and 16 deletions

View File

@ -5,18 +5,18 @@
`ylong_http` has built a complete HTTP capability, supporting users to use HTTP
capability to meet the needs of communication scenarios.
`ylong_http` provides HTTP protocol support to the network subsystem in the
`OpenHarmony` system service layer, and through the network subsystem, helps
upper layer applications recommend HTTP communication capabilities.
`ylong_http` is written in the Rust language to support OpenHarmony's Rust
capability.
**Structure**
### The position of ylong_http in OpenHarmony
`ylong_http` provides HTTP protocol support to the `netstack` module in the
`OpenHarmony` system service layer, and through the `netstack` module, helps
upper layer applications build HTTP communication capabilities.
![structure](./figures/structure.png)
**Inner Structure**:
### The internal structure of ylong_http
![inner_structure](./figures/inner_structure.png)
@ -49,7 +49,7 @@ Abilities supported by the current `ylong_http` crate:
## Build
`GN` is supported. User should add dependencies in `deps` of `BUILD.GN` to build this crate.
`GN` is supported. User should add dependencies in `deps` of `BUILD.gn` to build this crate.
```gn
deps += ["//example_path/ylong_http_client:ylong_http_client"]

View File

@ -4,16 +4,16 @@
ylong_http 协议栈构建了完整的 HTTP 能力,支持用户使用 HTTP 能力完成通信场景的需求。
ylong_http 向 OpenHarmony 系统服务层中的网络子系统提供 HTTP 协议支持,经由网络子系统帮助上层应用建议 HTTP 通信能力。
ylong_http 协议栈主体使用 Rust 语言编写,为 OpenHarmony 的 Rust 能力构筑提供支持。
**架构图**:
### ylong_http 在 OpenHarmony 中的位置
![structure](./figures/structure.png)
ylong_http 向 OpenHarmony 系统服务层中的网络协议栈模块提供 HTTP 协议支持,经由网络协议栈模块帮助上层应用建立 HTTP 通信能力。
**内部架构图**:
![inner_structure](./figures/inner_structure.png)
![structure](./figures/structure_zh.png)
### ylong_http 的内部架构:
![inner_structure](./figures/inner_structure_zh.png)
### ylong_http_client 库
@ -42,7 +42,7 @@ ylong_http 库提供了 HTTP 协议的各种基础组件,例如序列化组件
## 编译构建
若使用 GN 编译工具链, 在 ```BUILD.GN``` 的 ```deps``` 段下添加依赖。添加后使用 GN 进行编译和构建:
若使用 GN 编译工具链, 在 ```BUILD.gn``` 的 ```deps``` 段下添加依赖。添加后使用 GN 进行编译和构建:
```gn
deps += ["//example_path/ylong_http_client:ylong_http_client"]

View File

@ -19,7 +19,7 @@ ylong_http 整体分为 2 个库:
在使用 ylong_http_client 的功能之前,请保证在 `BUILD.gn``Cargo.toml` 中已成功添加依赖并开启对应 feature。
### v1.0.0
当前支持的功能:
- 支持异步 HTTP 客户端创建
- 支持 HTTP/1.1
@ -59,7 +59,7 @@ async fn create_client_with_builder() {
当前版本提供的 Client 的配置选项:
- `connect_timeout`: 设置连接超时时间
- `request_timeout`: 设置连接超时时间
- `request_timeout`: 设置请求超时时间
- `redirect`: 设置重定向逻辑
- `proxy`: 设置代理逻辑
- `tls_built_in_root_certs`: 是否使用预置证书

Binary file not shown.

Before

Width:  |  Height:  |  Size: 13 KiB

After

Width:  |  Height:  |  Size: 87 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 89 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 17 KiB

After

Width:  |  Height:  |  Size: 42 KiB

BIN
figures/structure_zh.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 46 KiB