Skip to content
This repository has been archived by the owner on Nov 4, 2021. It is now read-only.

Throw exception if any record fails and Log the response #213

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

clovenlife
Copy link

Attempting to resolve the
https://github.com/babenkoivan/scout-elasticsearch-driver/issues/186
ElasticSearch will return 200 regardless if a record failed with bulk loading, so I'm checking the response for an errors property and if it exists, iterate through all the items return to find the item that caused the error, log them, and throw an exception.

@iget-esoares
Copy link
Collaborator

Can you add a more eloquent log message and exception message?

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

Successfully merging this pull request may close these issues.

2 participants