diff --git a/lib/lhm/chunker.rb b/lib/lhm/chunker.rb index 59c4f32c..a880705c 100644 --- a/lib/lhm/chunker.rb +++ b/lib/lhm/chunker.rb @@ -38,12 +38,7 @@ def execute begin affected_rows = @connection.update(copy(bottom, top(stride))) - rescue ActiveRecord::StatementInvalid => err - if err.message.downcase.index('deadlock').nil? - raise - return - end - + rescue ActiveRecord::TransactionIsolationConflict => err if !@retry_on_deadlock raise return