- 28 10月, 2017 2 次提交
-
-
由 Thomas Walpole 提交于
- 25 10月, 2017 1 次提交
-
-
由 Akira Matsuda 提交于
Does not include disabled element in params
-
- 24 10月, 2017 2 次提交
-
-
由 Rafael França 提交于
specify minimum capybara version for system tests
-
由 Rafael França 提交于
Fix deprecation warnings from with_lock
-
- 23 10月, 2017 2 次提交
-
-
由 Chris Stadler 提交于
Currently `with_lock` checks whether the record has `changed?`, but when called within a callback `changed?` triggers deprecation warnings. Instead use `has_changes_to_save?`. Fixes #30307
-
由 Ryuta Kamizono 提交于
Backport perf changes
-
- 22 10月, 2017 1 次提交
-
-
由 Eileen M. Uchitelle 提交于
Backport #30579
-
- 19 10月, 2017 1 次提交
-
-
由 bogdanvlviv 提交于
Fix `bin/rails db:setup` and `bin/rails db:test:prepare` create wrong ar_internal_metadata's data for a test database. [Sean Griffin & bogdanvlviv]
-
- 16 10月, 2017 2 次提交
-
-
由 Ryuta Kamizono 提交于
We already found the longer sequence name, but we could not consider whether it was the sequence name created by serial type due to missed a max identifier length limitation. I've addressed the sequence name consideration to respect the max identifier length. Fixes #28332.
-
由 Ryuta Kamizono 提交于
If collided named sequence already exists, newly created serial column will generate alternative sequence name. Fix sequence name detection to allow the alternative names.
-
- 15 10月, 2017 1 次提交
-
-
由 Ryuta Kamizono 提交于
Currently `AUTO_INCREMENT` is implicitly used in the default primary key definition. But `AUTO_INCREMENT` is not only used for single column primary key, but also for composite primary key. In that case, `auto_increment: true` should be dumped explicitly in the `db/schema.rb`. Fixes #30894.
-
- 14 10月, 2017 1 次提交
-
-
由 Ryuta Kamizono 提交于
This is the fix for the regression of #29848. In #29848, I've kept existing select list in the subquery for the count if ORDER BY is given. But it had accidentally affect to GROUP BY queries also. It should keep the previous behavior in that case. Fixes #30886.
-
- 13 10月, 2017 1 次提交
-
-
由 Akira Matsuda 提交于
since r59328
-
- 05 10月, 2017 2 次提交
-
-
由 Ryuta Kamizono 提交于
-
由 Ryuta Kamizono 提交于
-
- 29 9月, 2017 2 次提交
-
-
由 Eileen M. Uchitelle 提交于
Backport Capybara :puma defaults to 5.1.x
-
由 Max Schwenk 提交于
-
- 27 9月, 2017 8 次提交
-
-
由 Guo Xiang Tan 提交于
``` require 'active_record' require 'benchmark/ips' ActiveRecord::Base.establish_connection(ENV.fetch('DATABASE_URL')) ActiveRecord::Migration.verbose = false ActiveRecord::Schema.define do create_table :users, force: true do |t| t.string :name, :email t.integer :topic_id t.timestamps null: false end create_table :topics, force: true do |t| t.string :title t.timestamps null: false end end attributes = { name: 'Lorem ipsum dolor sit amet, consectetur adipiscing elit.', email: 'foobar@email.com' } class Topic < ActiveRecord::Base has_many :users end class User < ActiveRecord::Base belongs_to :topic end 100.times do User.create!(attributes) end users = User.first(50) 100.times do Topic.create!(title: 'This is a topic', users: users) end Benchmark.ips do |x| x.config(time: 10, warmup: 5) x.report("preload") do User.includes(:topic).all.to_a end end ``` ``` Calculating ------------------------------------- preload 25.000 i/100ms ------------------------------------------------- preload 251.772 (± 1.2%) i/s - 2.525k ``` ``` Calculating ------------------------------------- preload 26.000 i/100ms ------------------------------------------------- preload 270.392 (± 1.1%) i/s - 2.704k ```
-
由 Guo Xiang Tan 提交于
```ruby require 'active_record' require 'benchmark/ips' ActiveRecord::Base.establish_connection(ENV.fetch('DATABASE_URL')) ActiveRecord::Migration.verbose = false ActiveRecord::Schema.define do create_table :users, force: true do |t| t.string :name, :email t.timestamps null: false end end attributes = { name: 'Lorem ipsum dolor sit amet, consectetur adipiscing elit.', email: 'foobar@email.com' } class User < ActiveRecord::Base; end 1000.times do User.create!(attributes) end Benchmark.ips do |x| x.config(time: 10, warmup: 2) x.report('pluck 1 column') do User.pluck(:id) end x.report('pluck 2 columns') do User.pluck(:id, :email) end x.report('pluck 1 column with scope') do User.where(id: 1000).pluck(:id) end x.report('pluck 2 columns with scope') do User.where(id: 1000).pluck(:id, :email) end end ``` ``` Calculating ------------------------------------- pluck 1 column 122.000 i/100ms pluck 2 columns 74.000 i/100ms pluck 1 column with scope 615.000 i/100ms pluck 2 columns with scope 515.000 i/100ms ------------------------------------------------- pluck 1 column 1.272k (± 3.9%) i/s - 12.810k pluck 2 columns 750.096 (± 3.3%) i/s - 7.548k pluck 1 column with scope 6.074k (± 4.1%) i/s - 60.885k pluck 2 columns with scope 5.158k (± 2.7%) i/s - 52.015k ``` ``` Calculating ------------------------------------- pluck 1 column 126.000 i/100ms pluck 2 columns 78.000 i/100ms pluck 1 column with scope 457.000 i/100ms pluck 2 columns with scope 434.000 i/100ms ------------------------------------------------- pluck 1 column 1.266k (± 2.1%) i/s - 12.726k pluck 2 columns 795.061 (± 3.0%) i/s - 7.956k pluck 1 column with scope 4.660k (± 2.1%) i/s - 46.614k pluck 2 columns with scope 4.355k (± 2.3%) i/s - 43.834k ``` ``` Calculating ------------------------------------- pluck 1 column 126.000 i/100ms pluck 2 columns 78.000 i/100ms pluck 1 column with scope 539.000 i/100ms pluck 2 columns with scope 481.000 i/100ms ------------------------------------------------- pluck 1 column 1.308k (± 3.4%) i/s - 13.104k pluck 2 columns 798.604 (± 2.8%) i/s - 8.034k pluck 1 column with scope 5.530k (± 3.4%) i/s - 55.517k pluck 2 columns with scope 4.914k (± 2.7%) i/s - 49.543k ``` ``` Calculating ------------------------------------- pluck 1 column 139.000 i/100ms pluck 2 columns 79.000 i/100ms pluck 1 column with scope 580.000 i/100ms pluck 2 columns with scope 526.000 i/100ms ------------------------------------------------- pluck 1 column 1.337k (± 3.0%) i/s - 13.483k pluck 2 columns 806.776 (± 2.7%) i/s - 8.137k pluck 1 column with scope 5.924k (± 4.1%) i/s - 59.160k pluck 2 columns with scope 5.276k (± 3.1%) i/s - 53.126k ```
-
由 Ryuta Kamizono 提交于
-
由 Ryuta Kamizono 提交于
Fixes #30539.
-
由 Ryuta Kamizono 提交于
https://travis-ci.org/rails/rails/jobs/279300966#L2600 The result of `Loofah::HTML5::Scrub.scrub_css` was changed since v2.1.0.rc1. https://github.com/flavorjones/loofah/commit/ca56295ff9e802018ea18d23ed49be235a95ccad
-
由 Ryuta Kamizono 提交于
make create_join_table compatible.
-
由 Sean Griffin 提交于
Ensure `1 AS one` for SQL Server with Calculations
-
由 Ryuta Kamizono 提交于
PERF: Restore memoization when preloading associations.
-
- 15 9月, 2017 1 次提交
-
-
由 Kasper Timm Hansen 提交于
Backport #29146 to 5-1-stable
-
- 14 9月, 2017 1 次提交
-
-
由 Kasper Timm Hansen 提交于
Correctly set user_supplied_options when there is no whitespace in option specification
-
- 08 9月, 2017 2 次提交
-
-
由 Matthew Draper 提交于
-
由 Matthew Draper 提交于
-
- 06 9月, 2017 3 次提交
-
-
由 Ryuta Kamizono 提交于
Update CHANGELOG.md [ci skip]
-
由 Muhammet 提交于
-
由 Sean Griffin 提交于
activerecord: Fix saved_changes for saves nested in after callbacks
-
- 04 9月, 2017 5 次提交
-
-
由 Ryuta Kamizono 提交于
Otherwise using reserved words as composite primary key names will be failed as an invalid SQL. Fixes #30518.
-
由 Ryuta Kamizono 提交于
Fixes #30496.
-
由 Ryuta Kamizono 提交于
-
由 Ryuta Kamizono 提交于
Unscoping `default_scope` in associations has already supported (#17360 for preloading, c9cf8b8d for eager loading). Fixes #20679. Closes #16531.
-
由 Ryuta Kamizono 提交于
-
- 30 8月, 2017 1 次提交
-
-
由 Dylan Thacker-Smith 提交于
Previously, saved_changes would return a hash of changes corresponding to the outermost save in the callbacks for the nested save, but now it will return the hash of changes for the nested save in its callbacks.
-
- 29 8月, 2017 1 次提交
-
-
由 Ryuta Kamizono 提交于
This regression was caused by caa178c1. The block for `set_inverse_instance` should also be passed to join dependency. Fixes #30402.
-