for testing and deploying your application
for finding and fixing issues
for empowering human code reviews
<?php
namespace Pheanstalk\Command;
use Pheanstalk\Exception;
use Pheanstalk\Structure\Workflow;
use Pheanstalk\XmlResponseParser;
/**
* The 'put' command.
*
* Inserts a job into the client's currently used tube.
* @see UseCommand
* @author Paul Annesley
* @package Pheanstalk
* @license http://www.opensource.org/licenses/mit-license.php
*/
class PutCommand extends AbstractCommand implements \Pheanstalk\ResponseParser
{
/** @var Workflow $workflow */
private $workflow;
* Puts a workflow in queue.
* @param Workflow $workflow The Workflow
public function __construct(Workflow $workflow)
$this->workflow = $workflow;
}
* @inheritDoc
public function getGroup(): string
return 'instance';
public function getAction(): string
return 'launch';
public function getFilters(): array
return [
'name' => $this->workflow->getName(),
];
public function getResponseParser()
return $this;
public function parseResponse($responseLine, $responseData)
return $responseData['@attributes'];