Bånder

QueueMonitor extends BaseModel
in package

Table of Contents

Properties

$timestamps  : mixed
$casts  : mixed
$dateFormat  : mixed
$guarded  : mixed
$table  : mixed

Methods

canBeRetried()  : bool
formatForException()  : string
getBasename()  : string|null
Get the base class name of the job.
getData()  : array<string, mixed>
Get any optional data that has been added to the monitor model within the job.
getElapsedInterval()  : CarbonInterval
getElapsedSeconds()  : float
Get the currently elapsed seconds.
getException()  : Throwable|null
Recreate the exception.
getRemainingInterval()  : CarbonInterval
getRemainingSeconds()  : float
Get the estimated remaining seconds. This requires a job progress to be set.
hasFailed()  : bool
Check if the job has failed.
hasSucceeded()  : bool
check if the job has succeeded.
isFinished()  : bool
check if the job is finished.
newEloquentBuilder()  : mixed
retry()  : void
update()  : mixed
scopeFailed()  : void
scopeLastHour()  : void
scopeOrdered()  : void
scopeSucceeded()  : void
scopeToday()  : void
scopeWhereJob()  : void

Properties

$casts

protected mixed $casts = ['failed' => 'bool', 'retried' => 'bool', 'queued_at' => 'datetime', 'started_at' => 'datetime', 'finished_at' => 'datetime', 'exception' => 'json']

$dateFormat

protected mixed $dateFormat = 'Y-m-d H:i:sO'

Methods

canBeRetried()

public canBeRetried() : bool
Return values
bool

formatForException()

public formatForException() : string
Return values
string

getBasename()

Get the base class name of the job.

public getBasename() : string|null
Return values
string|null

getData()

Get any optional data that has been added to the monitor model within the job.

public getData() : array<string, mixed>
Return values
array<string, mixed>

getElapsedInterval()

public getElapsedInterval([Carbon|null $end = null ]) : CarbonInterval
Parameters
$end : Carbon|null = null
Return values
CarbonInterval

getElapsedSeconds()

Get the currently elapsed seconds.

public getElapsedSeconds([Carbon|null $end = null ]) : float
Parameters
$end : Carbon|null = null
Return values
float

getException()

Recreate the exception.

public getException([bool $rescue = true ]) : Throwable|null
Parameters
$rescue : bool = true

Wrap the exception recreation to catch exceptions

Return values
Throwable|null

getRemainingInterval()

public getRemainingInterval([Carbon|null $now = null ]) : CarbonInterval
Parameters
$now : Carbon|null = null
Return values
CarbonInterval

getRemainingSeconds()

Get the estimated remaining seconds. This requires a job progress to be set.

public getRemainingSeconds([Carbon|null $now = null ]) : float
Parameters
$now : Carbon|null = null
Return values
float

hasFailed()

Check if the job has failed.

public hasFailed() : bool
Return values
bool

hasSucceeded()

check if the job has succeeded.

public hasSucceeded() : bool
Return values
bool

isFinished()

check if the job is finished.

public isFinished() : bool
Return values
bool

newEloquentBuilder()

public newEloquentBuilder(mixed $query) : mixed
Parameters
$query : mixed

update()

public update([array<string|int, mixed> $attributes = [] ][, array<string|int, mixed> $options = [] ]) : mixed
Parameters
$attributes : array<string|int, mixed> = []
$options : array<string|int, mixed> = []

scopeFailed()

protected scopeFailed(Builder $query) : void
Parameters
$query : Builder

scopeLastHour()

protected scopeLastHour(Builder $query) : void
Parameters
$query : Builder

scopeOrdered()

protected scopeOrdered(Builder $query) : void
Parameters
$query : Builder

scopeSucceeded()

protected scopeSucceeded(Builder $query) : void
Parameters
$query : Builder

scopeToday()

protected scopeToday(Builder $query) : void
Parameters
$query : Builder

scopeWhereJob()

protected scopeWhereJob(Builder $query, mixed $jobId) : void
Parameters
$query : Builder
$jobId : mixed

        
On this page

Search results