Keep similar-ai from tripping the global circuit on a lone URL 502, clamp Qdrant search to 100, and add Server-Timing plus slow-request logging. Studio shared props, Academy S3 exists caching, heat chunking, and Redis/scheduler hygiene stay in this rollout.
28 lines
660 B
PHP
28 lines
660 B
PHP
<?php
|
|
|
|
declare(strict_types=1);
|
|
|
|
namespace App\Jobs\Concerns;
|
|
|
|
/**
|
|
* M1 added $afterArtworkId to RecCompute* jobs. Payloads serialized before that
|
|
* property existed leave a typed property uninitialized on unserialize, which
|
|
* fatals on first access. Constructor defaults do not apply to unserialize.
|
|
*/
|
|
trait RestoresAfterArtworkIdCursor
|
|
{
|
|
protected function restoreAfterArtworkIdCursor(): void
|
|
{
|
|
if (! isset($this->afterArtworkId)) {
|
|
$this->afterArtworkId = null;
|
|
}
|
|
}
|
|
|
|
protected function afterArtworkId(): ?int
|
|
{
|
|
$this->restoreAfterArtworkIdCursor();
|
|
|
|
return $this->afterArtworkId;
|
|
}
|
|
}
|