Slide 1

Slide 1 text

Continuous Integration with Trunk-based & Feature Toggle @aziziyazit DEV OPS Code Plan Test Release O perate Monitor

Slide 2

Slide 2 text

Continuous Integration (CI) Continuous delivery Continuous integration integrate integrate integrate 1x 2x 4x automated build DEV OPS Code Plan Test Release O perate Monitor 1 day

Slide 3

Slide 3 text

Trunk-based Development (TBD) Continuous delivery Continuous integration merge merge merge 1 PR 2 PR’s 4 PR’s trunk 1 day short-lived branches

Slide 4

Slide 4 text

Trunk-Based Development (TBD) Trunk-Based Development is a key enabler of Continuous Integration DEV OPS Code Plan Test Release O perate Monitor

Slide 5

Slide 5 text

Trunk-based strategies Branch by Abstraction Use branch-by-abstraction to make complex or larger scale changes to to your application incrementally while keeping the system working.

Slide 6

Slide 6 text

Trunk-based strategies Branch by Abstraction TypographyComponent TextfieldComponent ButtonComponent LinkComponent

Slide 7

Slide 7 text

Trunk-based strategies Branch by Abstraction button branch trunk register page branch textfield branch component, test & storybook component, test & storybook PR new branch new branch new branch PR pull from mainline pull from mainline PR

Slide 8

Slide 8 text

Trunk-based strategies Branch by Abstraction button branch trunk register page branch textfield branch PR new branch new branch new branch PR pull from mainline pull from mainline PR component, test & storybook component, test & storybook component as abstraction

Slide 9

Slide 9 text

button branch trunk register page branch textfield branch component, test & storybook component, test & storybook PR PR pull from mainline pull from mainline PR new branch new branch Trunk-based strategies Branch by Abstraction new branch Short-lived branches

Slide 10

Slide 10 text

button branch trunk register page branch textfield branch component, test & storybook component, test & storybook new branch new branch new branch PR Trunk-based strategies Branch by Abstraction PR PR pull from mainline pull from mainline Concurrent development Small commit - continuous code review

Slide 11

Slide 11 text

Trunk-based strategies Feature Toggle Feature Toggles are a powerful technique, allowing teams to modify system behavior without changing code. martinfowler.com

Slide 12

Slide 12 text

Trunk-based strategies Feature Toggle using Angular APP_ INITIALIZER APP STATE images taken from flaticon.com Feature Flag Directive App true false true true

Slide 13

Slide 13 text

Trunk-based strategies Feature Toggle using Angular { “featureA”: true, “featureB”: false, “featureC”: true, “featureD”: false, } Feature Flags
this will be shown this will be hide https://dev.to/ngconf/feature-flags-in-angular-3ic7

Slide 14

Slide 14 text

{ “featureA”: true, “featureB”: false, “featureC”: true, “featureD”: false, } Feature Flags
this will be hide https://dev.to/ngconf/feature-flags-in-angular-3ic7 Trunk-based strategies Feature Toggle using Angular
this will be shown
this will be shown “featureA”: true

Slide 15

Slide 15 text

Trunk-based strategies Feature Toggle trunk releases feature A branch MVP 1.0 flag off MVP 1.1 flag on flag removed MVP 2.0 feature A feature A feature B branch pull from mainline

Slide 16

Slide 16 text

trunk releases feature A branch MVP 1.0 flag on flag removed MVP 2.0 feature A feature B branch commit to trunk at least once every 24 hours codebase is always releasable on demand and helps to make Continuous Delivery a reality Trunk-based strategies Feature Toggle flag off MVP 1.1 feature A pull from mainline

Slide 17

Slide 17 text

Summary Continuous integration complementing Agile and Trunk-based is the key enabler for Continuous integration. They are supporting each other to accomplish the goal to speed up the time to ship the product to customers as early as possible. Team should adapt techniques like branch-by- abstraction and feature toggles in day to day development to allow smooth and safe code integration.