Version Control Database Development Uri Margalit DBmaestro
May 11, 2015
Version Control Database Development Uri Margalit
DBmaestro
About the presenter
• Director of Products at DBmaestro• +20 years experience in enterprise management• R&D Director at Precise / VERITAS / Symantec
About DBmaestro…
Agenda
• Yesterday, Today & Tomorrow• App development vs. DB development• Exploring the gap• Short demo• Benefits
Yesterday, Today & Tomorrow
Yesterday – Version Control
• Version Control becomes standard de-facto• Files are Checked-Out & Checked-In to
reflect the change• All changes are documented• Ability to tag a version crossing different revisions• Ability to compare changes across the history• Know Who did What, When and Where
Yesterday – ALM
• Application Lifecycle Management not only:• Version Control• Test Management
• Application Lifecycle Management consists of:• Requirement Management• Version Control• Change Management• Test Management• Release Management
Today – Agile
• Adopted quickly by many organizations• Allows development teams to present working
products every couple of weeks
Tomorrow – DevOps
• Agile already adopted quickly by many organization• Collaborate development teams and operations to
ensure highest quality deployments
“Every developer must think of the end user. Committing a piece of code is far from being done. It needs to work in all kinds of weird use cases. And it’s not only QA’s job to find all the bugs. Good developers want to ensure that the new features are not only coded, but tested and ultimately
released to their users. Only then the task is really done.” Matthias Marschall
Poll – What do you utilize
• Which method does your organization utilize?• Application Version Control • Database Version Control• Application Lifecycle Management• Agile• DevOps
Methods & Processes Evolution
Version ControlKeep Track of Changes
ALMLink the Change to the Reason
AgileQuick Development of Small Requirements
DevOps
High Quality & Quick Deployment of Development Products
App development vs. DB development
Poll – Database Version Control
• What is the main feature you see in database version control?• Working directly in the Oracle IDE
(required to Check-Out the object)• No need to maintain change scripts• Generating the deployment scripts• Integration with Change Management System (ALM)• Merge & Deploy automation
One enforced process
App Development
Check-Out File
Modify File
Run Applications’
Tests
Check-In File
DB Development – Today
Two isolated processes
Benefits We Do NOT Have
Visibility into the Lifecycle of Releases
Concurrent Database Development
Consistent Database Environments
Meeting Release Schedules with Desired Quality
Automated Tasks
Agility in Responding to Scope Changes
App Development
Version Control: App vs. DB
Text Based
DB Development
Knowledge of the content change is not relevant
No relationship between files
Store locally
Changes published only in Check-In
Deploy done by copy & replace previous executable
Many types of objects and syntax
Reference data has many formats
Central resource
No Change Policy Enforcement
Changes affect immediately
Deploy must preserve existing data
One enforced process as exists in App Development
DB Development – The Future
18
Poll – Oracle IDE
• Which Oracle IDE do you use?• Oracle SQL Developer• Oracle PL/SQL Developer• TOAD• SQL Navigator• SQL*Plus
19
Database & Version Control
• Same Version Control Principles:
Object LockingCheck out / in for PL/SQL Code, Structure & DataBaselineTag / Label / Golden CopyCompare / MergeDeploy / Build
20
Database & ALM
• Integration with Change Management System
Know the Reason (Why) for any changeAbility to Deploy changes by TasksBetter reports on the work for each Requirement
21
Database & Agile
• More then just Compare & Sync• Merge Changes from several environments
Automation (web services, command line)Deploy based on Version Control Repository3-Way analysis
22
Baseline in Deployments
23
Simple Compare & Sync 3-way Analysis & Deploy
With Baseline the unknown is now known
You do not have all the information
DevOps Deployment
• Many small deployments deployed frequentlyGenerate on-the-fly deploy scripts3-Way Analysis – prevents wrong decisions
• Application Deployment• Copy & Replace• Error Recovery – Replace new binary,
fixed quickly• Database Deployment
• Alter objects• Error Recovery – New deploy script,
long down time
24
Benefits - Development
• Database Change Repository• Follow SCM best practices
(Check-Out/Check-In)• All Changes are documented• Manage Who can do What, Where, When & Why
25
Benefits - Operation
• Integrated Deployment Engine• Business Level Audit• Roles & Responsibilities Enforcement
26
Summary
• Implement ALM, Agile & DevOps methods in database development
• Manage Who can do What, Where, When and Why• Build Safety net to reduce issues in production
27
Thanks for listening