We accidentally did the structural (database) changes for T336848: Change how the donation bounded context stores tracking data in ticket T336846: Migrate donation tracking data to new table. This ticket is about integrating those database changes into the Fundraising Application and deploying the them to test and production.
We will not do the data migration in production (that'll be part of the deployment in T336848: Change how the donation bounded context stores tracking data), only the structural database changes.
Affected repositories
- Fundraising Application
Implementation details
- Update wmde/fundraising-donations dependency to the newest version
- update the SQL by running make generate-database-schema
Deployment
This needs a database, both in the test and production deployment.
- deploy (without symlinking, see deployment documentation on the Ansible parameters: https://github.com/wmde/fundraising-infrastructure/blob/main/docs/deployment/Fundraising_Application.md#skip_symlink)
- run Doctrine migration
- do a normal deployment ( = no symlink skipping)
Testing the data migration script in the testing environment (DONE)
To make sure that the production data migration will run smoothly, do the following steps:
- copy the production database to test
- create the file migrations-db.php file in the project root directory (current-release), with PDO connection data returned as an array. You can convert the db section from the JSON configuration file into PHP syntax.
- run data migration script vendor/wmde/fundraising-donations/bin/migrate-donation-tracking-data.