23
Amir Barylko - CI MavenThought Inc. AMIR BARYLKO CONTINUOUS INTEGRATION WITH TEAMCITY CODE PALOUSA MARCH 2012

Cpl12 continuous integration

Embed Size (px)

Citation preview

Page 1: Cpl12 continuous integration

Amir Barylko - CI MavenThought Inc.

AMIR BARYLKO

CONTINUOUS INTEGRATION

WITH TEAMCITY

CODE PALOUSAMARCH 2012

Page 2: Cpl12 continuous integration

Amir Barylko - CI MavenThought Inc.

WHO AM I?• Quality Expert

• Architect

• Developer

• Mentor

• Great cook

• The one who’s entertaining you for the next hour!

Page 3: Cpl12 continuous integration

Amir Barylko - CI MavenThought Inc.

RESOURCES• Email: [email protected]

• Twitter : @abarylko

• Blog: http://orthocoders.com

• Materials: http://bit.ly/orthoslides

Page 4: Cpl12 continuous integration

Amir Barylko - CI MavenThought Inc.

INTROWhat is CI?

Who needs CI?How to start

Page 5: Cpl12 continuous integration

Amir Barylko - CI MavenThought Inc.

WHAT IS CI?•Development methodology that aims to

•Automate building process

•Verify sanity of each build

•Automate unit, integration and acceptance testing

•Placeholder for other tools

Page 6: Cpl12 continuous integration

Amir Barylko - CI MavenThought Inc.

WHY DO YOU NEED CI?• Make sure the build is not broken

• Catch failing test sooner than later

• Generate nightly builds

• Deploy automatically

• Deploy with one click

• Run extra tools (static analysis, code coverage, etc)

Page 7: Cpl12 continuous integration

Amir Barylko - CI MavenThought Inc.

HOW TO START• Automate your process/tasks with a script

• Install a CI server (TeamCity, Jenkins, etc...)

• Create basic build and testing

• Add visible notifications

• Add deployment

• Add other tools like static analysis, etc...

Page 8: Cpl12 continuous integration

Amir Barylko - CI MavenThought Inc.

USING TEAM CITYIn a nutshell

Architecture OverviewSource Control

Build AgentsNotifications

Page 9: Cpl12 continuous integration

Amir Barylko - CI MavenThought Inc.

IN A NUTSHELL• Build automation and management server

• Team communication

• Platform agnostic

• Free professional version with 20 projects and 3 agents

Page 10: Cpl12 continuous integration

Amir Barylko - CI MavenThought Inc.

ARCHITECTURE OVERVIEW

Page 11: Cpl12 continuous integration

Amir Barylko - CI MavenThought Inc.

SOURCE CONTROL• Many providers: Git, Hg, SVN, TFS, CVS, VSS, etc....

• Build trigger rules to detect changes

• Labelling

Page 12: Cpl12 continuous integration

Amir Barylko - CI MavenThought Inc.

BUILD AGENTS• Each agent can run in a different system/environment

• Concurrent build

• Real-time results

• Dedicated agents for particular tasks (like slow tests)

Page 13: Cpl12 continuous integration

Amir Barylko - CI MavenThought Inc.

NOTIFICATIONS• Rich and friendly web interface

• Notifiers using email, jabber, tray, etc...

• HTML widget status

Page 14: Cpl12 continuous integration

Amir Barylko - CI MavenThought Inc.

DEMOCommons Project

BuildTest

Nightly buildDeployTools

Page 15: Cpl12 continuous integration

Amir Barylko - CI MavenThought Inc.

SUMMARYAutonomous Build

Iteration 0Success TipsNext Steps

Page 16: Cpl12 continuous integration

Amir Barylko - CI MavenThought Inc.

AUTONOMOUS BUILD• Build with the minimum amount of tools

• Store necessary tools with the projects (if possible)

• Avoid storing binaries libraries/assemblies in repository

• Avoid storing artifacts that can be generated

Page 17: Cpl12 continuous integration

Amir Barylko - CI MavenThought Inc.

ITERATION 0• Flush out architecture.

• Setup Testing harness for TDD and BDD.

• Setup continuous integration.

• Setup scripts to build, deploy, etc.

• Setup visual communication tools.

Page 18: Cpl12 continuous integration

Amir Barylko - CI MavenThought Inc.

SUCCESS TIPS• Commit often (in your branch)

• Make sure you run builds and tests before committing

• Fix build failures immediately

• Fail fast

• Act on metrics

• Build on every target environment

• Create artifacts for every build

Page 19: Cpl12 continuous integration

Amir Barylko - CI MavenThought Inc.

NEXT STEPS• Build automatically per branch

• Let your clients deploy

• Shelving commits

• Discover static analysis tools

Page 20: Cpl12 continuous integration

Amir Barylko - CI MavenThought Inc.

QUESTIONS?

Page 21: Cpl12 continuous integration

Amir Barylko - CI MavenThought Inc.

RESOURCES• Email: [email protected]

• Twitter : @abarylko

• Materials: http://bit.ly/orthoslides

Page 22: Cpl12 continuous integration

Amir Barylko - CI MavenThought Inc.

RESOURCES II

Page 23: Cpl12 continuous integration

Amir Barylko - CI MavenThought Inc.

SOFTWARE QUALITY WORKSHOP

• When: May 4, 10-11 & 16-17

• More info: http://www.maventhought.com

• Goal: Learn Kanban, BDD & TDD to improve the quality of your day to day job.