Class: AuthorizedProjectsWorker

Inherits:
Object
  • Object
show all
Includes:
ApplicationWorker, WaitableWorker
Defined in:
app/workers/authorized_projects_worker.rb

Constant Summary

Constants included from ApplicationWorker

ApplicationWorker::LOGGING_EXTRA_KEY, ApplicationWorker::SAFE_PUSH_BULK_LIMIT

Constants included from WorkerAttributes

WorkerAttributes::DEFAULT_DATA_CONSISTENCY, WorkerAttributes::NAMESPACE_WEIGHTS, WorkerAttributes::VALID_DATA_CONSISTENCIES, WorkerAttributes::VALID_RESOURCE_BOUNDARIES, WorkerAttributes::VALID_URGENCIES

Class Method Summary collapse

Instance Method Summary collapse

Methods included from Gitlab::SidekiqVersioning::Worker

#job_version

Methods included from WorkerContext

#with_context

Class Method Details

.bulk_perform_and_wait(args_list, timeout: 10) ⇒ Object


21
22
# File 'app/workers/authorized_projects_worker.rb', line 21

def self.bulk_perform_and_wait(args_list, timeout: 10)
end

.bulk_perform_inline(args_list) ⇒ Object


24
25
# File 'app/workers/authorized_projects_worker.rb', line 24

def self.bulk_perform_inline(args_list)
end

Instance Method Details

#perform(user_id) ⇒ Object


28
29
30
31
32
# File 'app/workers/authorized_projects_worker.rb', line 28

def perform(user_id)
  user = User.find_by_id(user_id)

  user&.refresh_authorized_projects(source: self.class.name)
end