作者 赵彬吉

update

@@ -58,6 +58,7 @@ class SyncProject extends Command @@ -58,6 +58,7 @@ class SyncProject extends Command
58 */ 58 */
59 public function handle() 59 public function handle()
60 { 60 {
  61 + while (true){
61 $list = NoticeLog::where('type', NoticeLog::TYPE_PROJECT)->where('status', NoticeLog::STATUS_PENDING)->get(); 62 $list = NoticeLog::where('type', NoticeLog::TYPE_PROJECT)->where('status', NoticeLog::STATUS_PENDING)->get();
62 foreach ($list as $item){ 63 foreach ($list as $item){
63 try { 64 try {
@@ -89,6 +90,9 @@ class SyncProject extends Command @@ -89,6 +90,9 @@ class SyncProject extends Command
89 $this->retry($item); 90 $this->retry($item);
90 } 91 }
91 } 92 }
  93 + sleep(2);
  94 + }
  95 +
92 } 96 }
93 97
94 /** 98 /**
@@ -29,7 +29,6 @@ class Kernel extends ConsoleKernel @@ -29,7 +29,6 @@ class Kernel extends ConsoleKernel
29 $schedule->command('web_traffic 2')->cron('*/18 * * * *'); // 引流 4-8个月的项目,18分钟一次 29 $schedule->command('web_traffic 2')->cron('*/18 * * * *'); // 引流 4-8个月的项目,18分钟一次
30 $schedule->command('web_traffic 3')->cron('*/12 * * * *'); // 引流 大于9个月的项目,12分钟一次 30 $schedule->command('web_traffic 3')->cron('*/12 * * * *'); // 引流 大于9个月的项目,12分钟一次
31 $schedule->command('sync_channel')->dailyAt('06:00')->withoutOverlapping(1); // 渠道信息,每周执行一次 31 $schedule->command('sync_channel')->dailyAt('06:00')->withoutOverlapping(1); // 渠道信息,每周执行一次
32 - $schedule->command('sync_project')->everyMinute()->withoutOverlapping(1); //同步项目  
33 $schedule->command('month_count')->monthlyOn(1,'01:00')->withoutOverlapping(1);//没月月初1号执行月统计记录 32 $schedule->command('month_count')->monthlyOn(1,'01:00')->withoutOverlapping(1);//没月月初1号执行月统计记录
34 $schedule->command('forward_count')->monthlyOn(1,'01:00')->withoutOverlapping(1);//没月月初1号执行月统计转发询盘记录 33 $schedule->command('forward_count')->monthlyOn(1,'01:00')->withoutOverlapping(1);//没月月初1号执行月统计转发询盘记录
35 $schedule->command('inquiry_delay')->everyMinute()->withoutOverlapping(1);//TODO::上线放开,转发询盘,每分钟执行一次 34 $schedule->command('inquiry_delay')->everyMinute()->withoutOverlapping(1);//TODO::上线放开,转发询盘,每分钟执行一次