在Elasticsearch中添加“不”字段

时间:2019-08-13 18:02:03

标签: elasticsearch

first:使用代码`curl -XPUT'localhost:9200 / twitter?pretty``创建表 secend:将fied添加到表中但是有问题

curl -X PUT "localhost:9200/twitter?pretty" -H 'Content-Type: application/json' -d
'{
  "mappings": {
    "properties": { 
      "title":    { "type": "text"  }, 
      "name":     { "type": "text"  }, 
      "age":      { "type": "integer" },  
      "created":  {
        "type":   "date", 
        "format": "strict_date_optional_time||epoch_millis"
      }
    }
  }
}'

错误:

  

“错误”:{       “根本原因” : [         {           “ type”:“ cluster_block_exception”,           “ reason”:“索引[twitter]被以下对象阻止:[FORBIDDEN / 12 / index只读/允许删除(api)];”         }       ],       “ type”:“ cluster_block_exception”,       “ reason”:“索引[twitter]被以下对象阻止:[FORBIDDEN / 12 / index只读/允许删除(api)];” },“状态”:403}

0 个答案:

没有答案