19 lines
509 B
Ruby
19 lines
509 B
Ruby
# typed: strict
|
|
class Domain::StaticFileJob < Scraper::JobBase
|
|
include Domain::StaticFileJobHelper
|
|
queue_as :static_file
|
|
discard_on ActiveJob::DeserializationError
|
|
|
|
sig { override.returns(Symbol) }
|
|
def self.http_factory_method
|
|
:get_generic_http_client
|
|
end
|
|
|
|
sig { override.params(args: T::Hash[Symbol, T.untyped]).returns(T.untyped) }
|
|
def perform(args)
|
|
file = post_file_from_args!
|
|
logger.push_tags(make_arg_tag(file), make_arg_tag(file.post))
|
|
download_post_file(file)
|
|
end
|
|
end
|