mirror of
https://gitee.com/iresty/apisix.git
synced 2024-12-02 12:07:35 +08:00
docs: Modify APISIX Chinese docs directory (#6898)
This commit is contained in:
parent
d67e892159
commit
57a42c2f2a
@ -59,13 +59,13 @@ hello world
|
||||
根据文件最后修改时间判断文件内容是否有变化,如有变化则重新加载,如没变化则跳过本次检查。
|
||||
所以高级调试模式的开启、关闭都是热更新方式完成。
|
||||
|
||||
| 名字 | 可选项 | 说明 | 默认值 |
|
||||
| ------------------------------- | ------ | ------------------------------------------------------------------ | ------ |
|
||||
| hook_conf.enable | 必选项 | 是否开启 hook 追踪调试。开启后将打印指定模块方法的请求参数或返回值 | false |
|
||||
| hook_conf.name | 必选项 | 开启 hook 追踪调试的模块列表名称 | |
|
||||
| hook_conf.log_level | 必选项 | 打印请求参数和返回值的日志级别 | warn |
|
||||
| hook_conf.is_print_input_args | 必选项 | 是否打印输入参数 | true |
|
||||
| hook_conf.is_print_return_value | 必选项 | 是否打印返回值 | true |
|
||||
| 名称 | 必选项 | 说明 | 默认值 |
|
||||
| ------------------------------- | ------ | ------------------------------------------------------------- | ------ |
|
||||
| hook_conf.enable | 是 | 是否开启 hook 追踪调试。开启后将打印指定模块方法的请求参数或返回值。 | false |
|
||||
| hook_conf.name | 是 | 开启 hook 追踪调试的模块列表名称。 | |
|
||||
| hook_conf.log_level | 是 | 打印请求参数和返回值的日志级别。 | warn |
|
||||
| hook_conf.is_print_input_args | 是 | 是否打印输入参数。 | true |
|
||||
| hook_conf.is_print_return_value | 是 | 是否打印返回值。 | true |
|
||||
|
||||
请看下面示例:
|
||||
|
||||
|
@ -6,18 +6,25 @@
|
||||
"label": "Architecture Design",
|
||||
"items": [
|
||||
"architecture-design/apisix",
|
||||
"architecture-design/route",
|
||||
"architecture-design/plugin",
|
||||
"architecture-design/script",
|
||||
"architecture-design/service",
|
||||
"architecture-design/consumer",
|
||||
"architecture-design/upstream",
|
||||
"architecture-design/global-rule",
|
||||
"architecture-design/plugin-config",
|
||||
"architecture-design/router",
|
||||
"architecture-design/debug-mode"
|
||||
]
|
||||
},
|
||||
{
|
||||
"type": "category",
|
||||
"label": "Terminology",
|
||||
"items": [
|
||||
"terminology/api-gateway",
|
||||
"terminology/consumer",
|
||||
"terminology/global-rule",
|
||||
"terminology/plugin",
|
||||
"terminology/route",
|
||||
"terminology/router",
|
||||
"terminology/script",
|
||||
"terminology/service",
|
||||
"terminology/upstream"
|
||||
]
|
||||
},
|
||||
{
|
||||
"type": "doc",
|
||||
"id": "getting-started"
|
||||
|
37
docs/zh/latest/terminology/api-gateway.md
Normal file
37
docs/zh/latest/terminology/api-gateway.md
Normal file
@ -0,0 +1,37 @@
|
||||
---
|
||||
title: API Gateway
|
||||
---
|
||||
|
||||
<!--
|
||||
#
|
||||
# Licensed to the Apache Software Foundation (ASF) under one or more
|
||||
# contributor license agreements. See the NOTICE file distributed with
|
||||
# this work for additional information regarding copyright ownership.
|
||||
# The ASF licenses this file to You under the Apache License, Version 2.0
|
||||
# (the "License"); you may not use this file except in compliance with
|
||||
# the License. You may obtain a copy of the License at
|
||||
#
|
||||
# http://www.apache.org/licenses/LICENSE-2.0
|
||||
#
|
||||
# Unless required by applicable law or agreed to in writing, software
|
||||
# distributed under the License is distributed on an "AS IS" BASIS,
|
||||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
#
|
||||
-->
|
||||
|
||||
## 描述
|
||||
|
||||
API 网关是位于客户端与后端服务集之间的 API 管理工具。API 网关相当于反向代理,用于接受所有 API 的调用、整合处理这些调用所需的各种服务,并返回相应的结果。API 网关通常会处理**跨 API 服务系统使用**的常见任务,并统一接入进行管理。通过 API 网关的统一拦截,可以实现对 API 接口的安全、日志等共性需求,如用户身份验证、速率限制和统计信息。
|
||||
|
||||
## 为什么需要 API 网关?
|
||||
|
||||
与传统的 API 微服务相比,API 网关有很多好处。比如:
|
||||
|
||||
- 它是所有 API 请求的唯一入口。
|
||||
- 可用于将请求转发到不同的后端,或根据请求头将请求转发到不同的服务。
|
||||
- 可用于执行身份验证、授权和限速。
|
||||
- 它可用于支持分析,例如监控、日志记录和跟踪。
|
||||
- 可以保护 API 免受 SQL 注入、DDOS 攻击和 XSS 等恶意攻击媒介的攻击。
|
||||
- 它可以降低 API 和微服务的复杂性。
|
@ -28,7 +28,7 @@ title: Consumer
|
||||
|
||||
如上图所示,作为 API 网关,需要知道 API Consumer(消费方)具体是谁,这样就可以对不同 API Consumer 配置不同规则。
|
||||
|
||||
| 字段 | 必选 | 说明 |
|
||||
| 名称 | 必选项 | 说明 |
|
||||
| -------- | ---- | -------------------------------------------------------------------------------------------------------------------------------- |
|
||||
| username | 是 | Consumer 名称。 |
|
||||
| plugins | 否 | 该 Consumer 对应的插件配置,它的优先级是最高的:Consumer > Route > Service。对于具体插件配置,可以参考 [Plugins](plugin.md) 章节。 |
|
Loading…
Reference in New Issue
Block a user