OutgoingTask

Implements \SymfonyBundles\Fork\TaskInterface

Class TestTask provides background outgoing HTTP requests in forked process

package

App\Task

Methods

OutgoingTask constructor to provide XML POST to target endpoint URLs with new headers

__construct(integer $id, \Doctrine\ORM\EntityManager $em, \Symfony\Component\DependencyInjection\ParameterBag\ParameterBagInterface $params, \Psr\Log\LoggerInterface $logger) 

Arguments

$id

integer

$em

\Doctrine\ORM\EntityManager

$params

\Symfony\Component\DependencyInjection\ParameterBag\ParameterBagInterface

$logger

\Psr\Log\LoggerInterface

TaskInterface Execute function runs as a forked child process in background with logging attached

execute() 

Properties

Incoming ID of record to process via `php bin/console app:outgoing (id}`

id : integer
var

Type(s)

integer

Symfony Application parameters injection via auto-wiring

params : \Symfony\Component\DependencyInjection\ParameterBag\ParameterBagInterface
var

Type(s)

\Symfony\Component\DependencyInjection\ParameterBag\ParameterBagInterface

Doctrine Entity Manager for application via config/services.yaml

em : \Doctrine\ORM\EntityManager
var

Type(s)

\Doctrine\ORM\EntityManager

Logger Interface for application passed via auto-wiring

logger : \Psr\Log\LoggerInterface
var

Type(s)

\Psr\Log\LoggerInterface