未能找到分析器 Elasticsearch

Failed to find analyzer Elasticsearch

我有这个指数:

    {
        "movies": {
            "aliases": {},
            "mappings": {},
            "settings": {
                "index": {
                    "routing": {
                        "allocation": {
                            "include": {
                                "_tier_preference": "data_content"
                            }
                        }
                    },
                    "number_of_shards": "1",
                    "provided_name": "movies",
                    "creation_date": "1632841492405",
                    "analysis": {
                        "filter": {
                            "autcomplete_filter": {
                                "type": "edge_ngram",
                                "min_gram": "1",
                                "max_gram": "20"
                            }
                        },
                        "analyser": {
                            "autocomplete": {
                                "filter": [
                                    "lowercase",
                                    "autocomplete_filter"
                                ],
                                "type": "custom",
                                "tokenizer": "standard"
                            }
                        }
                    },
                    "number_of_replicas": "1",
                    "uuid": "IhEcIyw1QoKRDVS8Drfj1w",
                    "version": {
                        "created": "7140199"
                    }
                }
            }
        }
    }

当我想用这个测试我的分析仪时:

curl -XGET "127.0.0.1:9200/movies/_analyze?pretty" -H "Content-Type: application/json" -d '
{
    "analyzer": "autocomplete",
    "text": "Sta"
}'

我有这个错误。

{
  "error" : {
    "root_cause" : [
      {
        "type" : "illegal_argument_exception",
        "reason" : "failed to find analyzer [autocomplete]"
      }
    ],
    "type" : "illegal_argument_exception",
    "reason" : "failed to find analyzer [autocomplete]"
  },
  "status" : 400
}

我不明白为什么,因为我们可以看到存在自动完成分析器。 如果我再次尝试创建分析器,ES 会说它已经存在。

你能帮我解决我的问题吗

改变这个:

   "analyser":{
      ...
      }
   }

收件人:

   "analyzer":{
     ...
      }
   }