Elastichsearch 1.7.3 - Array Field breaks and turns into String

Hi everyone!

I am using elasticsearch to store documents which also contain an array type. This array type works most of the time but at some point elasticsearch takes all it's elements and merges them into a single string.

So far I wasn't able to find a pattern as to when this happens.

Did you map the field correctly? If not, what is the mapping now?

"_accepts" : {
"type" : "string",
"dynamic" : false,
"index" : "not_analyzed",
"store" : true
},

it's initialized with []

and incremented with: ctx._source._accepts += elem


intermediary solution is now that I reconstruct the array for every new entry.

Not sure about what you are doing with a full example but may be you want to use nested documents?

So mark your field as nested...

My 2 cents