webinar: "in database automation we trust"

65
Emerasoft srl Mission Vision Market & Solutions Monica Burzio Gian Giacomo Ermacora

Upload: emerasoft-solutions-to-collaborate

Post on 11-Jan-2017

279 views

Category:

Software


1 download

TRANSCRIPT

Page 1: Webinar: "In database automation we trust"

•Emerasoft srl•Mission•Vision•Market & Solutions

Monica BurzioGian Giacomo Ermacora

Page 2: Webinar: "In database automation we trust"

Agenda

• Principi di Continuous Delivery • Vantaggi della CD • CD per il database?• Database version control• Database deployment automation• Database impact analysis• Stopping the CD line• DBmaestro Demo• Q&A

Webinar: “In Database automation we trust”

SETTEMBRE 2015

Page 3: Webinar: "In database automation we trust"

Chi siamo

Data di nascita: 2005

Dove siamo:

via Po, 1 – Torino via del Poggio Laurentino, 118 - Roma

Creare valore per i nostri clienti implementando soluzioni

che aumentano la produttività, facilitando la collaborazione.

La nostra mission:

Page 4: Webinar: "In database automation we trust"

Alcuni clienti

Page 5: Webinar: "In database automation we trust"

DevOpsIoT

System & Software Engineering

Testing

ALM

SOAProcess Intelligence

Business Intelligence

Security

Digital Publishing

Training

ALM+PLMtraceability

standard compliance

collaboration

Big Data

BYOD

User Experience

QualityEnterprise Mobility

agileIoD

IoH

Usability

APIBPM

Continuous Delivery Continuous Integration

Page 6: Webinar: "In database automation we trust"

DevOpsIoT

System & Software Engineering

Testing

ALM

SOAProcess Intelligence

Business Intelligence

Security

Digital Publishing

Training

ALM+PLMtraceability

standard compliance

collaboration

Big Data

BYOD

User Experience

QualityEnterprise Mobility

agileIoD

IoH

Usability

APIBPM

Continuous Delivery Continuous Integration

Page 7: Webinar: "In database automation we trust"

PRESSIONI MERCATO Qualità

Page 8: Webinar: "In database automation we trust"

REQUISITI PROCESSI

ATTIVITÁ COLLABORAZIONE

Page 9: Webinar: "In database automation we trust"

DevOps

Continuous Delivery

Continuous Integration

Automatisation ContinuousAcceleration

Page 10: Webinar: "In database automation we trust"

In Database Automation

We Trust

Page 11: Webinar: "In database automation we trust"

About DBmaestro

• The leading provider of DevOps for Database• Database development and deployment automation

Page 12: Webinar: "In database automation we trust"

DevOps & CD: a must for every company

▪Every business is an IT business

▪Customers demand that you deliver new features faster− Agile Development− Process Automation− DevOps

▪Can’t wait 6 months for that next waterfall release…

▪ If you don’t, your competitor probably will

Page 13: Webinar: "In database automation we trust"

Continuous *what*?

Continuous Integration

Continuous Delivery

Continuous Deployment

!

?

Page 14: Webinar: "In database automation we trust"

What is Continuous Integration?

• Principles and practices• Been around for a while▪ Focus on streamlining development

■ Developers integrate code into shared repository■ Each check-in is verified■ Automated builds■ Automated tests■ High visibility – a feedback loop

▪ Easier & quicker to find problems, less back tracks => short integrations

Page 15: Webinar: "In database automation we trust"

And Continuous Delivery?

▪ Next step after continuous integration▪ Becoming lean, and even more Agile

■ Make sure each change is releasable • Develop-> build-> test-> move to staging-> acceptance test

■ Build a process to release with a push of a button• Deploy to production-> test production

▪ Actual deployment to production in manually actuated

=> Ensure risk mitigation and high efficiency

Page 16: Webinar: "In database automation we trust"

Continuous Delivery

Image from Wikipedia

FailPass

Page 17: Webinar: "In database automation we trust"

Continuous Deployment

• Automating changes all the way to production■ Develop-> build-> test-> move to staging-> acceptance test->

deploy to production-> test production

• Makes sense for Facebook, Amazon, i.e. - for large SAAS solutions.■ A/B test new features■ Throttle traffic to new releases etc…

▪ Not for everyone…

Page 18: Webinar: "In database automation we trust"

How Do I Measure Success?

• More rapid changes• Fewer changes backed out• Better collaboration• Fewer defects

• Ultimately better service • Happy customers • Profitability

Page 19: Webinar: "In database automation we trust"

Continuous Delivery moving ahead!

▪ Recently Conducted DBmaestro Survey■ Over 350 participants

Page 20: Webinar: "In database automation we trust"

Why Continuous Delivery?

Page 21: Webinar: "In database automation we trust"

But…what about the database?

Page 22: Webinar: "In database automation we trust"

What about the database?

Page 23: Webinar: "In database automation we trust"

Down to 14% !!!

• Based on the questions they answered, only 14% from the ones reported doing CD for DB, are actually performing basic CD practices!!!

• The rest are plugging the automated process with various manual steps…

• Why?• What is so special about the database?

Page 24: Webinar: "In database automation we trust"

The Weakest Link In a Chain ???

•Old adage but true• The database is often neglected and therefore can

become the weakest link• Manual processes

•Database/Code Silos exist…• Don’t always communicate effectively• Need to follow same procedures & best practices

•Essential from a compliance and business point of view

•Should be the strongest link

Page 25: Webinar: "In database automation we trust"

The Database is a constraint

Page 26: Webinar: "In database automation we trust"

CD for the database

• In many organizations, changes to databases are not included in the CD picture

• Too much risk – seems to be very challenging

• Too little awareness of the packaging, deployment, promotion etc. concepts used for application code

• Insufficient tool support for these concepts

Page 27: Webinar: "In database automation we trust"

Manual steps in an automated process…

• At first you think: It is easy! We can handle it!

• Then your start fighting a loosing game…

• And then you have to speed up!!!

Page 28: Webinar: "In database automation we trust"

So why not move forward?

• Mistrust…

Page 29: Webinar: "In database automation we trust"

What is the problem?

Root Causes for issues:– Challenging manual version control process– Static deployments code overrides– Dynamic deployments unaware of version control– No release automation red-flags – don’t know when to stop the line…

Page 30: Webinar: "In database automation we trust"

Two isolated processes

Version Control Process (file based)

Development Process

Check-Out Script

Modify Script

Get updated Script from DB

Check-In Script

Compile

Scriptin DB

Debug

Scriptin DB

?

??

?

A

A’

Version control repository is out of sync from the tested database and cannot act as a Single Source of Truth

Page 31: Webinar: "In database automation we trust"

Scripts & version control

Challenges:− Code-overrides− Working on the wrong revisions − Scripts do not always find their way to the version control solution− Out of process updates go unnoticed− Hard to locate outdated update scripts

Playing safe? What we really need: − The actual code of the object− The upgrade script− A roll-back script

Page 32: Webinar: "In database automation we trust"

32

86%Rate this as a risk Factor

64%Rate this as a HIGH risk Factor

Page 33: Webinar: "In database automation we trust"

Scripts… Build Once Deploy Many

X1.11.1.11.11.21.31.41.51.61.7

Int QA Stage Prod

Database Deploy ScriptEnvironment

Re-Base (due to defects)

DevDev

DevModel

1.1 1.2

1.2 1.3

1.3 1.4

1.4 1.5

1.5 1.6

1.6 1.7

1.11.11.41.7

1.1 1.2

1.2 1.3

1.3 1.4

1.4 1.5

1.5 1.6

1.6 1.7

1.1 1.2

1.2 1.3

1.3 1.4

1.4 1.5

1.5 1.61.6 1.7

Out of Process Change

XX

XXX

? 1.1.1

X

a

a

33

Page 34: Webinar: "In database automation we trust"

Scripts are static…

▪ Scripts− Hard to test in their entirely (holistically)− Hard to test due to colliding dependencies− Need to run in a specific order…− Much harder to deal with project scope changes

▪ Scripts, unless super sophisticated:− Unaware of changes made in the target environment− Time passed from their coding to the time they are run− Potentially overriding production hot-fixes or work done in parallel by

another team

Page 35: Webinar: "In database automation we trust"

35

60%of those manually building scripts have

to fix or tweak them regularly as part of a deployment process

Page 36: Webinar: "In database automation we trust"

36

89%Rate this as a risk Factor

60%Rate this as a HIGH risk Factor

Page 37: Webinar: "In database automation we trust"

37

Gaining Trust!

Coordinated Process Traceability

Start in the Beginning

No Out-of-Process Changes

Impact Analysis

Automation

Task Based Development

Well Defined Processes

Page 38: Webinar: "In database automation we trust"

Version control: Integrated & Enforced process

Page 39: Webinar: "In database automation we trust"

Dealing with challenges…

▪Integrated Database Version Control process− Leverage proven version control best practices

• Forcing check in & out for changes• Labels• etc..

− No code-overrides− Always working with the correct revision− All changes are documented− Always know who did what, when, why and from where− No out-of-process changes

▪ No time spent on manual coding of the change scripts

Page 40: Webinar: "In database automation we trust"

1.11.21.31.41.51.61.7

*

Int QA Stage Prod

Database Deploy Script

Environment* Execute the same script being executed at the Stage environment

Re-Base (due to defects)

DevDev

DevModel

1.1 1.2

1.2 1.3

1.3 1.4

1.4 1.5

1.5 1.6

1.6 1.7

1.1 1.4

1.4 1.7

1.1.1 1.7

1.11.1 1.1

1.41.7

File Based Version Control

Out of Process Change

1.1.11.7 1.1.11.7

Validate

Build & deploy on demand

40

Page 41: Webinar: "In database automation we trust"

Using tools

Test cases using compare & sync tools:

An index exists in source (QA) but not in target (Production)

What should we do? Add the index or not?

Page 42: Webinar: "In database automation we trust"

Compare & sync tools

Safe to automate?Sure… (?)

Page 43: Webinar: "In database automation we trust"

Compare & sync tools

Safe to automate?No. Requires manual inspection…

Page 44: Webinar: "In database automation we trust"

Challenges…

Compare & sync tools:

▪ Are great for finding out what is out of sync

▪ Not so great for automating deployments

▪ Requires manual inspection

▪ Requires detailed knowledge regarding each change as part of the process

▪ Is unaware of any changes that occurred before the time it ran

▪ Has no knowledge of changes that took place at the target environment

▪ Unable to deal with conflicts & merges between different teams

Mistrust AGAIN… So…no automation… We fear for automating problems into production and a major risk!!!

Page 45: Webinar: "In database automation we trust"

We need to leverageknowledge from version

control

Page 46: Webinar: "In database automation we trust"

Safety net

Static script based deployment

Page 47: Webinar: "In database automation we trust"

Deploying changes if needed

Development BaselinePrevious Label /

Production Golden Copy

Production

If we had the index in the baseline => we should take it down from production…

(Deploy Change)

Page 48: Webinar: "In database automation we trust"

Or protecting target environment…

Development BaselinePrevious Label /

Production Golden Copy

Production

BUT… If no index in baseline => we should protect the NEW index on production!!!

(Protect Target)

Page 49: Webinar: "In database automation we trust"

Safe?

Simple, right?NO! we are going to BREAK production without even knowing…

Page 50: Webinar: "In database automation we trust"

Dealing with conflicts => merging changes

Page 51: Webinar: "In database automation we trust"

Conflict Resolving – Meta Data/Content

Page 52: Webinar: "In database automation we trust"

Safety Net Deployment Automation

■ Raise red flags on conflicts ■ Support out-of-process changes■ Utilize baseline aware analysis■ Understand the nature of the changes

Source vs. Baseline

Target vs. Baseline

Action

= = No Action

≠ = Deploy Changes

= ≠ Protect Target

≠ ≠ Merge Changes

Page 53: Webinar: "In database automation we trust"

Impact Analysis! not Damage Control…

Raise red flags to stop the line…if requires human intervention

Page 54: Webinar: "In database automation we trust"

Safety Net For Deployment Automation

Database Safe Deployment Automation:• Leverage one source of truth (baselines & previous revisions)

• Flexible scope (deploy multi schema to single task or work item)

• Run as a batch process (repeatable & consistent)

• Integrates to ALM (labels, CRs, Continuous Integration & Delivery)

• Deal with conflicts & merges to match code agility

Can raise red flags to stop the line…if requires human intervention

Page 55: Webinar: "In database automation we trust"

To summarize CD…

•Automate “everything”• Package the deployment of database changes along with all your other application

components to give a unified picture

•Move the process upstream• Easily promote the same package (including database changes!) from one environment to

the next, handling environment-specific differences automatically

•Create the deployment pipeline

Page 56: Webinar: "In database automation we trust"

What is DBmaestro TeamWork?

Page 57: Webinar: "In database automation we trust"

What does DBmaestro offer?Database Enforced Change Management solution

+ Database version control – for structure & content+ Enforce best practices+ Plugs into the ALM (change request, tickets & work items)+ Database merge & change impact analysis+ Know who can do what, where, when & why

DevOps Solution for databases + Baseline aware deployment automation, rollback & recovery+ Reduce database deployment issues+ Plugs into release management & Continuous Delivery

Allows you to package, verify, deploy and promote database changes just as you would do with application code…

putting you in a position to build a full delivery pipeline…

Page 58: Webinar: "In database automation we trust"

58

Change Policy Enforcement – for Oracle

Page 59: Webinar: "In database automation we trust"

59

…and MsSQL

Page 60: Webinar: "In database automation we trust"

60

Impact Analysis & conflict resolution

Page 61: Webinar: "In database automation we trust"

61

Database deployment automation,Database continuous integration & delivery

Page 62: Webinar: "In database automation we trust"

Live Demo

Page 63: Webinar: "In database automation we trust"

Q&A ?

Page 64: Webinar: "In database automation we trust"

Contenuti disponibili su:Canale slideshare di EmerasoftCanale Youtube Emerasoft

What’s next

Contattaci: [email protected] @WWWVisita il nostro sito emerasoft.com

Segui i nostri canali social

Page 65: Webinar: "In database automation we trust"

[email protected]

Emerasoft Srl

via Po, 1 – 10124 Torinovia del Poggio Laurentino, 118 – 00144 Roma

T +39 011 0120370 T +39 06 87811323F +39 011 3710371 

Grazie…

Contatti