I am trying to bulk index using jq, and having trouble.
I enter the following using the terminal (I'm using Ubuntu 16.04)
cat practice.json | jq -c '.[] | {"index": {"_index": "text", "_type": "text", "_id": "text"}}, .' | curl -XPOST localhost:9200/_bulk --data-binary @-
This is the error that I get:
{"type":"mapper_parsing_exception","reason":"failed to parse","caused_by":{"type":"not_x_content_exception","reason":"not_x_content_exception: Compressor detection can only be called on some xcontent bytes or compressed xcontent bytes"}}}}
Oddly, I was able to get similar code (I forgot to save what I did, but I think it is the same as this) to work. I couldn't find anyone with the same problem here or elsewhere. Any idea on how to fix this?