mixonic/ranked-model — pull request #88 by csaura (2014-12-03 20:00:20+00:00)
Title: Add collision policy

When ranked models are set in the same first or last position, the 24th
element will have the RankedModel::MIN_RANK_VALUE or RankedModel::MAX_RANK_VALUE.

Apply rearrange will force to shift for the all the next elements in the first/last position, when the list is really large performs an sql like:

````
UPDATE `table` SET position_column = position_column + 1 where
`table`.`position_column` >= -8388606
````

and its lock rows that can cause performance issues.

Setting the `collision_policy: :rebalance` for ranked models that usually inserts in the same first/last position will reduce the performance issues in very large ranked lists.