Kernel.php 3.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384
  1. <?php
  2. namespace App\Console;
  3. use App\Console\Commands\CheckIosAppStore;
  4. use App\Console\Commands\CheckStockModeNegative;
  5. use App\Console\Commands\DbQueue;
  6. use App\Console\Commands\OnlineReport;
  7. use App\Console\Commands\DecStock;
  8. use App\Console\Commands\ExemptReview;
  9. use App\Console\Commands\Extension;
  10. use App\Console\Commands\PayOrder;
  11. use App\Console\Commands\RecordPlatformData;
  12. use App\Console\Commands\RecordServerGameCount;
  13. use App\Console\Commands\RecordServerGameCountYesterday;
  14. use App\Console\Commands\RecordThreeGameYesterday;
  15. use App\Console\Commands\RecordPaidRewardDailyStatistics;
  16. use App\Console\Commands\RecordUserScoreChangeStatistics;
  17. use App\Console\Commands\SuperballUpdatePoolAndStats;
  18. use Illuminate\Console\Scheduling\Schedule;
  19. use Illuminate\Foundation\Console\Kernel as ConsoleKernel;
  20. class Kernel extends ConsoleKernel
  21. {
  22. /**
  23. * The Artisan commands provided by your application.
  24. *
  25. * @var array
  26. */
  27. protected $commands = [
  28. ExemptReview::class,
  29. PayOrder::class,
  30. Extension::class,
  31. CheckStockModeNegative::class,
  32. RecordPlatformData::class,
  33. RecordServerGameCount::class,
  34. RecordServerGameCountYesterday::class,
  35. RecordPaidRewardDailyStatistics::class,
  36. RecordUserScoreChangeStatistics::class,
  37. DecStock::class,
  38. CheckIosAppStore::class,
  39. OnlineReport::class,
  40. DbQueue::class,
  41. RecordThreeGameYesterday::class,
  42. SuperballUpdatePoolAndStats::class,
  43. ];
  44. /**
  45. * Define the application's command schedule.
  46. *
  47. * @param \Illuminate\Console\Scheduling\Schedule $schedule
  48. * @return void
  49. */
  50. protected function schedule(Schedule $schedule)
  51. {
  52. // $schedule->command('db_queue')->everyMinute()->description('批量处理redis队列任务');
  53. $schedule->command('exempt_review')->everyMinute()->description('免审提现');
  54. $schedule->command('record_server_game_count')->cron('*/15 * * * * ')->description('按天统计游戏人数');
  55. $schedule->command('stock_mode:check_negative')->cron('*/5 * * * *')->description('检测库存模式房间库存是否为负并通过 Telegram 报警');
  56. $schedule->command('online_max')->cron('*/8 * * * * ')->description('最高在线人数统计');
  57. $schedule->command('record_server_game_count_yesterday')->cron('05 0 * * * ')->description('按天统计游戏人数--今日执行昨日');
  58. $schedule->command('RecordPlatformData')->cron('10 0 * * * ')->description('数据统计');
  59. $schedule->command('RecordPaidRewardDailyStatistics')->cron('15 0 * * * ')->description('付费用户奖励日统计');
  60. $schedule->command('RecordUserScoreChangeStatistics')->cron('03 0 * * * ')->description('用户金额变化明细按天按用户汇总');
  61. $schedule->command('superball:update-pool-stats')->everyMinute()->description('Superball 每分钟刷新奖池及展示统计');
  62. $schedule->command('online_report')->everyMinute()->description('每分钟统计曲线');
  63. $schedule->command('ios:check-app-store')->everyFiveMinutes()->description('每5分钟检测 iOS App Store 包是否下架');
  64. // $schedule->command('record_three_game_yesterday')->cron('05 0 * * * ')->description('按天统计游戏人数--今日执行昨日');
  65. }
  66. /**
  67. * Register the commands for the application.
  68. *
  69. * @return void
  70. */
  71. protected function commands()
  72. {
  73. $this->load(__DIR__.'/Commands');
  74. // require base_path('routes/console.php');
  75. }
  76. }