mirror of
https://github.com/rails/rails.git
synced 2022-11-09 12:12:34 -05:00
[ci skip] Update active_job_basics.md
ApplicationJob should be inherits ActiveJob::Base
This commit is contained in:
parent
2201197961
commit
97412e08a6
1 changed files with 1 additions and 1 deletions
|
@ -289,7 +289,7 @@ style if the code inside your block is so short that it fits in a single line.
|
||||||
For example, you could send metrics for every job enqueued:
|
For example, you could send metrics for every job enqueued:
|
||||||
|
|
||||||
```ruby
|
```ruby
|
||||||
class ApplicationJob
|
class ApplicationJob < ActiveJob::Base
|
||||||
before_enqueue { |job| $statsd.increment "#{job.class.name.underscore}.enqueue" }
|
before_enqueue { |job| $statsd.increment "#{job.class.name.underscore}.enqueue" }
|
||||||
end
|
end
|
||||||
```
|
```
|
||||||
|
|
Loading…
Reference in a new issue