Sha256: 7bf448712b565813e8beb58070087abcaba5624a229f87b11d70cb755f87de57

Contents?: true

Size: 262 Bytes

Versions: 6

Compression:

Stored size: 262 Bytes

Contents

class ActiveRecord::ConnectionAdapters::ConnectionPool
  def new_connection_with_retry
    Activerecord::Mysql::Reconnect.retryable(
      :proc => proc {
        new_connection_without_retry
      }
    )
  end

  alias_method_chain :new_connection, :retry
end

Version data entries

6 entries across 6 versions & 1 rubygems

Version Path
activerecord-mysql-reconnect-0.3.3 lib/activerecord/mysql/reconnect/connection_pool_ext.rb
activerecord-mysql-reconnect-0.3.2 lib/activerecord/mysql/reconnect/connection_pool_ext.rb
activerecord-mysql-reconnect-0.3.1 lib/activerecord/mysql/reconnect/connection_pool_ext.rb
activerecord-mysql-reconnect-0.3.0 lib/activerecord/mysql/reconnect/connection_pool_ext.rb
activerecord-mysql-reconnect-0.2.1 lib/activerecord/mysql/reconnect/connection_pool_ext.rb
activerecord-mysql-reconnect-0.2.0 lib/activerecord/mysql/reconnect/connection_pool_ext.rb