Feature branches and toggles in a post-GitHub world GOTO Chicago 2017 Sam Newman
@gotochi @samnewman
Sam Newman & Associates @gotochi @samnewman
Sam Newman & Associates (there are no associates) @gotochi @samnewman
Building Microservices DESIGNING FINE - GRAINED SYSTEMS Sam Newman @gotochi @samnewman
2004 @gotochi @samnewman
@gotochi @samnewman
@gotochi @samnewman
Coventry Arena Coventry Long Buckby Bedford Rugby Bedford St Johns Northampton Kempston Hardwick Stewartby Millbrook to Luton Lidlington St Albans Ridgmont Wolverton London St P Aspley Guise Leamington Woburn Sands Spa Milton Keynes Bow Brickhill Central Fenny Stratford k Bletchley Leighton Buzzard Cheddington St Albans Abbey Tring Berkhamsted Park Street to How Wood Hemel Hempstead Banbury Bricket Wood Apsley Oxford Reading Garston Kings Langley High Wycombe Watford North London Marylebone Watford Junction Bushey Harrow & Wealdstone Wembley Central London Euston @gotochi @samnewman
Coventry Arena Coventry Long Buckby Bedford Rugby Bedford St Johns Northampton Kempston Hardwick Stewartby Millbrook to Luton Lidlington St Albans Ridgmont Wolverton London St P Aspley Guise Leamington Woburn Sands Spa Milton Keynes Bow Brickhill Central Fenny Stratford k Bletchley Leighton Buzzard Cheddington St Albans Abbey Tring Berkhamsted Park Street to How Wood Hemel Hempstead Banbury Bricket Wood Apsley Oxford Reading Garston Kings Langley High Wycombe Watford North London Marylebone Watford Junction Bushey Harrow & Wealdstone Wembley Central London Euston @gotochi @samnewman
Coventry Arena Coventry Long Buckby Bedford Rugby Bedford St Johns Northampton Kempston Hardwick Stewartby Millbrook to Luton Lidlington St Albans Ridgmont Wolverton London St P Aspley Guise Leamington Woburn Sands Spa Milton Keynes Bow Brickhill Central Fenny Stratford k Bletchley Leighton Buzzard Cheddington St Albans Abbey Tring Berkhamsted Park Street to How Wood Hemel Hempstead Banbury Bricket Wood Apsley Oxford Reading Garston Kings Langley High Wycombe Watford North London Marylebone Watford Junction Bushey Harrow & Wealdstone Wembley Central London Euston @gotochi @samnewman
Coventry Arena Coventry Long Buckby Bedford Rugby Bedford St Johns Northampton Kempston Hardwick Stewartby Millbrook to Luton Lidlington St Albans Ridgmont Wolverton London St P Aspley Guise Leamington Woburn Sands Spa Milton Keynes Bow Brickhill Central Fenny Stratford k Bletchley Leighton Buzzard Cheddington St Albans Abbey Tring Berkhamsted Park Street to How Wood Hemel Hempstead Banbury Bricket Wood Apsley Oxford Reading Garston Kings Langley High Wycombe Watford North London Marylebone Watford Junction Bushey Harrow & Wealdstone Wembley Central London Euston @gotochi @samnewman
R3 @gotochi @samnewman
R3 @gotochi @samnewman
R3 R4 @gotochi @samnewman
R3 R4 @gotochi @samnewman
R3 R4 @gotochi @samnewman
R3 R4 @gotochi @samnewman
R3 R4 @gotochi @samnewman
https://www.flickr.com/photos/jubilo/6965626176/ @gotochi @samnewman
R3-R4 Merge Bug Fix Team @gotochi @samnewman
R3-R4 Merge Bug Fix Team yay @gotochi @samnewman
@gotochi @samnewman
Continuous Integration @gotochi @samnewman
@gotochi @samnewman
@gotochi @samnewman
CI Tool @gotochi @samnewman
� CI Tool @gotochi @samnewman
� � CI Tool @gotochi @samnewman
@gotochi @samnewman
@gotochi @samnewman
� @gotochi @samnewman
� � @gotochi @samnewman
1. Validate the integration � � @gotochi @samnewman
1. Validate the integration � � � @gotochi @samnewman
1. Validate the integration 2. When the build breaks, fix it! � � � @gotochi @samnewman
1. Validate the integration 2. When the build breaks, fix it! � � � � @gotochi @samnewman
1. Validate the integration 2. When the build breaks, fix it! … � � � � @gotochi @samnewman
1. Validate the integration 2. When the build breaks, fix it! … � � � � @gotochi @samnewman
1. Validate the integration 2. When the build breaks, fix it! … � � � � � � � � @gotochi @samnewman
1. Validate the integration 2. When the build breaks, fix it! 3. Integrate daily … � � � � � � � � @gotochi @samnewman
R3 R4 @gotochi @samnewman
R3 � � � R4 @gotochi @samnewman
R3 � � � � � � R4 @gotochi @samnewman
R3 � � � � � � R4 @gotochi @samnewman
Integrate Once A Day @gotochi @samnewman
How can you deal with half-finished work? @gotochi @samnewman
Option 1: @gotochi @samnewman
Option 1: Wait to check in @gotochi @samnewman
Option 2: @gotochi @samnewman
Option 2: Make a branch! @gotochi @samnewman
Trunk @gotochi @samnewman
Trunk @gotochi @samnewman
F1 Trunk @gotochi @samnewman
F1 Trunk @gotochi @samnewman
F1 Trunk @gotochi @samnewman
F1 Trunk F2 @gotochi @samnewman
F1 Trunk F2 @gotochi @samnewman
F1 Trunk F2 @gotochi @samnewman
F1 Trunk F2 @gotochi @samnewman
F1 Trunk F2 @gotochi @samnewman
F1 Trunk F2 we are deferring integration! @gotochi @samnewman
Pain of merge = fn ( size_of_merge, duration_since_last_merge) @gotochi @samnewman
Big merges = commit race! @gotochi @samnewman
Merging refactoring is *really* hard @gotochi @samnewman
Option 3: @gotochi @samnewman
Option 3: Check in anyway @gotochi @samnewman
Option 3: Check in anyway err…wat? @gotochi @samnewman
Trunk-based development @gotochi @samnewman
Everyone integrates into trunk @gotochi @samnewman
Trunk @gotochi @samnewman
Trunk @gotochi @samnewman
integrate often… Trunk @gotochi @samnewman
integrate often… …fast feedback… Trunk @gotochi @samnewman
integrate often… …fast feedback… …break up merge pain Trunk @gotochi @samnewman
integrate often… …fast feedback… …break up merge pain Trunk err…but what about half-finished features? @gotochi @samnewman
Feature Toggles @gotochi @samnewman
Feature Toggles Hide the partially implemented feature in the running system @gotochi @samnewman
… super_widget = off … @gotochi @samnewman
… … super_widget = off super_widget = on … … @gotochi @samnewman
… … super_widget = off super_widget = on … … super widget! @gotochi @samnewman
… … super_widget = off super_widget = on … … $. run -Dsuper_widget=on super widget! @gotochi @samnewman
… … super_widget = off super_widget = on … … $. run -Dsuper_widget=on super widget! @gotochi @samnewman
But what about changes to existing functionality? @gotochi @samnewman
@gotochi @samnewman
Hypersonic Persistence Hypersonic @gotochi @samnewman
Hypersonic Persistence Hypersonic Postgres @gotochi @samnewman
Hypersonic Persistence Hypersonic Postgres @gotochi @samnewman
Hypersonic Persistence shipping every two weeks… Hypersonic Postgres @gotochi @samnewman
Hypersonic Generic SQL Persistence Persistence shipping every two weeks… Hypersonic Postgres @gotochi @samnewman
Persistence Interface Hypersonic Generic SQL Persistence Persistence shipping every two weeks… Hypersonic Postgres @gotochi @samnewman
Persistence Interface Hypersonic Generic SQL Persistence Persistence shipping every two weeks… Hypersonic Postgres @gotochi @samnewman
Persistence Interface Hypersonic Generic SQL Persistence Persistence shipping every two weeks… Hypersonic Postgres @gotochi @samnewman
Persistence Interface Hypersonic Generic SQL Persistence Persistence shipping every two weeks… Hypersonic Postgres @gotochi @samnewman
Persistence Interface Hypersonic Generic SQL Persistence Persistence shipping every two weeks… Hypersonic Postgres @gotochi @samnewman
Persistence Interface Generic SQL Persistence shipping every two weeks… Postgres @gotochi @samnewman
@gotochi @samnewman
Feature Branching @gotochi @samnewman
Feature Branching Branch-by abstraction @gotochi @samnewman
Important Rules: @gotochi @samnewman
Recommend
More recommend