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

Reading BulkResponse of BulkRequestBuilder in spark? #463

Closed
piyushGoyal2 opened this issue Jun 2, 2015 · 1 comment
Closed

Reading BulkResponse of BulkRequestBuilder in spark? #463

piyushGoyal2 opened this issue Jun 2, 2015 · 1 comment

Comments

@piyushGoyal2
Copy link

Hi Costin,
If I see the elasticsearch API, for bulk add, update and delete functionality, the response obtained from execute.actionGet always contains the information such as hasFailure, failureMessages, numberOfActions and other parameters.
However, with spark, saveToES(with or without Meta) returns Unit. Is there a way wherein I can collect the response and see at least certain items such as hasFailure and failureMessage?

@costin
Copy link
Member

costin commented Jun 2, 2015

No, one would get an exception in case of failure and the exception message would contain any relevant information.

There are various reasons why that is, the main one being that the connector does not control the runtime (it's YARN, Hadoop, Spark, Akka, etc..) and only an exception can prevent those from assuming everything went okay.
Additionally, in terms of sync/async, distributed vs local things tend to be different and a fail fast stop works consistently across all.

Last but not least, please ask questions on the forums not on the issue tracker.

Thanks.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants