58
Release and Dependency Management Joe Ferguson

Release and-dependency-management memphis python

Embed Size (px)

Citation preview

Page 1: Release and-dependency-management memphis python

Release and Dependency Management

Joe Ferguson

Page 2: Release and-dependency-management memphis python

This is not a Code Talk

Page 3: Release and-dependency-management memphis python

What’s “Scale”?

Page 4: Release and-dependency-management memphis python

“At Scale”

http://www.pcmag.com/encyclopedia/term/68176/at-scale

“…at the required size to solve the problem…”

Page 5: Release and-dependency-management memphis python

What’s “Enterprise”?

http://www.pcmag.com/encyclopedia/term/42637/enterprise

Any undertaking or project, with the implication that it is of reasonable size

and complexity.

Page 6: Release and-dependency-management memphis python

Everyone is at “Enterprise” “Scale”

Page 7: Release and-dependency-management memphis python

Brands

Page 8: Release and-dependency-management memphis python

http://corp.aol.com/mission

Page 9: Release and-dependency-management memphis python

Enterprise === A lot

http://hyperboleandahalf.blogspot.com/2010/04/alot-is-better-than-you-at-everything.html

Page 10: Release and-dependency-management memphis python

We’re a small(ish) team

2 Front End Devs

6 Back end Devs

1 Architect / Product Manager

1 Manager

Page 11: Release and-dependency-management memphis python

Foundation of our Applications

Modern*

Well Tested

Semantic Versioning

Peer Approval

Continuous Integration

Client Focused Solutions

Page 12: Release and-dependency-management memphis python

Our CMS Application

Page 13: Release and-dependency-management memphis python

Start with a strong version control process/strategy

Page 14: Release and-dependency-management memphis python

New Feature Git Workflow

Pull master branch

Page 15: Release and-dependency-management memphis python

New Feature Git Workflow

Pull master branch

checkout new branch named feature/new-feature-description

Page 16: Release and-dependency-management memphis python

New Feature Git Workflow

Pull master branch

checkout new branch named feature/new-feature-description

change code <where the magic happens>

Page 17: Release and-dependency-management memphis python

New Feature Git Workflow

Pull master branch

checkout new branch named feature/new-feature-description

change code <where the magic happens>

Commit changes and open pull request against the develop branch

Page 18: Release and-dependency-management memphis python

New Feature Git Workflow

Pull master branch

checkout new branch named feature/new-feature-description

change code <where the magic happens>

Commit changes and open pull request against the develop branch

Wait for two peers to approve changes <jeopardy theme plays>

Page 19: Release and-dependency-management memphis python

New Feature Git Workflow

Pull master branch

checkout new branch named feature/new-feature-description

change code <where the magic happens>

Commit changes and open pull request against the develop branch

Wait for two peers to approve changes <jeopardy theme plays>

Merge pull request into the develop branch

Page 20: Release and-dependency-management memphis python

Commit & Versioning Tools

Page 21: Release and-dependency-management memphis python

Emoji in your commits!

https://github.com/slashsBin/styleguide-git-commit-message

Page 22: Release and-dependency-management memphis python

Commit tool to automate messages

https://github.com/jakeasmith/commit

Page 23: Release and-dependency-management memphis python

export GIT_EDITOR=~/PhpstormProjects/commit/bin/commit

Page 24: Release and-dependency-management memphis python

Commit tool to automate messages

https://github.com/jakeasmith/commit

Page 25: Release and-dependency-management memphis python

Identify What Changed

Page 26: Release and-dependency-management memphis python

Bump!

https://github.com/jakeasmith/bump

Page 27: Release and-dependency-management memphis python

$ bump major|minor|patch

Page 28: Release and-dependency-management memphis python

Wait for package repo to index new version

Page 29: Release and-dependency-management memphis python

Deployment Cycles, Waterfalls, Sprints, Kanban, and bears oh my!

Page 30: Release and-dependency-management memphis python

Find what works for you

Page 31: Release and-dependency-management memphis python

Kanban

Two Week Release Cycle

Page 32: Release and-dependency-management memphis python

Code Freeze and Release Branches

Two Week Release Cycle

Wednesday before release is a Release Candidate Code Freeze

Release branches are created from develop branch

Release branches deployed to staging servers

Page 33: Release and-dependency-management memphis python

Testing on Staging Servers

Two Week Release Cycle

Wednesday before release is a Release Candidate Code Freeze

Release branches are created from develop branch

Release branches deployed to staging servers

Developers & Clients test changes on staging servers & sign off

From Wednesday to Tuesday is testing time

Page 34: Release and-dependency-management memphis python

Production DeploymentTwo Week Release Cycle

Wednesday before release is a Release Candidate Code Freeze

Release branches are created from develop branch

Release branches deployed to staging servers

Developers & Clients test changes on staging servers & sign off

From Wednesday to Tuesday is testing time

Tuesday following the RC freeze is production deploy

Release branches are Merged into master via same 2 peer approval pull request process

Page 35: Release and-dependency-management memphis python

Production DeploymentTwo Week Release Cycle

Wednesday before release is a Release Candidate Code Freeze

Release branches are created from develop branch

Release branches deployed to staging servers

Developers & Clients test changes on staging servers & sign off

From Wednesday to Tuesday is testing time

Tuesday following the RC freeze is production deploy

Release branches are Merged into master via same 2 peer approval pull request process

Code is deployed to production

Page 36: Release and-dependency-management memphis python

When something breaks…

Page 37: Release and-dependency-management memphis python

Hotfixes and Bugfixes

Hotfixes are branches named hotfix/description that are opened against master

Hotfixes are how we patch production

Page 38: Release and-dependency-management memphis python

Hotfixes and Bugfixes

Hotfixes are branches named hotfix/description that are opened against master

Hotfixes are how we patch production

Bug fixes are when we find issues after the RC freeze but before RC branch merging to master

Bug fix branches are named bugfix/description that are opened against the release branch

Page 39: Release and-dependency-management memphis python

That’s how we deploy features to our CMS

Page 40: Release and-dependency-management memphis python

Our CI/CD Hero

Page 41: Release and-dependency-management memphis python

Jenkins Automation

Build & Run Tests

Build Docker Images & Test

Build & Deploy Applications

Sound the alarms when something breaks

Slack Notifications in a CI/CD Channel

Page 42: Release and-dependency-management memphis python

That’s how we deploy features to our CMS, API,

Page 43: Release and-dependency-management memphis python

That’s how we deploy features to our CMS, API, Design Tool,

Page 44: Release and-dependency-management memphis python

That’s how we deploy features to our CMS, API, Design Tool, and other standalone applications

Page 45: Release and-dependency-management memphis python

Architecture

CMS

API

Design Tool

A lot of shared logic

Page 46: Release and-dependency-management memphis python

Enter: “Core”

Page 47: Release and-dependency-management memphis python

Architecture

CMS

API

Design Tool

Core

Page 48: Release and-dependency-management memphis python

composer require aol/core

*not the actual package name

Page 49: Release and-dependency-management memphis python

Control Version Constraints

{ "require": { "aol/core": "^17", }}

Page 50: Release and-dependency-management memphis python

Lock To A Minor Version

{ "require": { "aol/core": “^17.10", }}

Page 51: Release and-dependency-management memphis python

We now have access to all of the logic in Core in all of our applications

Page 52: Release and-dependency-management memphis python

Core Git Workflow

No develop branch

No Hotfixes, or Bugfix branches

All changes are via pull request against master

After PRs are approved and merged version tags are bumped

Semantic versioning is your friend

Individual applications update their own core versions at their own pace (During normal deployment cycles)

Page 53: Release and-dependency-management memphis python

Architecture

CMS

API

Design Tool

Core

Version 15.1.3

Version 17.6.13

Version 17.0.0

Page 54: Release and-dependency-management memphis python

Remember Scale?

Page 55: Release and-dependency-management memphis python

Core is just another application…

Page 56: Release and-dependency-management memphis python

“Compromise is essential because there are no ideal solutions, only

trade-offs”

Thomas Sowell - “A Conflict of Vision”

Page 57: Release and-dependency-management memphis python

Follow your process

Page 58: Release and-dependency-management memphis python

Joe FergusonTwitter: @JoePFergusonEmail: [email protected]: joepferguson

Contact Info: