aboutsummaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
...
| * | | | | | | | | | | | Fixing issue when delegating to methods named "block", "args", or "arg"Jake Bell2015-08-192-5/+21
| | | | | | | | | | | | |
* | | | | | | | | | | | | Fix test failures caused by d99db6b8b3e4Sean Griffin2015-10-201-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | I messed up the merge conflict, and accidentally removed a schema query that needed to be ignored.
* | | | | | | | | | | | | Merge pull request #21756 from soutaro/qualify-column-in-calculationSean Griffin2015-10-203-1/+27
|\ \ \ \ \ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Qualify column names in calculation
| * | | | | | | | | | | | | Qualify column names in calculationSoutaro Matsumoto2015-10-203-1/+27
|/ / / / / / / / / / / / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Column names inserted via `group` have to be qualified with table name.
* | | | | | | | | | | | | Merge pull request #18856 from al2o3cr/issue_17897Sean Griffin2015-10-202-3/+11
|\ \ \ \ \ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Match table names exactly on MySQL
| * | | | | | | | | | | | | Fix merge conflicts for #18856Sean Griffin2015-10-202-3/+11
|/| | | | | | | | | | | | |
| * | | | | | | | | | | | | Match table names exactly on MySQLMatt Jones2015-02-084-18/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The `SHOW TABLES LIKE` command accepts metacharacters `%` and `_` in potentially unexpected ways. This can be avoided by querying `information_schema.tables` directly. Fixes #17897
* | | | | | | | | | | | | | Don't add classes to the top level namespaceSean Griffin2015-10-201-13/+17
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | I've been writing too much Rust. My mind is still in the mode of things being auto-namespaced based on the file...
* | | | | | | | | | | | | | Merge pull request #21883 from tarzan/cache-key-too-preciseSean Griffin2015-10-206-8/+43
|\ \ \ \ \ \ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Fix precision on cache_key
| * | | | | | | | | | | | | | fixes #21815Maarten Jacobs2015-10-166-8/+43
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The default timestamp used for AR is `updated_at` in nanoseconds! (:nsec) This causes issues on any machine that runs an OS that supports nanoseconds timestamps, i.e. not-OS X, where the cache_key of the record persisted in the database (milliseconds precision) is out-of-sync with the cache_key in the ruby VM. This commit adds: A test that shows the issue, it can be found in the separate file `cache_key_test.rb`, because - model couldn't be defined inline - transactional testing needed to be turned off to get it to pass the MySQL tests This seemed cleaner than putting it in an existing testcase file. It adds :usec as a dateformat that calculates datetime in microseconds It sets precision of cache_key to :usec instead of :nsec, as no db supports nsec precision on timestamps
* | | | | | | | | | | | | | | Do not cache prepared statements that are unlikely to have cache hitsSean Griffin2015-10-2012-20/+69
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Prior to this commit, Rails makes no differentiation between whether a query uses bind parameters, and whether or not we cache that query as a prepared statement. This leads to the cache populating extremely fast in some cases, with the statements never being reused. In particular, the two problematic cases are `where(foo: [1, 2, 3])` and `where("foo = ?", 1)`. In both cases we'll end up quoting the values rather than using a bind param, causing a cache entry for every value ever used in that query. It was noted that we can probably eventually change `where("foo = ?", 1)` to use a bind param, which would resolve that case. Additionally, on PG we can change our generated query to be `WHERE foo = ANY($1)`, and pass an array for the bind param. I hope to accomplish both in the future. For SQLite and MySQL, we still end up preparing the statements anyway, we just don't cache it. The statement will be cleaned up after it is executed. On postgres, we skip the prepare step entirely, as an API is provided to execute with bind params without preparing the statement. I'm not 100% happy on the way this ended up being structured. I was hoping to use a decorator on the visitor, rather than mixing a module into the object, but the way Arel has it's visitor pattern set up makes it very difficult to extend without inheritance. I'd like to remove the duplication from the various places that are extending it, but that'll require a larger restructuring of that initialization logic. I'm going to take another look at the structure of it soon. This changes the signature of one of the adapter's internals, and will require downstream changes from third party adapters. I'm not too worried about this, as worst case they can simply add the parameter and always ignore it, and just keep their previous behavior. Fixes #21992.
* | | | | | | | | | | | | | | Merge pull request #21932 from kamipo/add_stored_procedure_test_in_mysql2Sean Griffin2015-10-208-22/+70
|\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add stored procedure test in mysql2
| * | | | | | | | | | | | | | | Add stored procedure test in mysql2Ryuta Kamizono2015-10-156-17/+65
| | | | | | | | | | | | | | | |
| * | | | | | | | | | | | | | | Make `AbstractMysqlAdapter#version` publicRyuta Kamizono2015-10-152-5/+5
| | | | | | | | | | | | | | | |
* | | | | | | | | | | | | | | | Merge pull request #21962 from kamipo/fix_tinyblobSean Griffin2015-10-208-16/+36
|\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Fix to correctly schema dump the `tinyblob`
| * | | | | | | | | | | | | | | | Fix to correctly schema dump the `tinyblob`Ryuta Kamizono2015-10-158-16/+36
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Currently `tinyblob` is dumped to `t.binary "tiny_blob", limit: 255`. But `t.binary ... limit: 255` is generating SQL to `varchar(255)`. It is incorrect. This commit fixes this problem.
* | | | | | | | | | | | | | | | | Upgrade all the gemsRafael Mendonça França2015-10-201-36/+47
| | | | | | | | | | | | | | | | |
* | | | | | | | | | | | | | | | | Merge branch 'fix-21955'Rafael Mendonça França2015-10-203-1/+27
|\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \
| * | | | | | | | | | | | | | | | | Add CHANGELOG entry for fix of #21955 [ci skip]Rafael Mendonça França2015-10-201-0/+6
| | | | | | | | | | | | | | | | | |
| * | | | | | | | | | | | | | | | | Merge pull request #21974 from ↵Rafael Mendonça França2015-10-202-5/+20
| |\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | jbranchaud/reorder-has-many-assocation-constraints Reorder application of has_many association constraints.
| | * | | | | | | | | | | | | | | | | Reorder application of has_many association constraints.jbranchaud2015-10-192-1/+21
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | With `unscope!` called last, it undoes `where` constraints of the same value when the `where` is chained after the `unscope`. This is what a `rewhere` does. This is undesirable behavior. The included tests demonstrate both the `unscope(...).where(...)` behavior as well as the direct use of `rewhere(...)`. This is in reference to #21955.
| * | | | | | | | | | | | | | | | | | Changed the order of Association constraints from where->order->unscope to ↵kal2015-10-203-1/+6
|/ / / / / / / / / / / / / / / / / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | unscope->where->order
* | | | | | | | | | | | | | | | | | Merge pull request #21858 from Gaurav2728/protected_method_nodocRafael Mendonça França2015-10-201-3/+3
|\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | nodoc for active support protected method [CI skip]
| * | | | | | | | | | | | | | | | | | nodoc for active support protected method [CI skip]Gaurav Sharma2015-10-041-3/+3
| | | | | | | | | | | | | | | | | | |
* | | | | | | | | | | | | | | | | | | Merge pull request #22003 from yui-knk/remove_needless_require_asYves Senn2015-10-2010-13/+0
|\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Delete needless `require 'active_support/deprecation'`
| * | | | | | | | | | | | | | | | | | | Delete needless `require 'active_support/deprecation'`yui-knk2015-10-2010-13/+0
| | |/ / / / / / / / / / / / / / / / / | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When `require 'active_support/rails'`, 'active_support/deprecation' is automatically loaded.
* | | | | | | | | | | | | | | | | | | Merge pull request #22004 from yui-knk/fix_method_to_actionYves Senn2015-10-201-1/+1
|\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | [ci skip] Replace "destroy` method" with `destroy` action`
| * | | | | | | | | | | | | | | | | | | [ci skip] Replace "destroy` method" with `destroy` action`yui-knk2015-10-201-1/+1
|/ / / / / / / / / / / / / / / / / / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Sure this is `destroy` method of PhotosController, but in this chapter these methods which mapped by the router are called "action". For example: ```ruby get '/patients/:id', to: 'patients#show' ``` is described to dispatch "controller's `show` action".
* | | | | | | | | | | | | | | | | | | Merge pull request #21978 from ctreatma/console_helper_reloadSean Griffin2015-10-191-1/+1
|\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Fix #21977: Removes memoization of helpers in Rails console
| * | | | | | | | | | | | | | | | | | | Fix #21977: Removes memoization of helpers in Rails consoleCharles Treatman2015-10-161-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | In the Rails console, the `helper` function provides a shorthand for working with application helpers. However, `helper` memoizes the value of `ApplicationController#helpers`. This means that if a user subsequently changes helper code and calls `reload!` in the console, their code changes will not be reflected by the `helper` function, even though the helper was, in fact, reloaded.
* | | | | | | | | | | | | | | | | | | | Merge pull request #21987 from yui-knk/refactor_whereSean Griffin2015-10-193-10/+7
|\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Green version of moving the handling of supported arguments to `where`
| * | | | | | | | | | | | | | | | | | | | Green version of moving the handling of supported arguments to `where`yui-knk2015-10-183-10/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This commit follow up of 4d8f62d. The difference from 4d8f62d are below: * Change `WhereClauseFactory` to accept `Arel::Nodes::Node` * Change test cases of `relation_test.rb`
* | | | | | | | | | | | | | | | | | | | | Merge pull request #22001 from cleverlemming/doc_patch_enginesSean Griffin2015-10-191-1/+1
|\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Added context for running engine:migrations:install task. [ci skip]
| * | | | | | | | | | | | | | | | | | | | | added Rails 4 context for migrations:install taskSimon H2015-10-191-1/+1
|/ / / / / / / / / / / / / / / / / / / / /
* | | | | | | | | | | | | | | | | | | | | Merge pull request #21991 from philr/doc_tzinfo_no_longer_bundledClaudio B.2015-10-191-6/+0
|\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Remove outdated documentation regarding a bundled version of TZInfo
| * | | | | | | | | | | | | | | | | | | | | Remove outdated statement about bundled TZInfo.Phil Ross2015-10-181-6/+0
| | |_|/ / / / / / / / / / / / / / / / / / | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The bundled version of TZInfo referred to was removed from Active Support in version 3.0.
* | | | | | | | | | | | | | | | | | | | | Merge pull request #21999 from agis-/param-encoding-errorsSantiago Pastorino2015-10-194-8/+27
|\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ | |/ / / / / / / / / / / / / / / / / / / / |/| | | | | | | | | | | | | | | | | | | | Show helpful messages on invalid param. encodings
| * | | | | | | | | | | | | | | | | | | | Show helpful messages on invalid param. encodingsAgis Anastasopoulos2015-10-194-8/+27
|/ / / / / / / / / / / / / / / / / / / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Prior to this change, given a route: # config/routes.rb get ':a' => "foo#bar" If one pointed to http://example.com/%BE (param `a` has invalid encoding), a `BadRequest` would be raised with the following non-informative message: ActionController::BadRequest From now on the message displayed is: Invalid parameter encoding: hi => "\xBE" Fixes #21923.
* | | | | | | | | | | | | | | | | | | | Merge pull request #21988 from y-yagi/remove_useless_methodArthur Nogueira Neves2015-10-181-4/+0
|\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | remove useless method
| * | | | | | | | | | | | | | | | | | | | remove useless methodyuuji.yaginuma2015-10-181-4/+0
| |/ / / / / / / / / / / / / / / / / / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | `images` method has been deleted in 2bc4856, `create_images_directory` does nothing.
* | | | | | | | | | | | | | | | | | | | Merge pull request #21989 from imtayadeway/guides/active-model-basicsEileen M. Uchitelle2015-10-181-7/+7
|\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ | |/ / / / / / / / / / / / / / / / / / / |/| | | | | | | | | | | | | | | | | | | [ci skip] Improve readability in active model basics guide
| * | | | | | | | | | | | | | | | | | | [ci skip] Improve readability in active model basics guideTim Wade2015-10-181-7/+7
|/ / / / / / / / / / / / / / / / / / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * adds/removes a few words * removes an unnecessary comma
* | | | | | | | | | | | | | | | | | | Revert "Move the handling of supported arguments to `where`"Rafael Mendonça França2015-10-172-1/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This reverts commit 4d8f62dcfa0a5157b3facbd71f75fc6639636347. Reason: This broke the build. Please recommit again when it is green.
* | | | | | | | | | | | | | | | | | | Merge pull request #21982 from yui-knk/test_suppress_warningYves Senn2015-10-171-2/+0
|\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Suppress warnings of `assigned but unused variable`
| * | | | | | | | | | | | | | | | | | | Suppress warnings of `assigned but unused variable`yui-knk2015-10-171-2/+0
| | | | | | | | | | | | | | | | | | | |
* | | | | | | | | | | | | | | | | | | | Merge pull request #21980 from maratgaliev/timezones_fixRichard Schneeman2015-10-172-2/+2
|\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ | |/ / / / / / / / / / / / / / / / / / / |/| | | | | | | | | | | | | | | | | | | Use "rake time:zones:all" instead of "rake -D time" [ci skip]
| * | | | | | | | | | | | | | | | | | | Use "rake time:zones:all" instead of "rake -D time" [ci skip]Marat Galiev2015-10-172-2/+2
|/ / / / / / / / / / / / / / / / / / /
* / / / / / / / / / / / / / / / / / / [ci skip] Add backend queue starting documentationschneems2015-10-161-3/+12
|/ / / / / / / / / / / / / / / / / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | If you can't start your queue, you won't process much. This change adds external links to the Queue backends that have Active Job specific docs.
* | | | | | | | | | | | | | | | | | Move the handling of supported arguments to `where`Sean Griffin2015-10-162-3/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | `WhereClauseFactory` handles all other branches based on argument types, so the code fits more naturally here, and it's just where the responsibility belongs.
* | | | | | | | | | | | | | | | | | Merge pull request #21953 from bdunne/fix_dep_warnMatthew Draper2015-10-175-20/+92
|\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Fix deprecation warning messages on deprecate_methods