-
Notifications
You must be signed in to change notification settings - Fork 1
docs: add arch decision record for the migration path for legacy user grouping mechanisms #4
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Changes from 2 commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,95 @@ | ||
| 5. Migration Path for Legacy User Grouping Mechanisms | ||
| ##################################################### | ||
|
|
||
| Status | ||
| ****** | ||
|
|
||
| **Draft** - 2025-06-03 | ||
|
|
||
| Context | ||
| ******* | ||
|
|
||
| Open edX currently uses several user grouping mechanisms (Cohorts, Teams, | ||
| Enrollment Track Groups), each with its own logic, storage, and integration | ||
| points. This fragmentation results in: | ||
|
|
||
| - Complicates maintenance and evolution. | ||
| - Makes it difficult to implement new functionality. | ||
| - Limits interoperability and extensibility. | ||
saraburns1 marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
|
|
||
| Two migration paths were evaluated to transition to a unified grouping system: | ||
|
|
||
| - **Cross-System Synchronization**: creates an abstraction layer that | ||
| translates the new model to the legacy mechanisms. | ||
| - **Behavior Replication**: builds a new and independent system that replicates | ||
|
||
| the observable behavior of the legacy mechanisms without integrating with | ||
| them. | ||
|
|
||
| Decision | ||
| ******** | ||
|
|
||
| We select the behavior replication approach, eliminating direct dependencies on | ||
| legacy systems. This choice enables a simpler, cleaner architecture with: | ||
|
|
||
| - Full independence from legacy mechanisms from day one. | ||
| - Elimination of complex synchronization or integration layers. | ||
| - Reduced technical debt and maintenance costs during migration. | ||
|
|
||
| Existing user-facing functionalities will be replicated in the new model, with | ||
saraburns1 marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
| migration executed in clear, isolated phases to minimize risk. Activation will | ||
| be controlled via feature flags, configurable per course, organization, or | ||
| platform. | ||
|
|
||
| See `ADR 6 <docs/decisions/0006-replication-of-legacy-mechanisms-behavior.rst>`_ | ||
| for detailed rationale. | ||
|
|
||
| Consequences | ||
| ************ | ||
|
|
||
| - The new system can evolve independently, allowing greater flexibility. | ||
| - The responsibility for replicating legacy behavior lies entirely within the | ||
| new model, which must be thoroughly validated. | ||
| - The transition can be carried out gradually, implementing one functionality | ||
| at a time, allowing individual behavior validation and more targeted testing. | ||
| - Both new and legacy systems can coexist during rollout, avoiding user | ||
| disruption. | ||
| - Legacy systems will be fully deprecated and removed post-transition, | ||
|
||
| improving maintainability and extensibility. | ||
|
|
||
| Rejected Alternatives | ||
|
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Another rejected decision was maintaining both the new model and legacy, I think.
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. That alternative wasn’t documented. Do you think we should include it as a rejected option as well? I can add a brief explanation of why it was not chosen. |
||
| ********************* | ||
|
|
||
| Cross-System Synchronization | ||
|
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Should we compare the two as we did in the technical document? https://openedx.atlassian.net/wiki/spaces/OEPM/pages/5014192131/Migration+Path+Proposals+from+Legacy+to+the+Unified+Model#Comparative-Table
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I agree! I included the comparative table. |
||
| ============================ | ||
|
|
||
| This proposal involved creating a new unified model while maintaining indirect | ||
|
||
| synchronization with the legacy mechanisms through an abstraction layer. This | ||
| layer would be responsible for: | ||
|
|
||
| - Translating the logic of the new system to Cohorts, Teams, and Enrollment | ||
|
||
| Track Groups. | ||
| - Ensuring backward compatibility during the entire transition. | ||
| - Enabling a gradual adoption while maintaining functional consistency with the | ||
| legacy systems. | ||
|
|
||
| Reasons it was rejected: | ||
|
|
||
| - Significant increase in technical complexity: maintaining bi-directional | ||
|
||
| synchronization between two systems introduces risk of errors, logic | ||
| duplication, and hard-to-debug issues. | ||
| - Higher maintenance cost: any change in the platform or legacy models would | ||
| also require updating the synchronization layer. | ||
| - Interference with the evolution of the new model: depending on legacy systems | ||
| limits the ability of the new system to introduce more flexible criteria or | ||
| rules. | ||
| - Greater difficulty in isolating and testing the new system: requiring the | ||
| presence of legacy systems makes independent validation of the new model more | ||
| complex. | ||
| - Legacy cleanup becomes harder: as long as active synchronization exists, | ||
| legacy code cannot be removed without breaking dependencies. | ||
|
|
||
| References | ||
| ********** | ||
|
|
||
| - `Cross-System Synchronization Proposal <https://openedx.atlassian.net/wiki/x/AoBhJwE>`_ | ||
| - `Behavior Replication Proposal <https://openedx.atlassian.net/wiki/x/AgDiKgE>`_ | ||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It'd be useful to add the following in this context section as context on how we got here -these are only some ideas that should be refined before including them-:
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for your suggestions! I updated the section to provide a bit more context. What do you think?