| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
| |
Closes #7110 there's more work to do on rack-cache issue 69
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This allows us to do:
In your configuration:
Rails.queue[:image_queue] = SomeQueue.new
Rails.queue[:mail_queue] = SomeQueue.new
In your app code:
Rails.queue[:mail_queue].push MailJob.new
Both jobs pushed to the same default queue
Rails.queue.push DefaultJob.new
Rails.queue[:default].push DefaultJob.new
|
| |
|
|\
| |
| | |
Add indexes to create_join_table method
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
For instance, running
rails g migration CreateMediaJoinTable artists musics:uniq
will create a migration with
create_join_table :artists, :musics do |t|
# t.index [:artist_id, :music_id]
t.index [:music_id, :artist_id], unique: true
end
|
|/ |
|
|\
| |
| | |
Add references statements to migration generator
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
AddXXXToYYY/RemoveXXXFromYYY migrations are produced with references
statements, for instance
rails g migration AddReferencesToProducts user:references
supplier:references{polymorphic}
will generate the migration with:
add_reference :products, :user, index: true
add_reference :products, :supplier, polymorphic: true, index: true
|
|/
|
|
|
| |
Changes introduced in 7404cda9f61e41d52ce244d60abbf598684a96c4.
Fix railties build.
|
| |
|
| |
|
|
|
|
|
| |
Mocha is already required by AS::TestCase, so remove the duplicate
requires.
|
| |
|
|
|
|
|
| |
This requires all jobs to be instances of named classes, without block
implementations of methods.
|
|
|
|
|
|
|
|
| |
Jobs pushed to the queue should not contain a reference to it. As the queue
itself cannot be marshalled, and as a consequence of checking the
marshallability of all jobs in the test environment, we can now guarantee this
to be the case in the test environment when using the default TestQueue
implementation.
|
|
|
|
|
|
|
|
|
|
| |
By marshalling and unmarshalling jobs when adding them to the test queue, we
can ensure that jobs created during test runs are valid candidates for
marshalling, and, thus, that they can be used with queueing backends other than
the default simple in-process implementation.
This will also be used in a subsequent commit to ensure that jobs pushed to the
queue do not contain a reference to the queue itself.
|
|
|
|
|
|
|
| |
Using an anonymous class prevented marshalling: we're not doing that yet, but
the next commit will introduce this. This also provided an opportunity to
improve the expressivity of the tests and to make the assertion failure
messages clearer.
|
| |
|
|
|
|
| |
Introduced in pull request #6910, merged in 2ee3fa1a48513a2c42833e2e1f60fe03769bc295
|
|\
| |
| | |
Persist glob when replacing a path
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
When Rails::Paths::Root's []= is used to replace a path it should persist the previous path's glob. Without passing the glob along we get gnarly bugs when trying to wire up things like engines.
module FooEngine
class Engine < ::Rails::Engine
isolate_namespace FooEngine
config.paths['config/initializers'] = "lib/foo_engine/initializers"
end
end
## Example of behaviour before this commit.
#
# Before the initializer override:
>> FooEngine::Engine.config.paths["config/initializers"].glob
=> "**/*.rb"
# After the initializer override:
>> FooEngine::Engine.config.paths["config/initializers"].glob
=> nil
## Example of behaviour after this commit.
#
# Before the initializer override:
>> FooEngine::Engine.config.paths["config/initializers"].glob
=> "**/*.rb"
# After the initializer override:
>> FooEngine::Engine.config.paths["config/initializers"].glob
=> "**/*.rb"
|
| |
| |
| |
| | |
Related with 5e7d6bb
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
This reverts commit 6acebb38bc0637bc05c19d87f8767f16ce79189b.
Usage of this feature did not reveal any improvement in existing apps.
Conflicts:
actionpack/lib/action_dispatch/routing/mapper.rb
guides/source/routing.textile
railties/lib/rails/engine.rb
railties/lib/rails/paths.rb
railties/test/paths_test.rb
|
|/
|
|
|
|
|
|
| |
Since plugins were removed, we can clean up a few methods in engines.
We also use this opportunity to move `load_console`, `load_tasks` and
`load_runner` to Rails::Engine. This means that, if someone wants to
improve script/rails for engines to support console or runner commands,
part of the work is already done.
|
| |
|
| |
|
|\
| |
| | |
Fix wrong testcase for db:test:prepare, and wrong environment in AR rake task.
|
| | |
|
|\ \
| |/
|/|
| |
| |
| |
| |
| |
| | |
Add polymorphic option to model generator
For instance,
$ rails g model Product supplier:references{polymorphic}
generate model with `belongs_to :supplier, polymorphic: true` association and appropriate migration.
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
For instance,
$ rails g model Product supplier:references{polymorphic}
generate model with `belongs_to :supplier, polymorphic: true` association and appropriate migration.
Also fix model_generator_test.rb#L196 and #L201
|
| |
| |
| |
| | |
consistency.
|
|/
|
|
| |
consistency.
|
|
|
|
|
|
|
|
| |
app/controllers/application_controller.rb
app/views/layouts/application.html.erb
config/application.rb
config/routes.rb
test/performance/browsing_test.rb
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
|\
| |
| | |
Fix: 'rake rails:templates:copy' doesn't work
|
| | |
|
| | |
|
|\ \
| |/
|/| |
Notify A User they Have Pending Migrations
|
| |
| |
| | |
App should raise error on page_load
|
| |
| |
| |
| | |
Fix for a test failing after: 00ff0a6776
|
|\ \
| | |
| | | |
Plugin gen fix
|