php-enqueue/enqueue-dev

[Doctrine DBAL] Invalid timestamp of published_at value

andrewprofile opened this issue · 1 comments

https://github.com/php-enqueue/dbal/blob/d6c6d38290415d6383ab156a9cf580a99bd05522/DbalProducer.php#L65

        $publishedAt = null !== $message->getPublishedAt() ?
            $message->getPublishedAt() :
            (int) (microtime(true) * 10000)
        ;

microtime return value in seconds so the conversion to timestamp is invalid, ex : 16551970635236 -> GMT: Monday, 5 July 2494 17:37:15.236

published_at does not represent the date, but the created time in milliseconds.