public static function getNumericValue($eventTags, $logger)
    {
        if (!$eventTags) {
            $logger->log(Logger::DEBUG, "Event tags is undefined.");
            return null;
        }

        if (!is_array($eventTags)) {
            $logger->log(Logger::DEBUG, "Event tags is not a dictionary.");
            return null;
        }

        if (!isset($eventTags[self::NUMERIC_EVENT_METRIC_NAME])) {
            $logger->log(Logger::DEBUG, "The numeric metric key is not defined in the event tags or is null.");
            return null;
        }

        if (!is_numeric($eventTags[self::NUMERIC_EVENT_METRIC_NAME])) {
            $logger->log(Logger::DEBUG, "Numeric metric value is not an integer or float, or is not a numeric string.");
            return null;
        }

        if (is_nan($eventTags[self::NUMERIC_EVENT_METRIC_NAME]) || is_infinite(floatval($eventTags[self::NUMERIC_EVENT_METRIC_NAME]))) {
            $logger->log(Logger::DEBUG, "Provided numeric value is in an invalid format.");
            return null;
        }

        $rawValue = $eventTags[self::NUMERIC_EVENT_METRIC_NAME];
        // # Log the final numeric metric value
        $logger->log(Logger::INFO, "The numeric metric value {$rawValue} will be sent to results.");

        return floatval($rawValue);
    }