pair and mob programming · pair programming • from xp (extreme programming). • part of the...

15
Pair Programming & Mob Programming An Introduc3on

Upload: others

Post on 06-Aug-2020

3 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: Pair and Mob Programming · Pair Programming • From XP (eXtreme Programming). • Part of the technical implementaon of Agile. • Two-developers work on the task together

PairProgramming&

MobProgrammingAnIntroduc3on

Page 2: Pair and Mob Programming · Pair Programming • From XP (eXtreme Programming). • Part of the technical implementaon of Agile. • Two-developers work on the task together

Theclassicway:thelonecoder•  Coderscodeontheirown,inthezone,a

codewarriorontheedgeof3me.•  Othercodersarenotawareofthecodethey

arewri3ng.•  Ifthecodergetsstuckthentheymayspenda

long3metryingtosortoutanissue;theymaybeembarrassedtoaskforhelp.

•  Itthereforehardtomaintainandmeasurecodequality,whichcanleadtoarequirementofcodereviews(oroughtto).

•  Itcancausealackofteamownershipofcode,leadingto“well,Ididn’twritethis,so-and-sodid”.

•  Knowledgesilosarecreatedwhenonlyonedeveloperknowsthecode.Ifapersonleaves,theytaketheirknowledgesilowiththem.

•  Itmakesithardfornewcomerstotheteamtolearn.

Page 3: Pair and Mob Programming · Pair Programming • From XP (eXtreme Programming). • Part of the technical implementaon of Agile. • Two-developers work on the task together

PairProgramming•  FromXP(eXtreme

Programming).•  Partofthetechnical

implementa3onofAgile.•  Two-developersworkon

thetasktogether.•  Oneofthepaircanbreak

offtodosomethingelsethencomebacklater;Thisisespeciallyusefulduringanalysistasks.

Page 4: Pair and Mob Programming · Pair Programming • From XP (eXtreme Programming). • Part of the technical implementaon of Agile. • Two-developers work on the task together

Waystodoitphysically

•  Co-locatedteams,sharingakeyboard,orwithtwokeyboards.

•  RemotelyusingSkypesharingascreen.•  RemotelyusingTeamViewer,orsimilarVNCproduct.

•  Co-locatedteamsworkbestinmyexperience.•  Butpairprogramminghelpskeepremoteworkersfromloosingfocusorslackingoff!

Page 5: Pair and Mob Programming · Pair Programming • From XP (eXtreme Programming). • Part of the technical implementaon of Agile. • Two-developers work on the task together

Waystodoit•  Peopletakeitinturntodrive.•  Thedriverhasthekeyboard,thepassengersitsontheirhands!

•  Swapevery10to20minutes(15isgood).•  Ifonepersonislessexperienced,thenitmaybegoodtoletthemdrivemore;mayhelpenhancetheknowledgetransfer.

•  Forlongertasks,onepersonineachpaircanswap-offthetaskatthenextdayandanothercancomeontoit.Thenextday,theotherswaps-off.

Page 6: Pair and Mob Programming · Pair Programming • From XP (eXtreme Programming). • Part of the technical implementaon of Agile. • Two-developers work on the task together

Results–Benefits•  Knowledgetransferbetweendevelopersiscon3nuous.

Makesiteasiertogetnewbiesuptospeed.•  Greatersenseofteam-ownershipofcode.•  Codequalitymosto_enimproves;bugsgodown.•  Knowledgeisnot3edupinthemindofasinglecoder.•  Problemsaresolvedfasterandmoreefficientlydueto

constantexchangeofideas.•  Swapping-offandontotasksincreasesspreadofknowledge

inteam.•  Itfeelsgood;there’smorehumaninterac3on,andpeople

o_enfeelmoreconfidentaboutthesolu3onstheycreate.

Page 7: Pair and Mob Programming · Pair Programming • From XP (eXtreme Programming). • Part of the technical implementaon of Agile. • Two-developers work on the task together

Results-Downsides•  Itcanbehardtojus3fytomanagement–asitseemslikeusing

twiceasmanyresourcestoachievethesamegoal.•  There’snotalotofevidenceouttheretosupportit;noprecy

graphstoshowmanagement.•  Ifyourtestsuitetakesagestorun,thenitcanseemlikequitea

wasteof3metodopairtestrunnerwatching.•  However,youcanmeasureinyourteamusingcycle3me,burn

downrate,andnumberofbugsfromreleasedcode.•  Ihaveexperiencedsomedeveloperswhofoundit3ringtopairall

the3me;encouragesomebreakingoff,ormoreswapping.•  Ihavealsoexperiencedapairwhoconspiredtodoillasneither

wereconvincedwithAgileprinciples.Oncenotedwecouldensuretheyrarelypairedtogetherandfrequentlyswapped.AlsoseeMobProgramming….

Page 8: Pair and Mob Programming · Pair Programming • From XP (eXtreme Programming). • Part of the technical implementaon of Agile. • Two-developers work on the task together
Page 9: Pair and Mob Programming · Pair Programming • From XP (eXtreme Programming). • Part of the technical implementaon of Agile. • Two-developers work on the task together

MobProgramming•  DefinedbyMosesHohmanand

AndrewSlocumin“ExtremeProgrammingPerspec;ves”(2003)

•  RecentlypopularisedbyWoodyZuillin“MobProgramming:AWholeTeamApproach”(2014).

•  Everyonesharesasinglekeyboard!•  Developerstakeitinturnstodrive.•  Varia3on:thedrivercan’tcontribute•  Co-loca3onisprecymuchamust.•  Developers(andPOs,etc)areableto

dropinandoutfreely.

Page 10: Pair and Mob Programming · Pair Programming • From XP (eXtreme Programming). • Part of the technical implementaon of Agile. • Two-developers work on the task together

Let’swatchavideofromWoodyZuill

Page 11: Pair and Mob Programming · Pair Programming • From XP (eXtreme Programming). • Part of the technical implementaon of Agile. • Two-developers work on the task together

Results•  Totalteam-ownershipofcode.Abilitytosay“wedidthis,wedecidedthat”withconvic3on.

•  Enhancedcodequality,far,farfewerbugs.•  Knowledgetransfertoallteammembers(toatleastsomedegree).

•  Canhelpiden3fyknowledgesilos.•  Inmyexperienceitdoesn’tactuallyslowateamdown,remarkably.Anyslowdowncanbejus3fiedbyresul3ngcodequality.

•  Eliminatesconspiracies-to-do-bad;well,ifthewholeteamagreestotheconspiracy,thenyou’reprecymuchsunk!

Page 12: Pair and Mob Programming · Pair Programming • From XP (eXtreme Programming). • Part of the technical implementaon of Agile. • Two-developers work on the task together

Mobprogramming-downsides

•  Whateveryoudo,don’ttelltheFD!(atleastnotun3lyouhaveproofitworks).

•  Remoteworkersarehardtointegrate.•  Notthatgoodforinves3ga3onandanalysis.•  Notthatgoodfordevops/sysadmintasks;pairingworksbecerforthis.

•  Willmostlikelyini3allyaffectyourthroughputasitreducesyourteam’sWIPlimittoone.

Page 13: Pair and Mob Programming · Pair Programming • From XP (eXtreme Programming). • Part of the technical implementaon of Agile. • Two-developers work on the task together

Andnotjustprogramming…

•  Analysis•  Backloggrooming•  Tes3ng•  Systemsadministra3on/DevOps•  Repor3ng•  Diggingholesintheroad(mobdigginghasbeenusedforthisformanyyearsalready).

Page 14: Pair and Mob Programming · Pair Programming • From XP (eXtreme Programming). • Part of the technical implementaon of Agile. • Two-developers work on the task together

Andremembertoalso…•  Keepthestoriesshort.•  Focusonthewhat,whyand

forwhom,notthehow.•  Dotest-driven

development.•  WriteCLEANcode.•  Usedesignpacerns.•  Refactoro_en.•  Nurturerespectamongst

yourteammembers.•  Sitonyourhandsifyou

can’tkeepthemoffthekeyboard.

Page 15: Pair and Mob Programming · Pair Programming • From XP (eXtreme Programming). • Part of the technical implementaon of Agile. • Two-developers work on the task together

Thankyou.07811671893

[email protected]

hcp://leanbytes.co.ukhcps://mbharris.co.uk

hcp://uk.linkedin.com/in/mbharrishcps://github.com/mikebharris/