Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

dynamic index and custom header produce an invalid request #218

Closed
costin opened this Issue Jun 18, 2014 · 2 comments

Comments

Projects
None yet
2 participants
@costin
Copy link
Member

commented Jun 18, 2014

When a dynamic/template is used alongside a custom header, the generated JSON request is invalid causing ES to reject the payload with an error.

@costin costin added bug labels Jun 18, 2014

costin added a commit that referenced this issue Jun 18, 2014

@Bondza

This comment has been minimized.

Copy link

commented Jul 25, 2014

Hi,

I am trying to use dynamic index to create objects with different types as well as setting the id, this configuration also seems to result in invalid requests sent to ES. Is this the same issue?

The JSON output is invalid: {"index":{"_index":"statistics","_type":"hour""_id":"2014-07-17T11:00:00.000Z"}}
We are running Hadoop 2.4.0 EMR with ES 1.2.1.

Elasticsearch-hadoop configuration:
conf.set("es.input.json", "yes");
conf.set("es.mapping.id", "id");
conf.set("es.nodes", "localhost:9600");
conf.set("es.resource.write", "statistics/{type}");
conf.set("es.write.operation", "index");

@costin costin closed this in dbcc546 Jul 31, 2014

@costin

This comment has been minimized.

Copy link
Member Author

commented Aug 11, 2014

Hi,

This is a bug that occurs in 2.0.0 that was fixed on master and will be part of the upcoming 2.0.1.

Can you please try the latest builds and report back?

Thanks,

On 7/25/14 2:40 PM, Fredrik Bondza wrote:

Hi,

I am trying to use dynamic index to create objects with different types as well as setting the id, this configuration
also seems to result in invalid requests sent to ES. Is this the same issue?

The JSON output is invalid: {"index":{"_index":"statistics","_type":"hour""_id":"2014-07-17T11:00:00.000Z"}}
We are running Hadoop 2.4.0 EMR with ES 1.2.1.

Elasticsearch-hadoop configuration:
conf.set("es.input.json", "yes");
conf.set("es.mapping.id", "id");
conf.set("es.nodes", "localhost:9600");
conf.set("es.resource.write", "statistics/{type}");
conf.set("es.write.operation", "index");


Reply to this email directly or view it on GitHub
#218 (comment).

Costin

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.