配置模块请求

配置模块请求

Redis 企业软件
方法 路径 描述
发布 /v1/modules/config/bdb/{uid} 配置模块

配置模块

POST /v1/modules/config/bdb/{string: uid}

使用模块运行时配置命令(如果已定义)为模块配置新参数。

所需权限

权限名称
edit_bdb_module

请求

HTTP 请求示例

POST /v1/modules/config/bdb/1

示例 JSON 正文

{
  "modules": [
    {
      "module_name": "search",
      "module_args": "MINPREFIX 3 MAXEXPANSIONS 1000"
    }
  ]
}

Request headers

Key Value Description
Host cnm.cluster.fqdn Domain name
Accept application/json Accepted media type

Request body

Field Type Description
modules list of JSON objects List of modules (module_name) and their new configuration settings (module_args)
module_name search
ReJSON
graph
timeseries
bf
Module's name
module_args string Module command line arguments (pattern does not allow special characters &,<,>,”)

Response

Returns a status code. If an error occurs, the response body may include an error code and message with more details.

Error codes

When errors are reported, the server may return a JSON object with error_code and message field that provide additional information. The following are possible error_code values:

Code Description
db_not_exist Database with given UID doesn't exist in cluster
missing_field "module_name" or "module_args" are not defined in request
invalid_schema JSON object received is not a dict object
param_error "module_args" parameter was not parsed properly
module_not_exist Module with given "module_name" does not exist for the database

Status codes

Code Description
200 OK Success, module updated on bdb.
404 Not Found bdb not found.
400 Bad Request Bad or missing configuration parameters.
406 Not Acceptable Module does not support runtime configuration of arguments.
RATE THIS PAGE
Back to top ↑