Class: Servus::Extensions::Async::Job Private
- Inherits:
-
ActiveJob::Base
- Object
- ActiveJob::Base
- Servus::Extensions::Async::Job
- Defined in:
- lib/servus/extensions/async/job.rb
Overview
This class is part of a private API. You should avoid using this class if possible, as it may be removed or be changed in the future.
ActiveJob for executing Servus services asynchronously.
This job is used by Call#call_async to execute services in the background. It receives the service class name and arguments, instantiates the service, and executes it via Base.call.
Instance Method Summary collapse
-
#perform(name:, args:) ⇒ Servus::Support::Response
private
Executes the service with the provided arguments.
Instance Method Details
#perform(name:, args:) ⇒ Servus::Support::Response
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
Executes the service with the provided arguments.
Dynamically loads the service class by name and calls it with the provided keyword arguments.
32 33 34 |
# File 'lib/servus/extensions/async/job.rb', line 32 def perform(name:, args:) constantize!(name).call(**args) end |