RestApiIdempotencyService

package

Default

Methods

__construct

__construct(\Shopware\Components\Model\ModelManager $entityManager, \Doctrine\DBAL\Connection $dbalConnection, \Shopware\Plugins\ViisonPickwareERP\Components\RestApi\RequestLogging\RestApiRequestLoggerService $restApiRequestLoggerService, \Psr\Log\LoggerInterface $logger) 

Arguments

$entityManager

\Shopware\Components\Model\ModelManager

$dbalConnection

\Doctrine\DBAL\Connection

$logger

\Psr\Log\LoggerInterface

Creates and returns a new idempotent operation for the given `$request`.

createIdempotentOperation(\Enlight_Controller_Request_RequestHttp $request, string|null $idempotencyKey = null) : \Shopware\CustomModels\ViisonPickwareERP\RestApi\RestApiIdempotentOperation
Throws
\Shopware\Plugins\ViisonPickwareERP\Components\RestApi\Idempotency\IdempotencyException

if the given $request does not contain a valid Pickware-Idempotency-Key header.

Arguments

$request

\Enlight_Controller_Request_RequestHttp

$idempotencyKey

string|null

Either a string that will be used as idempotencyKeyString or null to retrieve the key automatically from the Pickware-Idempotency-Key HTTP header.

Response

\Shopware\CustomModels\ViisonPickwareERP\RestApi\RestApiIdempotentOperation

Executes the given `$executionPhases` within the context of the given `$idempotentOperation`.

executeIdempotently(\Shopware\CustomModels\ViisonPickwareERP\RestApi\RestApiIdempotentOperation $idempotentOperation, array $executionPhases) 
Throws
\Shopware\Plugins\ViisonPickwareERP\Components\RestApi\Idempotency\IdempotencyException

if reaching a non-finished recvery point without respective execution phase.

Arguments

$executionPhases

array