Added first edition of the plan to move data to the new module system.
diff --git a/MelangeModuleArchitecture.wiki b/MelangeModuleArchitecture.wiki index 3d01c66..3e485ef 100644 --- a/MelangeModuleArchitecture.wiki +++ b/MelangeModuleArchitecture.wiki
@@ -243,4 +243,53 @@ * task.py (Needs to be redone because it was wrong) == Model Conversion Process == -TODO: This section will explain the process which will be used to transfer the old datamodels into the new hierarchy. \ No newline at end of file +Converting to the new module system is going to be a multi-step process. This way we can have more control over the data. We will also be keeping all the old data until the conversion process is complete. + +The steps are outlined below: + +1. Convert the current Program entities to GSoCProgram entities keeping the same keyname. + +2. Convert all Organization entities to GSoCOrgs keeping their repsective keynames but with updating the Program reference (scope) to the respective GSoCProgram. The GSoCProgram can be easily looked up since it will have the same keyname as the Program entity. + +3. Update all OrgAdmins to GSoCOrgAdmins and change their scope to reference to the new GSoCOrganization and the program reference to the new GSoCProgram. + +4. The same as 3 but just for Mentors -> GSoCMentors. + +5. Convert the Student entities to GSoCStudent entities and update their Program reference to contain the new GSoCProgram. + +*At this point we are done with creating new entities, however several references still need to be updated* + +6. Update the StudentProposal entities with the following references: + * scope should be set to the new GSoCStudent + * mentor should be set to the new GSoCMentor + * possible_mentors should only contain GSoCMentors + * org property should be updated to contain GSoCOrganization + * program property should be updated to contain the new GSoCProgram + +7. Update the Review entities. We should look into deleting the role reference property or otherwise we need to ensure that we convert the Students to GSoCStudents, Mentors to GSoCMentors and OrgAdmins to GSoCOrgAdmins. + +8. Update the StudentProject entities with the following references: + * scope should be set to the new GSoCOrganization + * mentor should be updated with the new GSoCMentor + * additional_mentors should be updated with the new GSoCMentor entities + * student property should be updated to contain the new GSoCStudent reference. + * program property should be updated to contain the new GSoCProgram reference + +9. Update the Survey, ProjectSurvey and GradingProjectSurveys: + * For prefix == 'program' the scope entity should be updated to contain the new GSoCProgram model. All other prefixes should have never been in use. + +10. Update the ProjectSurveyRecords and GradingProjectSurveyRecords org property to reference the new GSoCOrganization entity. + +11. Update the Document model: + - For prefix == 'org' the scope should be updated to contain the new GSoCOrganization entity. If home_for is set this should be updated to the new GSoCOrganization as well. + - For prefix =='program' the scope should be updated to contain the new GSoCProgram enity. Same goes for the home_for property. + +*The move to the new module system is complete* + +Optional: + +12. Change proposal to have the organization as scope and student as a separate property. This would require updating the references from the reviews. + +13. Might also be good to move Reviews to an id_based system as well as Comments. This will help with change 12 as well as make it a more generic system. + +14. Rework document system to contain the prefix internally and work on an id-based system. This will make it easier to move documents between scopes and also makes it easier for the system for use within the module approach. \ No newline at end of file