push

@param mixed  $job
@param int    $delay
@param string $queue
@param array  $options

@return  int|string
14887
public function push($job, $delay = 0, $queue = null, array $options = [])
    {
        $message = $this->getMessageByJob($job);
        $message->setDelay($delay);
        $message->setQueueName($queue);
        $message->setOptions($options);

        return $this->driver->push($message);
    }
565877
public function push($job, array $data = null, $queue = null)
    {
        if (false !== ($delay = \Resque::getConfig('default.jobs.delay', false))) {
            return $this->later($delay, $job, $data, $queue);
        }

        return Job::create($this->getQueue($queue), $job, $data);
    }
1137098
public function push($queue, $item)
    {
        // Add the queue to the list of queues
        $this->getClient()->sadd($this->getKey(self::QUEUES_KEY), $queue);

        // Add the job to the specified queue
        $this->getClient()->rpush($this->getKey(self::QUEUE_KEY . $queue), json_encode($item));
    }
147965
public function later($delay, $job, $data = '', $queue = null)
    {
        return Timer::after($this->secondsUntil($delay) * 1000, function () use ($job, $data, $queue) {
            return $this->push($job, $data, $queue);
        });
    }
873577
public function pushRaw($payload, $queue = null, array $options = array())
	{
		return $this->pheanstalk->useTube($this->getQueue($queue))->put($payload);
	}
1256236
public function process(JobInterface $job, $maxTries = 0, $delay = 0)
    {
        if ($maxTries > 0 && $job->attempts() > $maxTries) {
            $this->fail($job);
            return Result::failed($job);
        }

        try {
            $job->fire();
            return Result::success($job);
        } catch (Exception $e) {
            // If we catch an exception, we will attempt to release the job back onto
            // the queue so it is not lost. This will let is be retried at a later
            // time by another listener (or the same one). We will do that here.
            if (!$job->isDeleted()) {
                $job->release($delay);
            }
            throw $e;
        } // @codeCoverageIgnoreStart
        catch (Throwable $e) {
            if (!$job->isDeleted()) {
                $job->release($delay);
            }
            throw $e;
        }
        // @codeCoverageIgnoreEnd
    }
1213954
public function push($workerClass, array $args = [], $retry = false, $priority = 0, $at = null, $jobId = null) :? Job
    {
        $job = new Job($this, $jobId);

        $status = $job->schedule($workerClass, $args, $retry, $priority, $at);

        if ($status) {
            return $job;
        }

        return false;
    }
947729
public function push($job, $data = '', $queue = null)
    {
        $id = $this->storeJob($job, $data, $queue);

        return 0;
    }
1268008
public function later($delay, $job, $data = '', $queue = null)
    {
        return $this->push($job, $data, $queue);
    }
1007438
protected function pushToChannel(Job $job)
    {
        $channelName = $job->channelName() ? $job->channelName() : static::$defaultChannel;

        $state = $this->channelOrFail($channelName)->push($job, $channelName);

        $job->setState($state);

        return $job;
    }
1290549
public function pushed($connection, $queue, JobPayload $payload)
    {
        $this->connection()->pipeline(function ($pipe) use ($connection, $queue, $payload) {
            $this->storeJobReference($pipe, 'recent_jobs', $payload);

            $time = str_replace(',', '.', microtime(true));

            $pipe->hmset(
                $payload->id(), [
                    'id' => $payload->id(),
                    'connection' => $connection,
                    'queue' => $queue,
                    'name' => $payload->decoded['displayName'],
                    'status' => 'pending',
                    'payload' => $payload->value,
                    'created_at' => $time,
                    'updated_at' => $time,
                ]
            );

            $pipe->expireat(
                $payload->id(), Chronos::now()->addMinutes($this->recentJobExpires)->getTimestamp()
            );
        });
    }
398334
protected function pushToDatabase($delay, $queue, $payload, $attempts = 0)
	{
		$availableAt = $delay instanceof DateTime ? $delay : Carbon::now()->addSeconds($delay);

		return $this->database->table($this->table)->insertGetId([
			'queue' => $this->getQueue($queue),
			'payload' => $payload,
			'attempts' => $attempts,
			'reserved' => 0,
			'reserved_at' => null,
			'available_at' => $availableAt->getTimestamp(),
			'created_at' => $this->getTime(),
		]);
	}
268763
protected function createPayloadArray($job, $queue, $data = '')
    {
        return array_merge(parent::createPayloadArray($job, $queue, $data), [
            'queue' => $this->getQueue($queue),
        ]);
    }
1189213
public function dispatch(Queueable $job)
    {
        if (isset($job->queue, $job->delay)) {
            return $this->connection->laterOn($job->queue, $job->delay, $job);
        }
        if (isset($job->queue)) {
            return $this->connection->pushOn($job->queue, $job);
        }
        if (isset($job->delay)) {
            return $this->connection->later($job->delay, $job);
        }

        return $this->connection->push($job);
    }
252527
private function pushExecutedJob(Job $job)
    {
        $this->executedJobs[] = $job;

        $compiled = $job->compile();

        // If callable, log the string Closure
        if (is_callable($compiled)) {
            $compiled = 'Closure';
        }

        $this->addSchedulerVerboseOutput("Executing {$compiled}");

        return $job;
    }
989905
protected function pushToDatabase($queue, $payload, $delay = 0, $attempts = 0)
    {
        return $this->database->table($this->table)->insertGetId($this->buildDatabaseRecord(
            $this->getQueue($queue), $payload, $this->availableAt($delay), $attempts
        ));
    }
381269
public function push($job, $data = '', $queue = null)
	{
		$this->resolveJob($job, $data)->fire();

		return 0;
	}