when I make following request. I got the following error.
PUT /develop_tickets_dev/_mapping
{
"properties": {
"fieldMap": {
"type": "nested",
"properties": {
"ts.requester": {
"type": "object",
"properties": {
"value": {
"type": "long"
},
"lookup": {
"type": "object",
"properties": {
"index": "develop_users_dev",
"type": "user",
"path": "id"
}
}
}
}
}
}
}
}
Here is the error:
{
"error": {
"root_cause": [
{
"type": "mapper_parsing_exception",
"reason": "Expected map for property [fields] on field [path] but got a class java.lang.String"
}
],
"type": "mapper_parsing_exception",
"reason": "Failed to parse mapping: Expected map for property [fields] on field [path] but got a class java.lang.String",
"caused_by": {
"type": "mapper_parsing_exception",
"reason": "Expected map for property [fields] on field [path] but got a class java.lang.String"
}
},
"status": 400
}
My mapping is as follows:
{
"mappings": {
"properties": {
"email": {
"type": "text",
"fields": {
"keyword": {
"type": "keyword",
"ignore_above": 256
}
}
},
"fullName": {
"type": "text",
"fields": {
"keyword": {
"type": "keyword",
"ignore_above": 256
}
}
},
"id": {
"type": "long"
}
}
}
}
what should be the correct lookup object in the request?