forked from fa/breadcrumb-the-shire
Repo Interface für tests
This commit is contained in:
30
lib/Repository/Scheduler/ScheduledJobRepositoryInterface.php
Normal file
30
lib/Repository/Scheduler/ScheduledJobRepositoryInterface.php
Normal file
@@ -0,0 +1,30 @@
|
||||
<?php
|
||||
|
||||
namespace MintyPHP\Repository\Scheduler;
|
||||
|
||||
interface ScheduledJobRepositoryInterface
|
||||
{
|
||||
public function create(array $data): int|false;
|
||||
|
||||
public function find(int $id): ?array;
|
||||
|
||||
public function findByKey(string $jobKey): ?array;
|
||||
|
||||
public function listPaged(array $filters): array;
|
||||
|
||||
public function listDueJobs(string $nowUtc, int $limit = 20): array;
|
||||
|
||||
public function updateJobMeta(int $id, array $data): bool;
|
||||
|
||||
public function markRunning(int $id, string $startedAtUtc): bool;
|
||||
|
||||
public function finishRun(
|
||||
int $id,
|
||||
string $status,
|
||||
string $startedAtUtc,
|
||||
string $finishedAtUtc,
|
||||
?string $nextRunAtUtc,
|
||||
?string $errorCode,
|
||||
?string $errorMessage
|
||||
): bool;
|
||||
}
|
||||
Reference in New Issue
Block a user