aboutsummaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
...
* | | | | | | | | Merge pull request #22333 from harrykiselev/patch-3Yves Senn2015-11-211-1/+5
|\ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | [ci skip] Update dirty.rb: documentation fix.
| * | | | | | | | | Update dirty.rb: documentation fix.Harry V. Kiselev2015-11-191-1/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | ActiveModel::Dirty module documentation fix.
* | | | | | | | | | Merge pull request #22362 from radar/toggle-documentationClaudio B2015-11-201-0/+8
|\ \ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | Add example for AR::Persistence#toggle
| * | | | | | | | | | Add example for AR::Persistence#toggleRyan Bigg2015-11-211-0/+8
| | | | | | | | | | |
* | | | | | | | | | | Merge pull request #22353 from Bounga/doc_for_cookies_encryptedClaudio B2015-11-201-0/+7
|\ \ \ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | Add missing example for cookies.encrypted [ci skip]
| * | | | | | | | | | | Add missing example for cookies.encrypted [ci skip]Nicolas Cavigneaux2015-11-201-0/+7
| | | | | | | | | | | |
* | | | | | | | | | | | Merge pull request #22354 from nishantmodak/image-tag-data-attributesRafael França2015-11-202-1/+4
|\ \ \ \ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | Example of setting data attributes for image_tag
| * | | | | | | | | | | | Example of setting data attributes for image_tagNishant Modak2015-11-202-1/+4
| |/ / / / / / / / / / /
* | | | | | | | | | | | Merge pull request #22355 from yui-knk/remove_arity_checkKasper Timm Hansen2015-11-202-10/+0
|\ \ \ \ \ \ \ \ \ \ \ \ | |/ / / / / / / / / / / |/| | | | | | | | | | | Remove arity check for `RouteSet#draw`
| * | | | | | | | | | | Remove arity check for `RouteSet#draw`yui-knk2015-11-212-10/+0
|/ / / / / / / / / / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This code was added for migration from Rails 3.1 to upper, now we are developing Rails 5.
* | | | | | | | | | | Merge pull request #22332 from grosser/grosser/deprecationRafael França2015-11-206-4/+72
|\ \ \ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | add deprecations for a smooth transition after #22215
| * | | | | | | | | | | add deprecations for a smooth transition after #22215Michael Grosser2015-11-196-4/+72
| | |/ / / / / / / / / | |/| | | | | | | | |
* | | | | | | | | | | Merge pull request #22347 from kamipo/fix_test_index_in_createSean Griffin2015-11-192-6/+6
|\ \ \ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | Fix test failure in `adapters/mysql/active_schema_test.rb`
| * | | | | | | | | | | Fix test failure in `adapters/mysql/active_schema_test.rb`Ryuta Kamizono2015-11-202-6/+6
|/ / / / / / / / / / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Follow up to #21601.
* | | | | | | | | | | Revert "Allow specifying the default table options for mysql adapters"Sean Griffin2015-11-193-26/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This reverts commit 8246b593bff71f2cebf274c133bb8917f1e094c8. There was concern about this modifying the behavior of past migrations. We're going to add an way to modify the migration generator instead.
* | | | | | | | | | | Allow specifying the default table options for mysql adaptersSean Griffin2015-11-193-1/+26
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | It's often the case that you want to have an option that you cannot specify at the database level, but want applied to *all* tables that you create. For example, you might want to specify `ROW_FORMAT=DYNAMIC` to not have to limit text columns to length 171 for indexing when using utf8mb4. This allows an easy way to specify this in your database configuration. While this change affects both MySQL and MySQL2, the test only covers MySQL2, as the legacy mysql adapter appears to always return ASCII strings, and is tangential to what we're actually doing.
* | | | | | | | | | | Merge pull request #22336 from tjschuck/enumerable_sum_perfKasper Timm Hansen2015-11-191-1/+1
|\ \ \ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | Change Enumerable#sum to use inject(:sym) specification
| * | | | | | | | | | | Change Enumerable#sum to use inject(:sym) specificationT.J. Schuck2015-11-191-1/+1
| |/ / / / / / / / / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Not only does this make for simpler, more obvious code, it's also more performant: require 'benchmark/ips' module Enumerable def old_sum(identity = 0, &block) if block_given? map(&block).old_sum(identity) else inject { |sum, element| sum + element } || identity end end def new_sum(identity = 0, &block) if block_given? map(&block).new_sum(identity) else inject(:+) || identity end end end summable = (1..100).to_a # sum is 5050 Benchmark.ips do |x| x.report("old_sum") { summable.old_sum } x.report("new_sum") { summable.new_sum } x.compare! end # Calculating ------------------------------------- # old_sum 10.674k i/100ms # new_sum 14.542k i/100ms # ------------------------------------------------- # old_sum 117.350k (± 7.1%) i/s - 587.070k # new_sum 154.712k (± 3.8%) i/s - 785.268k # # Comparison: # new_sum: 154712.1 i/s # old_sum: 117350.0 i/s - 1.32x slower More benchmarks [here](https://gist.github.com/tjschuck/b3fe4e8c812712376648), including summing strings and passing blocks. The performance gains are less for those, but this version still always wins.
* | | | | | | | | | | Merge pull request #22340 from rbr/change-configuration-exampleYves Senn2015-11-191-1/+1
|\ \ \ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | Change configuration-guide example [ci skip]
| * | | | | | | | | | | Change configuration-guide examplerbr2015-11-191-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Use an example from a default Rails app (4.2.5) rather than an outdated one in the Configuring Rails Components section. I picked config.time_zone as it currently is the only 'setting for Rails' left in a default config/application.rb. I stumbled upon this with investigating autoloading in a legacy app, which still included the example comment "# config.autoload_paths += %W(#{config.root}/extras)". Usually adding app/* directories to autoload_paths isn't necessary, so also finding this example within the current docs was a bit confusing initially. [ci skip]
* | | | | | | | | | | | Merge pull request #22342 from AlexVPopov/patch-1Abdelkader Boudih2015-11-191-1/+1
|\ \ \ \ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | Fix a typo [ci skip]
| * | | | | | | | | | | | Fix a typoAlex Popov2015-11-191-1/+1
|/ / / / / / / / / / / /
* | | | | | | | | | | | Merge pull request #22077 from obduk/clean-up-logsKasper Timm Hansen2015-11-191-3/+3
|\ \ \ \ \ \ \ \ \ \ \ \ | |/ / / / / / / / / / / |/| | | | | | | | | | | Remove newlines from start of logs
| * | | | | | | | | | | Remove newlines from start of logsOwen Davies2015-10-261-3/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Currently if using a single line logger, this causes the time stamp and log message to be on separate lines which is not common to how most other logging works.
* | | | | | | | | | | | guides, scaffold no longer used in getting started guide. Closes #22337.Yves Senn2015-11-191-6/+24
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | [ci skip] Since the "Getting Started" guide no longer uses the scaffold generator we should rewrite references to that in the testing guide. The functional testing section was quite heavily based on such a scaffold test. I changed it to use `generate scaffold_controller` instead so that we can build up on the model foundation we already have.
* | | | | | | | | | | | Merge pull request #22338 from zacharywelch/patch-1Rafael França2015-11-191-2/+2
|\ \ \ \ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | [ci skip] Indentation in API app guide
| * | | | | | | | | | | | [ci skip] Indentation in cache exampleszacharywelch2015-11-181-2/+2
|/ / / / / / / / / / / /
* | / / / / / / / / / / Add missing requireMatthew Draper2015-11-191-0/+2
| |/ / / / / / / / / / |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Fixes #22311
* | | | | | | | | | | Merge pull request #22330 from samphilipd/samphilipd/rename_advisory_lock_keyRafael França2015-11-188-65/+65
|\ \ \ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | Rename 'key' to 'lock_id' or 'lock_name' for advisory locking
| * | | | | | | | | | | Rename 'key' to 'lock_id' or 'lock_name' for advisory lockingSam Davies2015-11-188-65/+65
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | - key was a poor choice of name. A key implies something that will unlock a lock. The concept is actually more like a 'lock identifier' - mysql documentation calls this a 'lock name' - postgres documentation calls it a 'lock_id' - Updated variable names to reflect the preferred terminology for the database in question
* | | | | | | | | | | | Revert "Fixed a few grammar issues."Rafael Mendonça França2015-11-182-2/+2
|/ / / / / / / / / / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This reverts commit 16ce41b7f4449d6df15df30d69aef18da6510f36. Reason: See https://github.com/rails/rails/commit/16ce41b7f4449d6df15df30d69aef18da6510f36#commitcomment-14475125
* | | | | | | | | | | Merge pull request #22328 from k0kubun/upgrade-byebugKasper Timm Hansen2015-11-181-1/+1
|\ \ \ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | Use latest byebug
| * | | | | | | | | | | Use latest byebugTakashi Kokubun2015-11-181-1/+1
| | | | | | | | | | | |
* | | | | | | | | | | | Merge pull request #22326 from mvj3/minor-grammar-issuesRafael França2015-11-182-2/+2
|\ \ \ \ \ \ \ \ \ \ \ \ | |/ / / / / / / / / / / |/| | | | | | | | | | | Fixed a few grammar issues.
| * | | | | | | | | | | Fixed a few grammar issues.David Chen2015-11-182-2/+2
|/ / / / / / / / / / /
* | | | | | | | | | | Merge pull request #22323 from jessedoyle/patch-1Claudio B2015-11-171-1/+1
|\ \ \ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | [ci skip] fix inconsistent indentation
| * | | | | | | | | | | [ci skip] fix inconsistent indentationJesse Doyle2015-11-171-1/+1
|/ / / / / / / / / / /
* | | | | | | | | | | Fix incorrect issue number [ci skip]Andrew White2015-11-171-1/+1
| | | | | | | | | | |
* | | | | | | | | | | Merge pull request #22316 from yui-knk/changelog_for_22300Andrew White2015-11-171-0/+6
|\ \ \ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | [ci skip] Add CHANGELOG for #22300 (817c1825c15013fd0180762ac5c05a2e0…
| * | | | | | | | | | | [ci skip] Add CHANGELOG for #22300 (817c1825c15013fd0180762ac5c05a2e024a640d)yui-knk2015-11-181-0/+6
| | | | | | | | | | | |
* | | | | | | | | | | | Raise ArgumentError when passing a truthy value to mergeAndrew White2015-11-172-5/+10
|/ / / / / / / / / / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | In b71e08f we started raising when nil or false was passed to merge to fix #12264, however we should also do this for truthy values that are invalid like true.
* | | | | | | | | | | Merge pull request #22271 from ↵Yves Senn2015-11-171-0/+32
|\ \ \ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | timbreitkreutz/twb-9015-schema-dumper-test-for-prefix-and-ignore Test case for Issue #9015 - ignore_table and table_prefix at same time
| * | | | | | | | | | | TWB Test case for Issue #9015 - ignore_table and table_prefix at same timeTim Breitkreutz2015-11-131-0/+32
| | | | | | | | | | | |
* | | | | | | | | | | | Merge pull request #22257 from yui-knk/fix_merge_to_not_call_to_proc_for_hashAndrew White2015-11-172-3/+9
|\ \ \ \ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | Make `AR::SpawnMethods#merge!` to check an arg is a Proc
| * | | | | | | | | | | | Make `AR::SpawnMethods#merge!` to check an arg is a Procyui-knk2015-11-122-3/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | From Ruby ( 2.3.0dev trunk 52520), `Hash#to_proc` is defined (https://github.com/ruby/ruby/commit/fbe967ec02cb65a7efa3fb8f3d747cf6f620dde1), and many tests have been failed with `ArgumentError: wrong number of arguments (given 0, expected 1)`. Because we call `Hash#to_proc` with no args in `#merge!`. This commit changes order of conditionals to not call `Hash#to_proc`.
* | | | | | | | | | | | | Using released concurrent-rubyRafael Mendonça França2015-11-162-3/+3
| | | | | | | | | | | | |
* | | | | | | | | | | | | Merge pull request #22215 from grosser/grosser/normalize_keyRafael França2015-11-165-39/+39
|\ \ \ \ \ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | send normalized keys to the cache backends so they do not need to man…
| * | | | | | | | | | | | | keep deprecated namespaced_key in case any subclass uses itMichael Grosser2015-11-103-2/+3
| | | | | | | | | | | | | |
| * | | | | | | | | | | | | send normalized keys to the cache backends so they do not need to manage ↵Michael Grosser2015-11-105-38/+37
| |/ / / / / / / / / / / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | this themselves
* | | | | | | | | | | | | Merge pull request #22300 from yui-knk/fix_21893Sean Griffin2015-11-165-5/+23
|\ \ \ \ \ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | Except keys of `build_record`'s argument from `create_scope` in initi…