Sha256: 21b602a200577977ba145190b6ccd518683d352199c0f7a2eec953f7666572f5

Contents?: true

Size: 695 Bytes

Versions: 2

Compression:

Stored size: 695 Bytes

Contents

module Octopus
  module Rails3
    module Persistence
      def update_attribute(*args)
        run_on_shard { super }
      end

      def update_attributes(*args)
        run_on_shard { super }
      end

      def update_attributes!(*args)
        run_on_shard { super }
      end

      def reload(*args)
        run_on_shard { super }
      end

      def delete
        run_on_shard { super }
      end

      def destroy
        run_on_shard { super }
      end

      def touch(name = nil)
        run_on_shard { super }
      end

      def update_column(*args)
        run_on_shard { super }
      end
    end
  end
end

ActiveRecord::Base.send(:include, Octopus::Rails3::Persistence)

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
ar-octopus-0.8.4 lib/octopus/persistence.rb
ar-octopus-0.8.3 lib/octopus/persistence.rb