OperationParticipant
in
Store that wants to know where an operation begins and ends (Doctrine, later cache or search).
A participant registers itself with the DI tag OperationScope::PARTICIPANT_TAG; nobody forwards begin/end through the model layers. It gets only root frames, synchronously, in the order of registration. An exception thrown here is caught and logged by the scope and never changes the result of the operation, except OperationContractViolationException from end(): the scope rethrows it once every participant ended and the frame is closed, unless the operation failed with its own exception. A participant throws it only after its own cleanup, so nothing dirty is left for the next operation.
Table of Contents
Methods
- begin() : void
- end() : void
- key() : string
- Stable name of the resource, e.g. `doctrine.default`; unique among participants.
Methods
begin()
public
begin(OperationFrame $frame) : void
Parameters
- $frame : OperationFrame
end()
public
end(OperationFrame $frame, OperationOutcome $outcome, Throwable|null $primary) : void
Parameters
- $frame : OperationFrame
- $outcome : OperationOutcome
- $primary : Throwable|null
-
the exception that leaves the operation; it is rethrown by the caller after this call, so a participant must not keep it
key()
Stable name of the resource, e.g. `doctrine.default`; unique among participants.
public
key() : string