Hello,
I just want to create a new and simple index/mapping (I follow the docs) in ES 5.0, but I am always getting "Validation Failed: 1: mapping source is empty;" What am I doing wrong ?
These are the commands :
$ curl -XPUT 'srpiso02d:9210/twitter?pretty' -d'
{
"mappings": {
"tweet": {
"properties": {
"message": {
"type": "text"
}
}
}
}
}
'
{
"mappings": {
"tweet": {
"properties": {
"message": {
"type": "text"
}
}
}
}
}
'
{
"acknowledged" : true,
** "shards_acknowledged" : true**
}
$ curl -XGET "http://srpiso02d:9210/twitter/_mapping"
{"twitter":{"mappings":{}}}srpiso02d:/var/hpsrp/srpiso02d/elastic/ES$
--> mapping is empty
$ curl -XPUT 'srpiso02d:9210/twitter/_mapping/user?pretty' -d'
{
"properties": {
"name": {
"type": "text"
}
}
}
{'
"properties": {
"name": {
"type": "text"
}
}
}
'
{
"error" : {
"root_cause" : [
{
"type" : "action_request_validation_exception",
** "reason" : "Validation Failed: 1: mapping source is empty;"**
}
],
"type" : "action_request_validation_exception",
** "reason" : "Validation Failed: 1: mapping source is empty;"**
},
"status" : 400
}
Many thanks in advance.