更新Logstore的索引資訊。
介面說明
介面說明
Host 由 Project 名稱和日誌服務 Endpoint 構成,您需要在 Host 中指定 Project。
調試
您可以在OpenAPI Explorer中直接運行該介面,免去您計算簽名的困擾。運行成功後,OpenAPI Explorer可以自動產生SDK程式碼範例。
調試
授權資訊
|
操作 |
存取層級 |
資源類型 |
條件關鍵字 |
關聯操作 |
|
log:UpdateIndex |
update |
*LogStore
|
|
無 |
請求文法
PUT /logstores/{logstore}/index HTTP/1.1
路徑參數
|
名稱 |
類型 |
必填 |
描述 |
樣本值 |
| logstore |
string |
是 |
Logstore 名稱。 |
test-logstore |
請求參數
|
名稱 |
類型 |
必填 |
描述 |
樣本值 |
| project |
string |
是 |
Project 名稱。 |
ali-test-project |
| body |
object |
否 |
請求體。 |
|
| keys |
object |
否 |
The configuration of field indexes. A field index is a key-value pair in which the key specifies the name of the field and the value specifies the index configuration of the field. |
|
|
object |
是 |
The index configuration of the field. |
||
| caseSensitive |
boolean |
否 |
Specifies whether to enable case sensitivity. Valid values:
|
|
| chn |
boolean |
否 |
Specifies whether to include Chinese characters. This parameter is required only when type is set to text. Valid values:
|
|
| type |
string |
否 |
The data type of the field value. Valid values: text, json, double, and long. 枚舉值:
|
|
| alias |
string |
否 |
The alias of the field. |
|
| token |
array |
是 |
The delimiters that are used to split text. This parameter is required only when type is set to text. |
|
|
string |
否 |
The delimiter that is used to split text. |
||
| doc_value |
boolean |
否 |
Specifies whether to turn on Enable Analytics for the field. |
|
| line |
object |
否 |
The configuration of full-text indexes. |
|
| chn |
boolean |
否 |
Specifies whether to include Chinese characters. Valid values:
|
|
| caseSensitive |
boolean |
否 |
Specifies whether to enable case sensitivity. Valid values:
|
|
| token |
array |
是 |
The delimiters that are used to split text. |
|
|
string |
否 |
The delimiter that is used to split text. |
||
| include_keys |
array |
否 |
The included fields. You cannot specify both include_keys and exclude_keys. |
|
|
string |
否 |
The included field. |
||
| exclude_keys |
array |
否 |
The excluded fields. You cannot specify both include_keys and exclude_keys. |
|
|
string |
否 |
The excluded field. |
||
| ttl |
integer |
否 |
The retention period of data. Unit: days. Valid values: 7, 30, and 90. |
|
| max_text_len |
integer |
否 |
The maximum length of a field value that can be retained. |
|
| log_reduce |
boolean |
否 |
Specifies whether to turn on LogReduce. If you turn on LogReduce, only one of |
|
| log_reduce_white_list |
array |
否 |
The fields in the whitelist that you want to use to cluster logs. |
|
|
string |
否 |
The field in the whitelist. |
||
| log_reduce_black_list |
array |
否 |
The fields in the blacklist that you want to use to cluster logs. |
|
|
string |
否 |
The field in the blacklist. |
返回參數
|
名稱 |
類型 |
描述 |
樣本值 |
當前API暫無返回參數
樣本
正常返回樣本
JSON格式
{}
錯誤碼
訪問錯誤中心查看更多錯誤碼。
變更歷史
更多資訊,參考變更詳情。