Modellwahl über Kanalfähigkeiten mit erklärten Einschränkungen, Abgleich alter Werte, Ausführungsvarianten je Modul, getrennte Vertrags-/Buchungsinformation, Warten auf die Portalbestätigung mit Eskalation und Wiederaufnahme (Fälle C und D getestet). Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
70 lines
3.0 KiB
PHP
70 lines
3.0 KiB
PHP
<?php
|
||
|
||
use App\Actions\AnonymizeGuests;
|
||
use App\Actions\MonitorChannels;
|
||
use App\Actions\RemindChannelTasks;
|
||
use App\Actions\RequestReviews;
|
||
use App\Actions\SendBookingReminders;
|
||
use App\Actions\SendDigests;
|
||
use App\Models\Tenant;
|
||
use App\Tenancy\TenantRunner;
|
||
use Illuminate\Support\Facades\Schedule;
|
||
|
||
/**
|
||
* Everything that acts on a landlord's data runs once per landlord (TenantRunner), so queries see the right
|
||
* rows and mail goes out with the right sender. Only the database backup stays global: one database, one dump.
|
||
*/
|
||
Schedule::command('bookings:expire-holds')->everyFiveMinutes()->withoutOverlapping();
|
||
|
||
Schedule::command('bookings:auto-offers')->everyFiveMinutes()->withoutOverlapping();
|
||
// Binding bookings waiting for a portal confirmation: deadline, escalation, resume (V2.1).
|
||
Schedule::command('bookings:advance-waiting')->everyFiveMinutes()->withoutOverlapping();
|
||
|
||
// v0.11: reminders of data requests (never extends a hold or a deadline of the case).
|
||
Schedule::command('cases:data-requests')->everyFiveMinutes()->withoutOverlapping();
|
||
|
||
// v0.11: evaluate assigned messages (limited per run; outside the minute-by-minute portal fast path).
|
||
Schedule::command('messages:extract')->everyFiveMinutes()->withoutOverlapping(10);
|
||
|
||
Schedule::command('bookings:resend-confirmations')->everyFifteenMinutes()->withoutOverlapping();
|
||
|
||
Schedule::command('channels:sync')->everyFiveMinutes()->withoutOverlapping(10);
|
||
|
||
Schedule::command('channels:fetch-mail')->everyMinute()->withoutOverlapping(5);
|
||
|
||
Schedule::call(fn (TenantRunner $runner, MonitorChannels $monitorChannels) => $runner->each(fn () => $monitorChannels->handle()))
|
||
->name('channels:monitor')
|
||
->everyFifteenMinutes()
|
||
->withoutOverlapping();
|
||
|
||
Schedule::call(fn (TenantRunner $runner, RemindChannelTasks $remindChannelTasks) => $runner->each(fn () => $remindChannelTasks->handle()))
|
||
->name('channels:remind-tasks')
|
||
->everyFifteenMinutes()
|
||
->withoutOverlapping();
|
||
|
||
Schedule::call(fn (TenantRunner $runner, SendDigests $sendDigests) => $runner->each(fn (Tenant $tenant) => $sendDigests->handle($tenant)))
|
||
->name('digests:send')
|
||
->everyFifteenMinutes()
|
||
->withoutOverlapping();
|
||
|
||
Schedule::call(fn (TenantRunner $runner, SendBookingReminders $sendBookingReminders) => $runner->each(fn () => $sendBookingReminders->handle()))
|
||
->name('bookings:reminders')
|
||
->dailyAt('09:00')
|
||
->withoutOverlapping();
|
||
|
||
Schedule::call(fn (TenantRunner $runner, RequestReviews $requestReviews) => $runner->each(fn () => $requestReviews->handle()))
|
||
->name('reviews:request')
|
||
->dailyAt('10:00')
|
||
->withoutOverlapping();
|
||
|
||
Schedule::call(fn (TenantRunner $runner, AnonymizeGuests $anonymizeGuests) => $runner->each(fn () => $anonymizeGuests->handle()))
|
||
->name('guests:anonymize')
|
||
->dailyAt('03:00')
|
||
->withoutOverlapping();
|
||
|
||
// One database, one dump – across all landlords (see MANDANTEN-PLAN §5).
|
||
Schedule::command('backup:database')
|
||
->name('backup:database')
|
||
->dailyAt('02:30')
|
||
->withoutOverlapping();
|