30
Introduction into Extreme Programming Audrys Kažukauskas [email protected]

Audrys Kažukauskas - Introduction into Extreme Programming

Embed Size (px)

DESCRIPTION

Extreme Programming might not be a silver bullet, but in software development it is almost that. Managers get all the bells and whistles you would expect from an agile process, whilst developers are equipped with a set of principles and practices, which almost inevitably improve the codebase and enable frequent delivery of quality software. In fact, many teams, which use other software development processes (Scrum, for instance) eventually end up adopting quite a few XP practices. I'll give you an introduction into XP, share my experiences and provide references to XP material for learning more about XP.

Citation preview

Page 1: Audrys Kažukauskas - Introduction into Extreme Programming

Introduction into Extreme Programming

Audrys Kaž[email protected]

Page 2: Audrys Kažukauskas - Introduction into Extreme Programming

What is XP?

• Agile software development methodology

• Cares about customers, managers and developers

Page 3: Audrys Kažukauskas - Introduction into Extreme Programming

Consider XP if

• Code is a mess, many bugs, integration problems

• Releases cause lots of stress

• Difficult to release more frequently

• Difficult to add new functionality

• Testing takes too long

Page 4: Audrys Kažukauskas - Introduction into Extreme Programming

or... if you use Scrum :)

Page 5: Audrys Kažukauskas - Introduction into Extreme Programming

AS - Adequately Satisfied PS - Partially SatisfiedNS - Not Satisfied

Comparing XP and Scrum

AttributesXPXPXP ScrumScrumScrum

AttributesAS PS NS AS PS NS

Software Requirements 60% 40% 0% 60% 20% 20%

Construction of Software 75% 25% 0% 0% 0% 100%

Software Testing 100% 0% 0% 0% 0% 100%

Software Engineering Management 80% 0% 20% 80% 20% 0%

Agile Principles - Proposed Practices relation 75% 8% 17% 50% 17% 33%

J.M. Fernandes and M. Almeida, "Classification and Comparison of Agile Methods", ;in Proc. QUATIC, 2010, pp.391-396.

Page 6: Audrys Kažukauskas - Introduction into Extreme Programming

What is special about XP?

• XP practices

• Emphasis on simplicity, quality and testing

• Can keep cost of change low

Page 7: Audrys Kažukauskas - Introduction into Extreme Programming

Cost of change

Cost of change

Time

Traditional

XP

sweet promise :)

Page 8: Audrys Kažukauskas - Introduction into Extreme Programming

XP practices

Test Driven Development

PairProgramming

ContinuousIntegration

Stories

Slack

Simple Design

Refactoring

Energized work

Sit Together

Weekly Cycle

Quarterly Cycle

Informative Workspace

WholeTeam

Page 9: Audrys Kažukauskas - Introduction into Extreme Programming

Some XP practices aren’t very special

Page 10: Audrys Kažukauskas - Introduction into Extreme Programming

Some general agile stuff

• practice Stories

• practice Weekly Cycle

• practice Quarterly Cycle

• practice Informative Workspace

Page 11: Audrys Kažukauskas - Introduction into Extreme Programming

Whole Team

• Cross-functional team

• We belong

• We are in this together

• We support each others’ work, growth, and learning

Page 12: Audrys Kažukauskas - Introduction into Extreme Programming

Sit Together

• Put team in one open room

• Communication!

Page 13: Audrys Kažukauskas - Introduction into Extreme Programming

Show me the money!

Page 14: Audrys Kažukauskas - Introduction into Extreme Programming

Simple Design

• Do the Simplest Thing that Could Possibly Work

• You Aren’t Going to Need It (YAGNI)

• Simplicity according to Kent Beck:• Runs all the tests

• Reveals all the intention

• No duplication

• Fewest number of classes or methods

Page 15: Audrys Kažukauskas - Introduction into Extreme Programming

Test Driven Development

• Tests as specification rather than verification

• Test before code or test after code?

• Red, green, refactor

Page 16: Audrys Kažukauskas - Introduction into Extreme Programming

Hierarchy of tests

Unit tests

Integration tests

Acceptancetests

Slower

Faster

Fewer

More

Page 17: Audrys Kažukauskas - Introduction into Extreme Programming

Refactoring

• Refactoring is a disciplined technique for restructuring an existing body of code, altering its internal structure without changing its external behavior {Martin Fowler}

• Keeps codebase in optimal state

• Removes technical debt

• Hardly possible without automated tests

Page 18: Audrys Kažukauskas - Introduction into Extreme Programming

Continuous Integration

• Integrate changes every couple of hours

• Fast feedback: 10-minute build!

• Split big product into multiple builds by component

• Parallel builds and more hardware to reduce build time

Page 19: Audrys Kažukauskas - Introduction into Extreme Programming

10-minute build!

10 min.

10 min.

10 min.10 min.

10 min.

10 min.

10 min.10 min.

10 min.

10 min.

10 min.

10 min.

Page 20: Audrys Kažukauskas - Introduction into Extreme Programming

Pair Programming

• Better code, less bugs, know-how sharing

•Driving and navigating

• Avoid teacher/student situation

• Personal hygiene!

Page 21: Audrys Kažukauskas - Introduction into Extreme Programming

Energized Work

• Maintain productivity for an indefinite interval of time

• Limited working hours

Page 22: Audrys Kažukauskas - Introduction into Extreme Programming

Slack

• [Dictionary definition: lacking in activity; not busy: a slack season for the travel business.]

•Deliver what you promise!

• Include minor tasks into iteration, which can be dropped out

• Include refactorings, researches or HackWeeks

Page 23: Audrys Kažukauskas - Introduction into Extreme Programming

Key practices of XP

Test Driven Development

PairProgramming

ContinuousIntegration

Stories

Slack

Simple Design

Refactoring

Energized work

Sit Together

Weekly Cycle

Quarterly Cycle

Informative Workspace

WholeTeam

Page 24: Audrys Kažukauskas - Introduction into Extreme Programming

Keep cost of change low

Cost of change

Time

Traditional

XP

enabled by TDD, CI and Refactoring

Page 25: Audrys Kažukauskas - Introduction into Extreme Programming

But I don’t hear much about XP recently...

Page 26: Audrys Kažukauskas - Introduction into Extreme Programming

What’s happened

• Agile is mainstream, hence abused

• Agile = Scrum problem

• XP is often combined with Scrum, but not mentioned explicitly

• Nevertheless, XP is alive and kicking! :)

Page 27: Audrys Kažukauskas - Introduction into Extreme Programming

Starting from scratch?

• Start with XP. It will take you further

• You don’t have to use all XP practices

• If you start with Scrum, borrow technical XP practices

Page 28: Audrys Kažukauskas - Introduction into Extreme Programming

Shape it your way!

• Always remember - Agile is about people over processes

•None of the processes is a silver bullet

• Combine the best of XP, Scrum, Lean - whatever works for you and your team

Page 29: Audrys Kažukauskas - Introduction into Extreme Programming

Further readings

• Kent Beck, Cynthia Andres. Extreme Programming Explained: Embrace Change, Addison-Wesley, 2nd edition.

• Kent Beck, Martin Fowler. Planning Extreme Programming, Addison-Wesley

• James Shore, Shane Warden. The Art of Agile Development, O’Reilly (some chapters available online jamesshore.com/Agile-Book/)

• Martin Fowler’s website has lots of goodies martinfowler.com