public function getVariationForFeatureExperiment(FeatureFlag $featureFlag, $userId, $userAttributes)
    {
        $featureFlagKey = $featureFlag->getKey();
        $experimentIds = $featureFlag->getExperimentIds();

        // Check if there are any experiment IDs inside feature flag
        if (empty($experimentIds)) {
            $this->_logger->log(
                Logger::DEBUG,
                "The feature flag '{$featureFlagKey}' is not used in any experiments."
            );
            return null;
        }

        // Evaluate each experiment ID and return the first bucketed experiment variation
        foreach ($experimentIds as $experiment_id) {
            $experiment = $this->_projectConfig->getExperimentFromId($experiment_id);
            if ($experiment && !($experiment->getKey())) {
                // Error logged and exception thrown in ProjectConfig-getExperimentFromId
                continue;
            }

            $variation = $this->getVariation($experiment, $userId, $userAttributes);
            if ($variation && $variation->getKey()) {
                $this->_logger->log(
                    Logger::INFO,
                    "The user '{$userId}' is bucketed into experiment '{$experiment->getKey()}' of feature '{$featureFlagKey}'."
                );

                return new FeatureDecision($experiment, $variation, FeatureDecision::DECISION_SOURCE_FEATURE_TEST);
            }
        }

        $this->_logger->log(
            Logger::INFO,
            "The user '{$userId}' is not bucketed into any of the experiments using the feature '{$featureFlagKey}'."
        );

        return null;
    }