alphagov/rummager — pull request #150 by jamiecobbett (2013-08-01 09:45:37+00:00)
Title: Raise errors when indexing fails

Currently we ignore some classes of indexing failure. This change inspects the response body and looks for any failures and raises an error. Things like Timeouts, Elasticsearch being unavailable and so on are already be reported.

In development, this change would mean you get a semantic 500 error for indexing requests.
In production-like environments, because indexing is done in the background, the error will be raised in the worker and then retried by Sidekiq's retry mechanism as normal.