我们有 elasticSearch 版本2.4.0。我用以下值更新了 elasticsearch.yml :
_update_by_query
我将{
"script":{
"inline": "ctx._source.myVariable = ctx._source.id == params.newVal ? 'test':ctx._source.myVariable ",
"params": {
"newVal": "2c9ef"
}}
}
API与以下示例有效负载配合使用:
{
"error": {
"root_cause": [
{
"type": "script_exception",
"reason": "scripts of type [inline], operation [update] and lang [groovy] are disabled"
}
],
"type": "script_exception",
"reason": "scripts of type [inline], operation [update] and lang [groovy] are disabled"
},
"status": 500
}
我仍然收到以下错误响应:
<config-file>
我从here中获取了配置详细信息。
答案 0 :(得分:0)
您必须重新启动ES实例,这些更改才能生效