protected function isCacheFileExpired(string $cacheEntryPathAndFilename, bool $acquireLock = true): bool
    {
        if (is_file($cacheEntryPathAndFilename) === false) {
            return true;
        }

        $expiryTimeOffset = filesize($cacheEntryPathAndFilename) - self::DATASIZE_DIGITS - self::EXPIRYTIME_LENGTH;
        if ($acquireLock) {
            $expiryTime = (integer)$this->readCacheFile($cacheEntryPathAndFilename, $expiryTimeOffset, self::EXPIRYTIME_LENGTH);
        } else {
            $expiryTime = (integer)file_get_contents($cacheEntryPathAndFilename, null, null, $expiryTimeOffset, self::EXPIRYTIME_LENGTH);
        }

        return ($expiryTime !== 0 && $expiryTime < time());
    }