feat(core): harden sessions settlement and credit activity
Some checks failed
lotterLaravel CI / test (push) Has been cancelled
lotterLaravel E2E / e2e-api (push) Has been cancelled

This commit is contained in:
wchino
2026-07-22 20:53:43 +08:00
parent 35f6e46958
commit 15bd997c4e
48 changed files with 1920 additions and 93 deletions

View File

@@ -267,10 +267,14 @@ return Application::configure(basePath: dirname(__DIR__))
$withSingleServerLock($schedule->command('settlement:mark-overdue-bills --days=7')
->dailyAt('02:00')
->withoutOverlapping());
/** @see docs/01-界面文档.md §2.1 `draw.countdown` */
/**
* @see docs/01-界面文档.md §2.1 `draw.countdown`
* 前端按服务器时间每秒本地计时;后端每 5 秒校准快照和期号边界,
* 避免每秒重复启动完整 Artisan 进程。
*/
if (config('lottery.realtime_hall_countdown', true)) {
$withSingleServerLock($schedule->command('lottery:hall-countdown')
->everySecond()
->everyFiveSeconds()
->withoutOverlapping(expiresAt: 5));
}
})