Command/CrawlCommand.php
/**
     * Logs a message that will tell the job is failed.
     *
     * @param \Simgroep\ConcurrentSpiderBundle\CrawlJob $crawlJob
     * @param string                                    $errorMessage
     */
Logs a message that will tell the job is failed.
Logs a message that will tell the job is failed .
public function markAsFailed(CrawlJob $crawlJob, $errorMessage)
    {
        $meta = $crawlJob->getMetadata();
        $this->logMessage(
            'emergency',
            sprintf(
                "Failed (%s) %s",
                $errorMessage,
                $crawlJob->getUrl()
            ),
            $crawlJob->getUrl(),
            $meta['core'],
            $crawlJob->getQueueName()
        );
    }
public function markAsFailed ( CrawlJob $ crawlJob , $ errorMessage ) { $ meta = $ crawlJob -> getMetadata ( ) ; $ this -> logMessage ( 'emergency' , sprintf ( " Failed (%s) %s " , $ errorMessage , $ crawlJob -> getUrl ( ) ) , $ crawlJob -> getUrl ( ) , $ meta [ 'core' ] , $ crawlJob -> getQueueName ( ) ) ; }
Logs a message that will tell the job is failed.
Logs a message that will tell the job is failed .