forgeplus/app/jobs/cache_async_set_job.rb

14 lines
413 B
Ruby

class CacheAsyncSetJob < ApplicationJob
queue_as :cache
def perform(type, params={}, id=nil)
case type
when "platform_statistic_service"
Cache::V2::PlatformStatisticService.new(params).call
when "project_common_service"
Cache::V2::ProjectCommonService.new(id, params).call
when "user_statistic_service"
Cache::V2::UserStatisticService.new(id, params).call
end
end
end