Database Migration : GSOC Project 2012


GitHub branch

Weekly Meeting Schedule : Tuesday, 16:30 UTC

Personal Details


Name : Anubhav Aggarwal
Country : India
Timezone: GMT + 5:30
Email : anubhav[at]gmail[dot]com
IRC Nick: anubhav


Name : Pat Tressel
Email : ptressel[at]myuw[dot]net
IRC Nick : ptressel

Name : Francis Boon
Email : francisboon[at]gmail[dot]com
IRC Nick : flavour

Project Abstract

The Database Migration project provides the developers with python scripts, to migrate or populate the database data between revisions .These scripts are provided according to the changes they have made in the database schema in comparison to the previous revision and also their intent behind there revision . This system also caters to the need of change in functionality of a field even if the database schema remains unchanged.

During this project, I will develop a detecting mechanism which determines the changes in the database schema with respect to the older revision using DAL. This detecting file can made to run after every commit. Then ask the developer what his intent was behind those particular changes using the view and he would be required to match up the renamed tables and columns.If the changes that the developer requested were compatible then the developer will be given a python script that he can use in order to populate the database. However if the changes are not compatible like changing the type of an existing field in a table, we would have to ask him to write the mappings which will be used for populating the tuples. A python script will be generated according to the mapping he has provided.

These script, which is generated and approved by the developer is stored in a folder for the use of System Admin , and will be run using "git hooks" attached with the "git pull" which will make the migration script present in the revision (provided by developer ) run

Project Goals and Plans

Tasks Desciption
Create Tracking schema Changes Script This Phase includes creating python script that can generate the schema changes between a serialized DAL instance and the current database . This would generate the result in the form of 2 dicts one contains appeared and the other contains disappeared .
Creating Actual Migration Scripts These scripts are made for these scenarios - Renaming a field, Adding New field, Deleting a field, Changing Type of a field
Building Tests and Adding Git hooks with the git pulls for the Sysadmin These are used when a pull request is accepted by the Sysadmin thus the migration script is run and tested from the consent of the sysadmin who is presented with the changes and the script build from the recommendations of the developer ,if any problems occur or changes needs to be done sysadmin can change the script
Adding The GUI for the developers who make the changes in their own forks This is view by which the developer can express express his intents ,and give his recommendations about the changes , these will be reviewed by the sysadmin when we accepts his pull requests

Due Date goal Status
Second trimester (2 June - 9 July)
10June Proper documentation of the Project goals, Deciding on the project workflow and start the coding for the Tracking Phase Done
15 June Converting Schema in a Dict In topo order completed Done
3 June Creating Actual Migration Scripts In progress
5 July Building comparison script In progress
8 July Adding Git portion to extract the second instance automatically through git pull from the branch
Third trimester (10 July - 13 August)
20 July Combining the comparison script and migration script to make the few things automated
28 July adding Wrappper script
3 August Testing
13 August Documentation Updates
Last modified 12 years ago Last modified on 06/28/12 17:48:51
Note: See TracWiki for help on using the wiki.