CheckForUpdatesJob
class CheckForUpdatesJob extends AbstractQueuedJob implements QueuedJob (View source)
Refresh report job. Runs as a queued job.
Properties
static private bool | $reschedule | Whether or not to reschedule a new job when one completes |
|
static private string | $reschedule_delay | The PHP time difference to reschedule a job for after one completes |
Methods
Extensions can have a construct but don't have too.
Define the title
Define the type.
Specifies what user ID should be when running the job valid values: null - (default) - run the job as current user 0 - run the job without a user greater than zero - run the job as a specific user
Processes the task as a job
Method for determining whether the job is finished - you may override it if there's more to it than just this
No description
No description
Gets custom config settings to use when running the job.
Sets custom config settings to use when the job is run.
Convenience methods for setting and getting job data
Details
__construct($params = array())
Extensions can have a construct but don't have too.
Without a construct, it's impossible to create a job in the CMS
string
getTitle()
Define the title
string
getSignature()
Return a signature for this queued job
getJobType()
Define the type.
int|null
getRunAsMemberID()
Specifies what user ID should be when running the job valid values: null - (default) - run the job as current user 0 - run the job without a user greater than zero - run the job as a specific user
This is useful in situations like:
- a job needs to always run without a user (like a static cache job)
- a job needs to run as a specific user (for example data migration job)
Note that this value can be overridden in the see QueuedJobService::queueJob()
setup()
Performs setup tasks the first time this job is run.
This is only executed once for every job. If you want to run something on every job restart, use the {@link prepareForRestart} method.
prepareForRestart()
Run when an already setup job is being restarted.
process()
Processes the task as a job
jobFinished()
Method for determining whether the job is finished - you may override it if there's more to it than just this
afterComplete()
getJobData()
setJobData(int $totalSteps, int $currentStep, bool $isComplete, stdClass $jobData, array $messages)
array|null
getCustomConfig()
Gets custom config settings to use when running the job.
setCustomConfig(array $config)
Sets custom config settings to use when the job is run.
addMessage(string $message, string $severity = 'INFO')
__set(mixed $name, mixed $value)
Convenience methods for setting and getting job data
mixed
__get(mixed $name)
Retrieve some job data