AmericanCouncils/AyamelResourceApiServer — pull request #199 by cmac1000 (2014-04-24 18:03:00+00:00)
Title: Calm indexer

This is intended to fix some queue-thrashing issues we saw in staging. The major change is that the search index consumer always returns true given an IndexException - in this case, putting the message back in the queue is unlikely to be useful, because whatever condition gave rise to the IndexException is likely still the case.

The only case we can think of in which we do want to someday re-index a currently unindexable resource is a case where the resource is modified, e.g. with content. In that case, the act of adding content should properly add a new message to the search index queue, so we don't need to keep track of failed attempts at indexing here - we log it as "skipped" and let the queue drain.

If there are cases in which we do want to handle exceptions some other way, we'll need to come up with another type of exception or otherwise rework this logic.