src/ListensForStorageOpportunities.php
protected static function storeEntriesAfterWorkerLoop($app)
    {
        $app['events']->listen(JobProcessing::class, function () {
            static::startRecording();

            static::$processingJobs[] = true;
        });

        $app['events']->listen(JobProcessed::class, function ($event) use ($app) {
            static::storeIfDoneProcessingJob($event, $app);
        });

        $app['events']->listen(JobFailed::class, function ($event) use ($app) {
            static::storeIfDoneProcessingJob($event, $app);
        });

        $app['events']->listen(JobExceptionOccurred::class, function () {
            array_pop(static::$processingJobs);
        });
    }
protected static function storeEntriesAfterWorkerLoop($app)
    {
        $app['events']->listen(JobProcessing::class, function () {
            static::startRecording();

            static::$processingJobs[] = true;
        });

        $app['events']->listen(JobProcessed::class, function ($event) use ($app) {
            static::storeIfDoneProcessingJob($event, $app);
        });

        $app['events']->listen(JobFailed::class, function ($event) use ($app) {
            static::storeIfDoneProcessingJob($event, $app);
        });

        $app['events']->listen(JobExceptionOccurred::class, function () {
            array_pop(static::$processingJobs);
        });
    }
protected static function storeEntriesAfterWorkerLoop ( $ app ) { $ app [ 'events' ] -> listen ( JobProcessing :: class , function ( ) { static :: startRecording ( ) ; static :: $ processingJobs [ ] = true ; } ) ; $ app [ 'events' ] -> listen ( JobProcessed :: class , function ( $ event ) use ( $ app ) { static :: storeIfDoneProcessingJob ( $ event , $ app ) ; } ) ; $ app [ 'events' ] -> listen ( JobFailed :: class , function ( $ event ) use ( $ app ) { static :: storeIfDoneProcessingJob ( $ event , $ app ) ; } ) ; $ app [ 'events' ] -> listen ( JobExceptionOccurred :: class , function ( ) { array_pop ( static :: $ processingJobs ) ; } ) ; }
Store entries after the queue worker loops.

@param  \Illuminate\Foundation\Application  $app
@return void
Store entries after the queue worker loops .