How would this be written as CURL? I've tried a few things, but it didn't work.
PUT my_index/_settings
{
"index.mapping.total_fields.limit": 2000
}
How would this be written as CURL? I've tried a few things, but it didn't work.
PUT my_index/_settings
{
"index.mapping.total_fields.limit": 2000
}
curl -XPUT $HOST:9200/my_index/_settings -d '{ "index.mapping.total_fields.limit": 2000 }'
most likely.
I tried curl -XPUT localhost:9200/my_index/_settings -d '{ "index.mapping.total_fields.limit": 2000 }'
and got
{"error":"Content-Type header [application/x-www-form-urlencoded] is not supported","status":406}
Ahh, probably https://www.elastic.co/guide/en/elasticsearch/reference/6.2/common-options.html#_content_type_requirements then.
Ok, this worked:
curl -H 'Content-Type: application/json' -XPUT localhost:9200/my_index/_settings -d '{ "index.mapping.total_fields.limit": 2000 }'
Thanks!
This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.
© 2020. All Rights Reserved - Elasticsearch
Apache, Apache Lucene, Apache Hadoop, Hadoop, HDFS and the yellow elephant logo are trademarks of the Apache Software Foundation in the United States and/or other countries.