File: //usr/local/rvm/gems/ruby-3.0.2/doc/activejob-6.1.4.1/ri/ActiveJob/Base/cdesc-Base.ri
U:RDoc::NormalClass[iI" Base:ETI"ActiveJob::Base;TI"Object;To:RDoc::Markup::Document:@parts[o;;[!S:RDoc::Markup::Heading:
leveli: textI"Active Job;To:RDoc::Markup::BlankLine o:RDoc::Markup::Paragraph;[I"IActive Job objects can be configured to work with different backend ;TI";queuing frameworks. To specify a queue adapter to use:;T@o:RDoc::Markup::Verbatim;[I"-ActiveJob::Base.queue_adapter = :inline
;T:@format0o;
;[I"@A list of supported adapters can be found in QueueAdapters.;T@o;
;[I"IActive Job objects can be defined by creating a class that inherits ;TI"Bfrom the ActiveJob::Base class. The only necessary method to ;TI"'implement is the "perform" method.;T@o;
;[I"$To define an Active Job object:;T@o;;[
I"-class ProcessPhotoJob < ActiveJob::Base
;TI" def perform(photo)
;TI"# photo.watermark!('Rails')
;TI"# photo.rotate!(90.degrees)
;TI"( photo.resize_to_fit!(300, 300)
;TI" photo.upload!
;TI" end
;TI" end
;T;0o;
;[I"IRecords that are passed in are serialized/deserialized using Global ;TI"4ID. More information can be found in Arguments.;T@o;
;[I"LTo enqueue a job to be performed as soon as the queuing system is free:;T@o;;[I"*ProcessPhotoJob.perform_later(photo)
;T;0o;
;[I"BTo enqueue a job to be processed at some point in the future:;T@o;;[I"NProcessPhotoJob.set(wait_until: Date.tomorrow.noon).perform_later(photo)
;T;0o;
;[I"GMore information can be found in ActiveJob::Core::ClassMethods#set;T@o;
;[I"JA job can also be processed immediately without sending to the queue:;T@o;;[I"(ProcessPhotoJob.perform_now(photo)
;T;0S; ;
i;I"Exceptions;T@o:RDoc::Markup::List:
@type:BULLET:@items[o:RDoc::Markup::ListItem:@label0;[o;
;[I"CDeserializationError - Error class for deserialization errors.;To;;0;[o;
;[I"?SerializationError - Error class for serialization errors.;T:
@fileI"lib/active_job/base.rb;T:0@omit_headings_from_table_of_contents_below0;0;0[ [ [[I" Core;To;;[ ;@T;0I"lib/active_job/base.rb;T[I"QueueAdapter;To;;[ ;@T;0@\[I"QueueName;To;;[ ;@T;0@\[I"QueuePriority;To;;[ ;@T;0@\[I"Enqueuing;To;;[ ;@T;0@\[I"Execution;To;;[ ;@T;0@\[I"Callbacks;To;;[ ;@T;0@\[I"Exceptions;To;;[ ;@T;0@\[I"Logging;To;;[ ;@T;0@\[I"Instrumentation;To;;[ ;@T;0@\[I"Timezones;To;;[ ;@T;0@\[I"Translation;To;;[ ;@T;0@\[[I"
class;T[[:public[ [:protected[ [:private[ [I"
instance;T[[;[ [;[ [;[ [ [U:RDoc::Context::Section[i 0o;;[ ;0;0[@TI"ActiveJob;TcRDoc::NormalModule