aboutsummaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
...
| * | | | | | | | | Extract `sanitize_as_sql_comment` from SQL visitor into connectionRyuta Kamizono2019-03-195-8/+15
| |/ / / / / / / / | | | | | | | | | | | | | | | | | | | | | | | | | | | Probably that is useful for any other feature as well.
* | | | | | | | | Merge pull request #35669 from cpruitt/update-mime-type-regexpAaron Patterson2019-03-192-1/+19
|\ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | Update regular expression for checking valid MIME type
| * | | | | | | | | Update regular expression for checking valid MIME typeCliff Pruitt2019-03-192-1/+19
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | MIME Type validation regular expression does not allow for MIME types initialized with strings that contain parameters after the MIME type name.
* | | | | | | | | | Instrument middleware processingDaniel Schierbeck2019-03-192-7/+57
|/ / / / / / / / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Adds ActiveSupport::Notifications instrumentation of the processing of each middleware in the stack.
* | | | | | | | | Merge pull request #35358 from tjwallace/patch-1Eileen M. Uchitelle2019-03-191-0/+3
|\ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | Add documentation for the resource(s) :param option
| * | | | | | | | | Add documentation for the resource(s) :param optionJeff Wallace2019-02-211-0/+3
| | | | | | | | | |
* | | | | | | | | | update_at/on note for ActiveRecord::Relation.update_all (#35461)Orhan Toy2019-03-191-2/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * update_at/on note for ActiveRecord::Relation.update_all * Verbatim updated_at/on
* | | | | | | | | | Merge pull request #35604 from jhawthorn/validate_mime_typesEileen M. Uchitelle2019-03-194-4/+45
|\ \ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | Raise exception when building invalid mime type
| * | | | | | | | | | Raise exception when building invalid mime typeJohn Hawthorn2019-03-144-4/+45
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This allows mime types in the form text/html, text/*, or */* This required a few minor test/code changes where previously nil was used as a mime string.
* | | | | | | | | | | Merge pull request #35620 from RTJ/masterEileen M. Uchitelle2019-03-191-1/+3
|\ \ \ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | Fix for migration active_storage migration
| * | | | | | | | | | | Traducir del: inglésEugeniu Tambur2019-03-191-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 44/5000 Checking for the existence of only one table
| * | | | | | | | | | | Fix for migration active_storage migrationEugeniu Tambur2019-03-151-1/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | *ActiveRecord::StatementInvalid: PG::UndefinedTable: ERROR: relation "active_storage_attachments" does not exist* Updating to rails 6.0.0.beta3 if the command rake app:update is used a new migration file is generated: ```ruby # db/migrate/add_foreign_key_constraint_to_active_storage_attachments_for_blob_id.active_storage.rb class AddForeignKeyConstraintToActiveStorageAttachmentsForBlobId < ActiveRecord::Migration[6.0] def up unless foreign_key_exists?(:active_storage_attachments, column: :blob_id) add_foreign_key :active_storage_attachments, :active_storage_blobs, column: :blob_id end end end ``` **If the project does not have previously installed active storage** this mgiration causes an error: ActiveRecord::StatementInvalid: PG::UndefinedTable: ERROR: relation "active_storage_attachments" does not exist **Error output:** PG::UndefinedTable: ERROR: relation "active_storage_attachments" does not exist activerecord-6.0.0.beta3/lib/active_record/connection_adapters/postgresql/database_statements.rb:90:in `async_exec' activerecord-6.0.0.beta3/lib/active_record/connection_adapters/postgresql/database_statements.rb:90:in `block (2 levels) in execute' activesupport-6.0.0.beta3/lib/active_support/dependencies/interlock.rb:48:in `block in permit_concurrent_loads' activesupport-6.0.0.beta3/lib/active_support/concurrency/share_lock.rb:187:in `yield_shares' activesupport-6.0.0.beta3/lib/active_support/dependencies/interlock.rb:47:in `permit_concurrent_loads' activerecord-6.0.0.beta3/lib/active_record/connection_adapters/postgresql/database_statements.rb:89:in `block in execute' activerecord-6.0.0.beta3/lib/active_record/connection_adapters/abstract_adapter.rb:643:in `block (2 levels) in log' activerecord-6.0.0.beta3/lib/active_record/connection_adapters/abstract_adapter.rb:642:in `block in log' activesupport-6.0.0.beta3/lib/active_support/notifications/instrumenter.rb:23:in `instrument' activerecord-6.0.0.beta3/lib/active_record/connection_adapters/abstract_adapter.rb:633:in `log' activerecord-6.0.0.beta3/lib/active_record/connection_adapters/postgresql/database_statements.rb:88:in `execute' activerecord-6.0.0.beta3/lib/active_record/connection_adapters/abstract/schema_statements.rb:977:in `add_foreign_key' activerecord-6.0.0.beta3/lib/active_record/migration.rb:875:in `block in method_missing' activerecord-6.0.0.beta3/lib/active_record/migration.rb:843:in `block in say_with_time' activerecord-6.0.0.beta3/lib/active_record/migration.rb:843:in `say_with_time' activerecord-6.0.0.beta3/lib/active_record/migration.rb:864:in `method_missing' /db/migrate/20190315102607_add_foreign_key_constraint_to_active_storage_attachments_for_blob_id.active_storage.rb:5:in `up' activerecord-6.0.0.beta3/lib/active_record/migration.rb:816:in `exec_migration' activerecord-6.0.0.beta3/lib/active_record/migration.rb:797:in `block (2 levels) in migrate' activerecord-6.0.0.beta3/lib/active_record/migration.rb:796:in `block in migrate' activerecord-6.0.0.beta3/lib/active_record/connection_adapters/abstract/connection_pool.rb:416:in `with_connection' activerecord-6.0.0.beta3/lib/active_record/migration.rb:795:in `migrate' activerecord-6.0.0.beta3/lib/active_record/migration.rb:985:in `migrate' activerecord-6.0.0.beta3/lib/active_record/migration.rb:1293:in `block in execute_migration_in_transaction' activerecord-6.0.0.beta3/lib/active_record/migration.rb:1344:in `block in ddl_transaction' activerecord-6.0.0.beta3/lib/active_record/connection_adapters/abstract/database_statements.rb:265:in `block in transaction' activerecord-6.0.0.beta3/lib/active_record/connection_adapters/abstract/transaction.rb:272:in `block in within_new_transaction' activerecord-6.0.0.beta3/lib/active_record/connection_adapters/abstract/transaction.rb:270:in `within_new_transaction' activerecord-6.0.0.beta3/lib/active_record/connection_adapters/abstract/database_statements.rb:265:in `transaction' activerecord-6.0.0.beta3/lib/active_record/transactions.rb:212:in `transaction' activerecord-6.0.0.beta3/lib/active_record/migration.rb:1344:in `ddl_transaction' activerecord-6.0.0.beta3/lib/active_record/migration.rb:1292:in `execute_migration_in_transaction' activerecord-6.0.0.beta3/lib/active_record/migration.rb:1264:in `block in migrate_without_lock' activerecord-6.0.0.beta3/lib/active_record/migration.rb:1263:in `each' activerecord-6.0.0.beta3/lib/active_record/migration.rb:1263:in `migrate_without_lock' activerecord-6.0.0.beta3/lib/active_record/migration.rb:1211:in `block in migrate' activerecord-6.0.0.beta3/lib/active_record/migration.rb:1364:in `with_advisory_lock' activerecord-6.0.0.beta3/lib/active_record/migration.rb:1211:in `migrate' activerecord-6.0.0.beta3/lib/active_record/migration.rb:1044:in `up' activerecord-6.0.0.beta3/lib/active_record/migration.rb:1019:in `migrate' activerecord-6.0.0.beta3/lib/active_record/tasks/database_tasks.rb:191:in `migrate' activerecord-6.0.0.beta3/lib/active_record/railties/databases.rake:78:in `block (3 levels) in <main>' activerecord-6.0.0.beta3/lib/active_record/railties/databases.rake:76:in `each' activerecord-6.0.0.beta3/lib/active_record/railties/databases.rake:76:in `block (2 levels) in <main>' railties-6.0.0.beta3/lib/rails/commands/rake/rake_command.rb:23:in `block in perform' railties-6.0.0.beta3/lib/rails/commands/rake/rake_command.rb:20:in `perform' railties-6.0.0.beta3/lib/rails/command.rb:48:in `invoke' railties-6.0.0.beta3/lib/rails/commands.rb:18:in `<main>' bootsnap-1.4.1/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:21:in `require' bootsnap-1.4.1/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:21:in `block in require_with_bootsnap_lfi' bootsnap-1.4.1/lib/bootsnap/load_path_cache/loaded_features_index.rb:83:in `register' bootsnap-1.4.1/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:20:in `require_with_bootsnap_lfi' bootsnap-1.4.1/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:29:in `require' activesupport-6.0.0.beta3/lib/active_support/dependencies.rb:297:in `block in require' activesupport-6.0.0.beta3/lib/active_support/dependencies.rb:263:in `load_dependency' activesupport-6.0.0.beta3/lib/active_support/dependencies.rb:297:in `require' bin/rails:4:in `<main>'
* | | | | | | | | | | | Merge pull request #35667 from sharang-d/fix-content-test-nameEileen M. Uchitelle2019-03-191-1/+1
|\ \ \ \ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | Fix a ContentNegotiation test description
| * | | | | | | | | | | | Fix a ContentNegotiation test descriptionSharang Dashputre2019-03-191-1/+1
| | | | | | | | | | | | |
* | | | | | | | | | | | | depend on Zeitwerk 1.4.0Xavier Noria2019-03-193-4/+8
| | | | | | | | | | | | |
* | | | | | | | | | | | | Merge pull request #35659 from rails/fix-time-advance-with-historical-datesAndrew White2019-03-193-2/+17
|\ \ \ \ \ \ \ \ \ \ \ \ \ | |/ / / / / / / / / / / / |/| | | | | | | | | | | | Fix Time#advance to work with dates before 1001-03-07
| * | | | | | | | | | | | Fix Time#advance to work with dates before 1001-03-07Andrew White2019-03-183-2/+17
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | In #10634 the behavior of Time#advance was changed to maintain a proleptic gregorian calendar for dates before calendar reform. However it didn't full address dates a long time before calendar reform and they gradually drift away from the proleptic calendar the further you go back in time. Fix this by always converting the date to gregorian before calling advance which sets the reform date to -infinity.
* | | | | | | | | | | | | Merge pull request #35663 from ↵Eileen M. Uchitelle2019-03-182-1/+3
|\ \ \ \ \ \ \ \ \ \ \ \ \ | |_|_|_|_|_|/ / / / / / / |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | eileencodes/fix-database-configuration-when-not-actually-a-three-tier Fix database configuration when adding another config level
| * | | | | | | | | | | | Fix database configuration when adding another config leveleileencodes2019-03-182-1/+3
| | |_|_|_|/ / / / / / / | |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This is kind of hard to explain but if you have a database config with another level like this: ``` development: primary: database: "my db" variables: statement_timeout: 1000 ``` the database configurations code would chooke on the `variables` level because it didn't know what to do with it. We'd see the following error: ``` lib/active_record/database_configurations.rb:72:in `block in find_db_config': undefined method `env_name' for [nil]:Array (NoMethodError) ``` The problem here is that Rails does correctly identify this as not a real configuration but returns `[nil]` along with the others. We need to make sure to flatten the array and remove all the `nil`'s before returning the `configurations` objects. Fixes #35646
* | | | | | | | | | | | Simplify values_list with more compositionKasper Timm Hansen2019-03-181-24/+30
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This also prevents insert_all from leaking its attributes checks.
* | | | | | | | | | | | Extract column check in values_listKasper Timm Hansen2019-03-181-14/+14
|/ / / / / / / / / / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | `values_list` is quite long and does far too many things. This also eagerly extract the keys in initialize instead of having to worry about calling them multiple times.
* | | | | | | | | | | Don't expose internal `type_casted_binds` methodRyuta Kamizono2019-03-192-8/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Internal usage for the method as public has removed at #29623.
* | | | | | | | | | | Added release notes for changes in Railties [ci skip] (#35622)प्रथमेश Sonpatki2019-03-182-2/+65
|/ / / / / / / / / / | | | | | | | | | | | | | | | | | | | | [Alex Kitchens, Prathamesh Sonpatki]
* | | | | | | | | | Merge pull request #35652 from razh/revert-rails-ujs-html-contentKasper Timm Hansen2019-03-182-3/+3
|\ \ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | Revert "Pass HTML responses as plain-text in rails-ujs"
| * | | | | | | | | | Add regression test for HTML content in rails-ujsrazh2019-03-171-0/+11
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | See discussion in #32287
| * | | | | | | | | | Revert "Pass HTML responses as plain-text in rails-ujs"razh2019-03-172-12/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This reverts commit 48e44edfd0a8a7a29aa8fad39638ac0ee5243f42. See discussion in #32287 For HTML content in `ajax:success` handlers, `event.detail[0]` should be an `HTMLDocument` instance.
* | | | | | | | | | | Merge pull request #35653 from kamipo/remove_arel_nodes_valuesRyuta Kamizono2019-03-1811-74/+22
|\ \ \ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | Get rid of `Arel::Nodes::Values`
| * | | | | | | | | | | Get rid of `Arel::Nodes::Values`Ryuta Kamizono2019-03-1811-74/+22
| |/ / / / / / / / / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | That is completely covered by `Arel::Nodes::ValuesList`. Related https://github.com/rails/arel/pull/484.
* | | | | | | | | | | Add test case to prevent possible SQL injectionRyuta Kamizono2019-03-183-1/+23
| | | | | | | | | | |
* | | | | | | | | | | Fix updating rich text via nested attributesGeorge Claghorn2019-03-176-7/+40
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Closes #35159.
* | | | | | | | | | | Merge pull request #35654 from t-richards/bugfix/referrer-policy-errorRyuta Kamizono2019-03-181-1/+1
|\ \ \ \ \ \ \ \ \ \ \ | |/ / / / / / / / / / |/| | | | | | | | | | Fix invalid suggestion in null origin error message
| * | | | | | | | | | Suggest 'strict-origin' Referrer-Policy headerTom Richards2019-03-171-1/+1
|/ / / / / / / / / /
* | | | | | | | | | Ruby 2.4 and later support native Unicode case mappingsRyuta Kamizono2019-03-181-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Here is only place where we use `mb_chars` internally.
* | | | | | | | | | Add `:reselect` and `:optimizer_hints` to the list of finder methodsRyuta Kamizono2019-03-181-0/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | These are introduced after Rails 6.0.0 beta2. [ci skip]
* | | | | | | | | | Add test case for unscoping `:optimizer_hints`Ryuta Kamizono2019-03-183-1/+13
| | | | | | | | | |
* | | | | | | | | | Tweak `truncate_tables`Ryuta Kamizono2019-03-182-18/+18
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Remove redundant `table_names.empty?` * Early return in `truncate_tables` since it is already deeply nested * Move `truncate_tables` out from between `exec_delete` and `exec_update`
* | | | | | | | | | SQLite3: Make fixture loading to bulk statementsRyuta Kamizono2019-03-175-53/+40
| | | | | | | | | |
* | | | | | | | | | Fix undefined local variable or method `discard_remaining_results'Ryuta Kamizono2019-03-171-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | https://buildkite.com/rails/rails/builds/59632#fe3d2551-569a-46c8-94f3-7abe835d4d7a/122-153
* | | | | | | | | | Ensure `execute_batch` discards remaining resultsRyuta Kamizono2019-03-172-14/+5
| | | | | | | | | |
* | | | | | | | | | Make `truncate_tables` to bulk statementsRyuta Kamizono2019-03-179-59/+123
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Before: ``` (16.4ms) TRUNCATE TABLE `author_addresses` (20.5ms) TRUNCATE TABLE `authors` (19.4ms) TRUNCATE TABLE `posts` ``` After: ``` Truncate Tables (19.5ms) TRUNCATE TABLE `author_addresses`; TRUNCATE TABLE `authors`; TRUNCATE TABLE `posts` ```
* | | | | | | | | | Merge pull request #35637 from y-yagi/add_environment_option_to_initializersYuji Yaginuma2019-03-173-2/+29
|\ \ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | Add `-e/--environment` option to `rails initializers`
| * | | | | | | | | | Add -e/--environment option to `rails initializers`yuuji.yaginuma2019-03-163-2/+29
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This allows specifying the environment as would any other rails commands.
* | | | | | | | | | | Fix warning: instance variable @optimizer_hints not initializedRyuta Kamizono2019-03-171-0/+1
| |_|_|_|_|/ / / / / |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | https://buildkite.com/rails/rails/builds/59622#924dff9d-85c2-4946-b264-a7e6ce01432c/122-130
* | | | | | | | | | Extract `truncate` and `truncate_tables` into database statementsRyuta Kamizono2019-03-1713-84/+42
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This is to easier make `truncate_tables` to bulk statements.
* | | | | | | | | | Merge pull request #35615 from kamipo/optimizer_hintsRyuta Kamizono2019-03-1720-6/+184
|\ \ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | Support Optimizer Hints
| * | | | | | | | | | Support Optimizer HintsRyuta Kamizono2019-03-1620-6/+184
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | We as Arm Treasure Data are using Optimizer Hints with a monkey patch (https://gist.github.com/kamipo/4c8539f0ce4acf85075cf5a6b0d9712e), especially in order to use `MAX_EXECUTION_TIME` (refer #31129). Example: ```ruby class Job < ApplicationRecord default_scope { optimizer_hints("MAX_EXECUTION_TIME(50000) NO_INDEX_MERGE(jobs)") } end ``` Optimizer Hints is supported not only for MySQL but also for most databases (PostgreSQL on RDS, Oracle, SQL Server, etc), it is really helpful to turn heavy queries for large scale applications.
* | | | | | | | | | | `ActiveRecord::Result#to_hash` has been renamed to `to_a` [ci skip]Ryuta Kamizono2019-03-171-2/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | See #33912.
* | | | | | | | | | | Merge pull request #35642 from simi/raise-on-unknown-column-during-insert-allRyuta Kamizono2019-03-172-0/+14
|\ \ \ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | Raise UnknownAttributeError when unknown column is passed to insert_all and friends
| * | | | | | | | | | | Raise UnknownAttributeError when unknown column is passed to insert_all and ↵Josef Šimánek2019-03-162-0/+14
|/ / / / / / / / / / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | friends.
* | | | | | | | | | | Merge pull request #35634 from sharang-d/update-parameterize-docsRyuta Kamizono2019-03-162-6/+10
|\ \ \ \ \ \ \ \ \ \ \ | |_|/ / / / / / / / / |/| | | | | | | | | | Update docs for 'parameterize()' [ci skip]