Following Copado's best practices in your release management process, you will be able to identify issues with your metadata changes as they are being deployed from one environment to the next. While enforcing quality gates, you will be able to troubleshoot the issues before the changes arrive to production. Hence, the probability of errors in production is minimal or non-existent.
However, if you would like to perform a rollback of all or some metadata changes after a deployment, the process to do so consists of the following two steps:
- Before a deployment:
- Backup the destination org in your Git repository with a Git snapshot, in case you don't have this already scheduled to backup automatically on a daily or weekly basis.
- After a deployment (and if you would like to rollback changes):
- Create a snapshot difference to compare the backup commit against the destination org. Once the difference calculation is finished, select the files that you would like to deploy to the destination org. Click on Create Deployment and then follow the steps in order to deploy the metadata components from the Git backup.
- If you're working with Copado Branch Management, commit the files that you deployed from the backup commit to the destination org, so that the Git branch linked to the destination org is also updated.