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

Asyncronously Process Evaluations

Katsuya Noguchi edited this page Oct 4, 2012 · 1 revision

For applications with large data set, computation of reputation values can be expensive. Therefore, it is common to perform the computation asynchronously (in batch). If you wish to asynchronously compute reputation values, I strongly recommend you to use collectiveidea's Delayed Job. For example:

class User < ActiveRecord
  has_reputation :karma,
    :source => :user,
    :aggregated_by => :sum

  handle_asynchronously :add_evaluation
  handle_asynchronously :update_evaluation
  handle_asynchronously :delete_evaluation
end