Sha256: 26e5a0d3b3350974587e7da86914438820c0fda680e63b2b0c8c597c8efe5df8

Contents?: true

Size: 514 Bytes

Versions: 25

Compression:

Stored size: 514 Bytes

Contents

$LOAD_PATH.unshift File.expand_path('../../lib', __FILE__)
require 'fresh_connection'
require 'benchmark/ips'
require 'active_record'
require 'mysql2'

class ActiveRecord::Base
  establish_connection(
    adapter: 'mysql2',
    encoding: 'utf8',
    database: 'kaeruspoon_development',
    pool: 5,
    username: 'root',
    password: '',
    socket: '/tmp/mysql.sock',
    replica: { encoding: 'utf8' }
  )
end

class Article < ActiveRecord::Base
end

Benchmark.ips do |x|
  x.report("find") { Article.take }
end

Version data entries

25 entries across 25 versions & 1 rubygems

Version Path
fresh_connection-2.4.0.rc3 benchmarks/benchmark.rb
fresh_connection-2.4.0.rc1 benchmarks/benchmark.rb
fresh_connection-2.3.2 benchmarks/benchmark.rb
fresh_connection-2.3.1 benchmarks/benchmark.rb
fresh_connection-2.3.0 benchmarks/benchmark.rb