How do I define a field in elasticsearch to always return an array.
I have a field KEYWORDS in elasticsearch that sometimes have one keyword
Elasticsearch then returns that field as a string rather than a list, this breaks the deserializer as it is expecting a list rather than a string.
This is how I defined keyword mapping:
"KEYWORDS": {
"type": "text",
"fields": {
"keyword": {
"type": "text"
}
}
},