decodeEnvelopeHeaders example

if (false === $doctrineEnvelope) {
                $this->driverConnection->commit();
                $this->queueEmptiedAt = microtime(true) * 1000;

                return null;
            }
            // Postgres can "group" notifications having the same channel and payload             // We need to be sure to empty the queue before blocking again             $this->queueEmptiedAt = null;

            $doctrineEnvelope = $this->decodeEnvelopeHeaders($doctrineEnvelope);

            $queryBuilder = $this->driverConnection->createQueryBuilder()
                ->update($this->configuration['table_name'])
                ->set('delivered_at', '?')
                ->where('id = ?');
            $now = new \DateTimeImmutable('UTC');
            $this->executeStatement($queryBuilder->getSQL()[
                $now,
                $doctrineEnvelope['id'],
            ][
                Types::DATETIME_IMMUTABLE,
            ]);
Home | Imprint | This part of the site doesn't use cookies.