Sha256: e6dea24bf9aeba3c2a9dcb47231f00c7c9531dc8e47732a8bba7e2c9ffef02bd

Contents?: true

Size: 487 Bytes

Versions: 40

Compression:

Stored size: 487 Bytes

Contents

module ActiveRecord::Turntable
  class Mixer
    class Fader
      class UpdateShardsMergeResult < Fader
        def execute
          @proxy.shards_transaction(@shards_query_hash.keys) do
            @shards_query_hash.map do |shard, query|
              args = @args.dup
              args[1] = args[1].dup if args[1].present?
              shard.connection.send(@called_method, query, *@args, &@block)
            end.inject(&:+)
          end
        end
      end
    end
  end
end

Version data entries

40 entries across 40 versions & 1 rubygems

Version Path
activerecord-turntable-4.4.1 lib/active_record/turntable/mixer/fader/update_shards_merge_result.rb
activerecord-turntable-4.4.0 lib/active_record/turntable/mixer/fader/update_shards_merge_result.rb
activerecord-turntable-4.3.0 lib/active_record/turntable/mixer/fader/update_shards_merge_result.rb
activerecord-turntable-4.2.0 lib/active_record/turntable/mixer/fader/update_shards_merge_result.rb
activerecord-turntable-4.1.0 lib/active_record/turntable/mixer/fader/update_shards_merge_result.rb
activerecord-turntable-4.0.0 lib/active_record/turntable/mixer/fader/update_shards_merge_result.rb
activerecord-turntable-3.1.0 lib/active_record/turntable/mixer/fader/update_shards_merge_result.rb
activerecord-turntable-3.0.1 lib/active_record/turntable/mixer/fader/update_shards_merge_result.rb
activerecord-turntable-3.0.0 lib/active_record/turntable/mixer/fader/update_shards_merge_result.rb
activerecord-turntable-2.5.0 lib/active_record/turntable/mixer/fader/update_shards_merge_result.rb
activerecord-turntable-3.0.0.alpha3 lib/active_record/turntable/mixer/fader/update_shards_merge_result.rb
activerecord-turntable-3.0.0.alpha2 lib/active_record/turntable/mixer/fader/update_shards_merge_result.rb
activerecord-turntable-2.4.0 lib/active_record/turntable/mixer/fader/update_shards_merge_result.rb
activerecord-turntable-3.0.0.alpha1 lib/active_record/turntable/mixer/fader/update_shards_merge_result.rb
activerecord-turntable-2.3.3 lib/active_record/turntable/mixer/fader/update_shards_merge_result.rb
activerecord-turntable-2.3.2 lib/active_record/turntable/mixer/fader/update_shards_merge_result.rb
activerecord-turntable-2.3.1 lib/active_record/turntable/mixer/fader/update_shards_merge_result.rb
activerecord-turntable-2.3.0 lib/active_record/turntable/mixer/fader/update_shards_merge_result.rb
activerecord-turntable-2.2.2 lib/active_record/turntable/mixer/fader/update_shards_merge_result.rb
activerecord-turntable-2.2.1 lib/active_record/turntable/mixer/fader/update_shards_merge_result.rb