DZone
Thanks for visiting DZone today,
Edit Profile
  • Manage Email Subscriptions
  • How to Post to DZone
  • Article Submission Guidelines
Sign Out View Profile
  • Post an Article
  • Manage My Drafts
Over 2 million developers have joined DZone.
Log In / Join
Refcards Trend Reports Events Over 2 million developers have joined DZone. Join Today! Thanks for visiting DZone today,
Edit Profile Manage Email Subscriptions Moderation Admin Console How to Post to DZone Article Submission Guidelines
View Profile
Sign Out
Refcards
Trend Reports
Events
Zones
Culture and Methodologies Agile Career Development Methodologies Team Management
Data Engineering AI/ML Big Data Data Databases IoT
Software Design and Architecture Cloud Architecture Containers Integration Microservices Performance Security
Coding Frameworks Java JavaScript Languages Tools
Testing, Deployment, and Maintenance Deployment DevOps and CI/CD Maintenance Monitoring and Observability Testing, Tools, and Frameworks
Partner Zones AWS Cloud
by AWS Developer Relations
Culture and Methodologies
Agile Career Development Methodologies Team Management
Data Engineering
AI/ML Big Data Data Databases IoT
Software Design and Architecture
Cloud Architecture Containers Integration Microservices Performance Security
Coding
Frameworks Java JavaScript Languages Tools
Testing, Deployment, and Maintenance
Deployment DevOps and CI/CD Maintenance Monitoring and Observability Testing, Tools, and Frameworks
Partner Zones
AWS Cloud
by AWS Developer Relations
  1. DZone
  2. Testing, Deployment, and Maintenance
  3. DevOps and CI/CD
  4. Database Continuous Delivery in a Git World

Database Continuous Delivery in a Git World

Life is too short to have to worry about multiple systems of record. Until you can avoid reviewing database schema changes at every point, you aren't moving at Git speed.

Robert Reeves user avatar by
Robert Reeves
·
Jan. 19, 17 · Opinion
Like (2)
Save
Tweet
Share
5.45K Views

Join the DZone community and get the full member experience.

Join For Free

Git has radically changed our perspective on branching and merging, distributed development, and the value of treating everything as code. Git users are able to rapidly branch and merge code to support non-linear development. With local repositories, Git supports widely distributed development teams that are no longer dependent on network resources. Our environments are now being described in code stored in Git repositories.

All of these benefits can be shared with our database developers and database administrators with just a few shifts in focus.

The first shift is that we must store all our environment changes (code, database schema changes, and environment config) in Git. We can no longer have multiple systems of record. Prior to Git, we were slowed by the network requirements of other version control systems. We didn’t want to store large amounts of information in the repository because pulling it down took too long. Now, with local repository access with Git, we see several orders of magnitude in performance improvement.

To that end, by storing our code and database changes in one location, we can benefit from the atomicity of the change. No longer are we concerned with which version of the code changes goes with which version of the database changes. Life is too short to have to worry about multiple systems of record.

Secondly, manual review of database changes at every stage needs to stop. Nowhere in our software development lifecycle do we review code changes after a build and release to test. Sure, we have code reviews in development — and thanks to Git’s rapid branch and merge capabilities, we can easily do that. However, we are not performing the same code reviews with our database changes.

Consider this: what impact would a system administrator reviewing code changes prior to deployment have on our deployment times? Of course, deployment times would expand. However, I’m sure you are most concerned with why a system administrator is reviewing code changes. Commonly, we have our Database Administrators perform this same review.

Forcing a review of database schema changes at every point proves that your current process and tooling is unable to guarantee quality and safety of the change. Until you can avoid this, you are not moving at Git speed.

Finally, relying on SQL scripts alone is foolish. The problems inherent to deploying SQL scripts are twofold. The first issue that you are faced with an incomplete execution of a series of scripts. You have no guarantee that your SQL scripts will execute properly in a target environment (which probably explains why you are manually reviewing today.) Secondly, if there is a failure that requires some rollback, you are left with manually exiting the deployment. Of course, you can mitigate that by requiring rollback scripts, but enforcing that is another headache and burden for an already overworked database team.

Database Git Continuous Integration/Deployment Delivery (commerce)

Published at DZone with permission of Robert Reeves. See the original article here.

Opinions expressed by DZone contributors are their own.

Popular on DZone

  • The 5 Books You Absolutely Must Read as an Engineering Manager
  • Fargate vs. Lambda: The Battle of the Future
  • How To Handle Secrets in Docker
  • Spring Boot vs Eclipse MicroProfile: Resident Set Size (RSS) and Time to First Request (TFR) Comparative

Comments

Partner Resources

X

ABOUT US

  • About DZone
  • Send feedback
  • Careers
  • Sitemap

ADVERTISE

  • Advertise with DZone

CONTRIBUTE ON DZONE

  • Article Submission Guidelines
  • Become a Contributor
  • Visit the Writers' Zone

LEGAL

  • Terms of Service
  • Privacy Policy

CONTACT US

  • 600 Park Offices Drive
  • Suite 300
  • Durham, NC 27709
  • support@dzone.com
  • +1 (919) 678-0300

Let's be friends: