method
perform_now
v7.1.3.4 -
Show latest stable
- Class:
ActiveJob::Execution
perform_now()public
Performs the job immediately. The job is not sent to the queuing adapter but directly executed by blocking the execution of others until it’s finished. perform_now returns the value of your job’s perform method.
class MyJob < ActiveJob::Base def perform "Hello World!" end end puts MyJob.new(*args).perform_now # => "Hello World!"