Update user registration ultimate trials eligibility to use new SSOT endpoint

Background

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

Objective

Update the user registration process to use the new SSOT endpoint for Ultimate trials eligibility checks, while maintaining the ability to fall back to the current database queries if needed.

Requirements

  1. Integrate the new SSOT endpoint into the user registration 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_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 registration process.

Acceptance Criteria

  • Feature flag use_ssot_for_trial_eligibility is implemented and functional.
  • User registration 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 registration process speed.
  • 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

Next Steps

  1. Implement the feature flag.
  2. Integrate the new SSOT endpoint into the registration 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