Hi everyone, I got a problem when I try to run an example of Custom type field section in this tutorial: https://www.elastic.co/guide/en/elasticsearch/reference/7.6/removal-of-types.html#_custom_type_field
I executed this query:
PUT twitter
{
"mappings": {
"user": {
"properties": {
"name": { "type": "text" },
"user_name": { "type": "keyword" },
"email": { "type": "keyword" }
}
},
"tweet": {
"properties": {
"content": { "type": "text" },
"user_name": { "type": "keyword" },
"tweeted_at": { "type": "date" }
}
}
}
}
The result is an error:
{
"error" : {
"root_cause" : [
{
"type" : "mapper_parsing_exception",
"reason" : "Root mapping definition has unsupported parameters: [tweet : {properties={tweeted_at={type=date}, user_name={type=keyword}, content={type=text}}}] [user : {properties={user_name={type=keyword}, name={type=text}, email={type=keyword}}}]"
}
],
"type" : "mapper_parsing_exception",
"reason" : "Failed to parse mapping [_doc]: Root mapping definition has unsupported parameters: [tweet : {properties={tweeted_at={type=date}, user_name={type=keyword}, content={type=text}}}] [user : {properties={user_name={type=keyword}, name={type=text}, email={type=keyword}}}]",
"caused_by" : {
"type" : "mapper_parsing_exception",
"reason" : "Root mapping definition has unsupported parameters: [tweet : {properties={tweeted_at={type=date}, user_name={type=keyword}, content={type=text}}}] [user : {properties={user_name={type=keyword}, name={type=text}, email={type=keyword}}}]"
}
},
"status" : 400
}
Can anyone help me with that, thanks in advance!