You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@apisix.apache.org by ju...@apache.org on 2020/11/12 16:27:54 UTC

[apisix] branch master updated: docs: add create/update_time fields (#2712)

This is an automated email from the ASF dual-hosted git repository.

juzhiyuan pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/apisix.git


The following commit(s) were added to refs/heads/master by this push:
     new 2f8762c  docs: add create/update_time fields (#2712)
2f8762c is described below

commit 2f8762c22ffb90a2935dcaa5716e9d05678bf0f4
Author: 罗泽轩 <sp...@gmail.com>
AuthorDate: Fri Nov 13 00:23:49 2020 +0800

    docs: add create/update_time fields (#2712)
    
    Close #2654
---
 doc/admin-api.md       | 12 +++++++++++-
 doc/zh-cn/admin-api.md | 10 ++++++++++
 2 files changed, 21 insertions(+), 1 deletion(-)

diff --git a/doc/admin-api.md b/doc/admin-api.md
index 0e8e17c..94b9fb0 100644
--- a/doc/admin-api.md
+++ b/doc/admin-api.md
@@ -72,6 +72,8 @@
 |service_protocol|False|Upstream protocol type|only `grpc` and `http` are supported|`http` is the default value; Must set `grpc` if using `gRPC proxy` or `gRPC transcode`|
 |labels   |False |Match Rules|Key/value pairs to specify attributes|{"version":"v2","build":"16","env":"production"}|
 |enable_websocket|False|Auxiliary| enable `websocket`(boolean), default `false`.||
+|create_time|False| Auxiliary|epoch timestamp in second| 1602883670|
+|update_time|False| Auxiliary|epoch timestamp in second| 1602883670|
 
 For the same type of parameters, such as `host` and `hosts`, `remote_addr` and `remote_addrs` cannot exist at the same time, only one of them can be selected. If enabled at the same time, the API will response an error.
 
@@ -293,6 +295,8 @@ curl http://127.0.0.1:9080/apisix/admin/routes/1 -H 'X-API-KEY: edd1c9f034335f13
 |desc     |False |Auxiliary   |service usage scenarios, and more.|customer xxxx|
 |labels   |False |Match Rules|Key/value pairs to specify attributes|{"version":"v2","build":"16","env":"production"}|
 |enable_websocket|False|Auxiliary| enable `websocket`(boolean), default `false`.||
+|create_time|False| Auxiliary|epoch timestamp in second| 1602883670|
+|update_time|False| Auxiliary|epoch timestamp in second| 1602883670|
 
 Config Example:
 
@@ -433,6 +437,8 @@ Return response from etcd currently.
 |plugins  |False |Plugin|See [Plugin](architecture-design.md#plugin) for more ||
 |desc     |False |Auxiliary   |Identifies route names, usage scenarios, and more.|customer xxxx|
 |labels   |False |Match Rules|Key/value pairs to specify attributes|{"version":"v2","build":"16","env":"production"}|
+|create_time|False| Auxiliary|epoch timestamp in second| 1602883670|
+|update_time|False| Auxiliary|epoch timestamp in second| 1602883670|
 
 Config Example:
 
@@ -513,7 +519,9 @@ In addition to the basic complex equalization algorithm selection, APISIX's Upst
 |desc     |optional|upstream usage scenarios, and more.|
 |pass_host            |optional|`pass` pass the client request host, `node` not pass the client request host, using the upstream node host, `rewrite` rewrite host by the configured `upstream_host`.|
 |upstream_host    |optional|This option is only valid if the `pass_host` is `rewrite`.|
-|labels|False |Match Rules|Key/value pairs to specify attributes|{"version":"v2","build":"16","env":"production"}|
+|labels|optional |Key/value pairs to specify attributes|{"version":"v2","build":"16","env":"production"}|
+|create_time|optional| epoch timestamp in second, like `1602883670`|
+|update_time|optional| epoch timestamp in second, like `1602883670`|
 
 
 Config Example:
@@ -656,6 +664,8 @@ Return response from etcd currently.
 |key|True|Private key|https Private key||
 |sni|True|Match Rules|https SNI||
 |labels|False |Match Rules|Key/value pairs to specify attributes|{"version":"v2","build":"16","env":"production"}|
+|create_time|False| Auxiliary|epoch timestamp in second| 1602883670|
+|update_time|False| Auxiliary|epoch timestamp in second| 1602883670|
 
 Config Example:
 
diff --git a/doc/zh-cn/admin-api.md b/doc/zh-cn/admin-api.md
index f5ed411..9df4de4 100644
--- a/doc/zh-cn/admin-api.md
+++ b/doc/zh-cn/admin-api.md
@@ -76,6 +76,8 @@
 |filter_func|可选|匹配规则|用户自定义的过滤函数。可以使用它来实现特殊场景的匹配要求实现。该函数默认接受一个名为 vars 的输入参数,可以用它来获取 Nginx 变量。|function(vars) return vars["arg_name"] == "json" end|
 |labels   |可选 |匹配规则|标识附加属性的键值对|{"version":"v2","build":"16","env":"production"}|
 |enable_websocket|可选 |辅助| 是否启用 `websocket`(boolean), 缺省 `false`.||
+|create_time|可选|辅助|单位为秒的 epoch 时间戳|1602883670|
+|update_time|可选|辅助|单位为秒的 epoch 时间戳|1602883670|
 
 有两点需要特别注意:
 
@@ -303,6 +305,8 @@ curl http://127.0.0.1:9080/apisix/admin/routes/1 -H 'X-API-KEY: edd1c9f034335f13
 |desc     |可选 |辅助   |服务描述、使用场景等。||
 |labels   |可选 |匹配规则|标识附加属性的键值对|{"version":"v2","build":"16","env":"production"}|
 |enable_websocket|可选 |辅助| 是否启用 `websocket`(boolean), 缺省 `false`.||
+|create_time|可选|辅助|单位为秒的 epoch 时间戳|1602883670|
+|update_time|可选|辅助|单位为秒的 epoch 时间戳|1602883670|
 
 serivce 对象 json 配置内容:
 
@@ -446,6 +450,8 @@ HTTP/1.1 200 OK
 |plugins|可选|Plugin|该 Consumer 对应的插件配置,它的优先级是最高的:Consumer > Route > Service。对于具体插件配置,可以参考 [Plugins](#plugin) 章节。||
 |desc     |可选 |辅助|consumer描述||
 |labels   |可选 |匹配规则|标识附加属性的键值对|{"version":"v2","build":"16","env":"production"}|
+|create_time|可选|辅助|单位为秒的 epoch 时间戳|1602883670|
+|update_time|可选|辅助|单位为秒的 epoch 时间戳|1602883670|
 
 consumer 对象 json 配置内容:
 
@@ -528,6 +534,8 @@ APISIX 的 Upstream 除了基本的复杂均衡算法选择外,还支持对上
 |pass_host            |可选|枚举|`pass` 透传客户端请求的 host, `node` 不透传客户端请求的 host, 使用 upstream node 配置的 host, `rewrite` 使用 `upstream_host` 配置的值重写 host 。||
 |upstream_host    |可选|辅助|只在 `pass_host` 配置为 `rewrite` 时有效。||
 |labels   |可选 |匹配规则|标识附加属性的键值对|{"version":"v2","build":"16","env":"production"}|
+|create_time|可选|辅助|单位为秒的 epoch 时间戳|1602883670|
+|update_time|可选|辅助|单位为秒的 epoch 时间戳|1602883670|
 
 upstream 对象 json 配置内容:
 
@@ -668,6 +676,8 @@ HTTP/1.1 200 OK
 |key|必需|私钥|https 证书私钥||
 |sni|必需|匹配规则|https 证书SNI||
 |labels|可选|匹配规则|标识附加属性的键值对|{"version":"v2","build":"16","env":"production"}|
+|create_time|可选|辅助|单位为秒的 epoch 时间戳|1602883670|
+|update_time|可选|辅助|单位为秒的 epoch 时间戳|1602883670|
 
 ssl 对象 json 配置内容: