sunspot/sunspot — pull request #306 by carols10cents (2012-10-23 01:43:45+00:00)
Title: Only reindex changes of

This adds an option that is the opposite of :ignore_attribute_changes_of. I've named it :only_reindex_attribute_changes_of but I will gladly rename it to whatever best fits in the project.

Instead of a blacklist of changing attributes to ignore, this is a whitelist of attributes that are the only ones that should trigger a reindex.

My use case is in a model with many attributes that only have a few that are searchable, and we'd rather list the positive set than the negative set. The set of searchable attributes is also less likely to change or be added to than the set of attributes that should be ignored.