Update in-app ultimate trials eligibility to use new SSOT endpoint

Background

We are updating our in-app ultimate trials eligibility process to use a new Single Source of Truth (SSOT) endpoint. This change is part of our ongoing efforts to improve the accuracy and efficiency of our trial eligibility checks for GitLab Ultimate.

Objective

Update the in-app ultimate trials eligibility process to use the new SSOT endpoint, while maintaining the ability to fall back to the current database queries if needed.

Requirements

  1. Integrate the new SSOT endpoint into the in-app flow for ultimate trials eligibility checks.
  2. Implement a feature flag to control the use of the new SSOT endpoint vs. the current database queries.
  3. Ensure proper error handling and logging for both the new endpoint and the existing database queries.
  4. Update relevant tests to cover both the new and existing eligibility check methods.

Implementation

  • Implement a feature flag named use_ssot_for_ultimate_trial_eligibility.
  • When the flag is off, continue using the current database queries for eligibility checks.
  • When the flag is on, use the new SSOT endpoint for eligibility checks.
  • Implement logging to track which method is being used for each eligibility check.

Technical Considerations

  • Ensure that the integration with the new SSOT endpoint is performant and doesn't introduce significant latency to the in-app trial eligibility process.

Acceptance Criteria

  • Feature flag use_ssot_for_ultimate_trial_eligibility is implemented and functional.
  • In-app ultimate trials eligibility process successfully uses the new SSOT endpoint when the feature flag is on.
  • Fallback to current database queries works correctly when the feature flag is off.
  • Error handling and logging are implemented for both methods.
  • Performance metrics show no significant degradation in the eligibility check process.
  • All relevant tests are updated and passing.
  • Documentation is updated to reflect the new eligibility check process.

Related Issues

  • Create SSOT endpoint for trial eligibility checks
  • Update in-app duo pro trials eligibility to us... (#507862 - closed)
  • Update user registration ultimate trials eligib... (#507863 - closed)
  • Update in-app duo enterprise trials eligibility... (#507861 - closed)

Next Steps

  1. Implement the feature flag.
  2. Integrate the new SSOT endpoint into the in-app ultimate trials eligibility process.
  3. Update error handling and logging.
  4. Update and create new tests as needed.
  5. Perform thorough testing in a staging environment.
  6. Plan for gradual rollout and monitoring in production.
  7. Schedule cleanup and full migration after successful rollout.
Edited Dec 04, 2024 by Doug Stull
Assignee Loading
Time tracking Loading