Your SlideShare is downloading. ×

DVCS: Making the move? How Atlassian can help...

1,116

Published on

Published in: Technology, Education
0 Comments
0 Likes
Statistics
Notes
  • Be the first to comment

  • Be the first to like this

No Downloads
Views
Total Views
1,116
On Slideshare
0
From Embeds
0
Number of Embeds
2
Actions
Shares
0
Downloads
18
Comments
0
Likes
0
Embeds 0
No embeds

Report content
Flagged as inappropriate Flag as inappropriate
Flag as inappropriate

Select your reason for flagging this presentation as inappropriate.

Cancel
No notes for slide
  • “you might be thinking”\n
  • “you might be thinking”\n
  • “you might be thinking”\n
  • “you might be thinking”\n
  • “you might be thinking”\n
  • “you might be thinking”\n
  • “you might be thinking”\n
  • “you might be thinking”\n
  • “you might be thinking”\n
  • “you might be thinking”\n
  • “you might be thinking”\n
  • “you might be thinking”\n
  • “you might be thinking”\n
  • Intro: \nAdvantages of DVCS (git & hg/mercurial) compared to Traditional VCS\nWhat we’ve learned about DVCS\nOptions for migrating and our migration\nEnd up thinking migrating to DVCS is awesome idea\nDrop nuggets along the way\n?What VCS’s using now?\n?Migrated? Thinking of Migrating?\n
  • Momentum\n
  • What do we know is good?\nWork Offline (local commits), easy to create new repo, faster\nEasier branching and merging “apparently”: Who branches in SVN?\nforks, pull request, OS stuff - new models\n
  • Distributed:\npush when you want - commit often\ncreate local repos, push to others\nfast, fast history\ndefine clones?\nclones or branches, more flexibility - new workflows (more later)\nNothing compelling yet?\n
  • * Important: This is what we discovered\n* SVN/CVS: Linear, concurrent changes\n* DAG: Commits built on parent commits - uniquely identified - new commits made by one author only - concurrent commits are merged\n* demonstrate\n
  • * Linear\n* Overlap unintentionally\n
  • * Linear\n* Overlap unintentionally\n
  • * Linear\n* Overlap unintentionally\n
  • Unintended state\nCI was invented to deal with this\n
  • Contrast to in SVN, changes made at same time, but appear as logical progression\nDVCS: Commits build on a known state\n
  • Contrast to in SVN, changes made at same time, but appear as logical progression\nDVCS: Commits build on a known state\n
  • Contrast to in SVN, changes made at same time, but appear as logical progression\nDVCS: Commits build on a known state\n
  • Contrast to in SVN, changes made at same time, but appear as logical progression\nDVCS: Commits build on a known state\n
  • Contrast to in SVN, changes made at same time, but appear as logical progression\nDVCS: Commits build on a known state\n
  • Lots of merges: yes, but deliberate, tracked, only merge a change once! \nMerging: very powerful - track copies/moves - long running refactoring\nCan “branch” at any point - each concurrent commit IS a branch - merge to any descendant\n\n
  • Graph Queries, 20% JIRA integration\nPause\n
  • distributed nature + DAG = lots of options\nNo-one tells you which one is best!\n\n
  • Stay with what you know - mimic SVN workflow\n get used to whats possible - devs will experiement\n adapt slowly\n\n
  • Us: Started using branching -> release & feature branching (all work on releases like this!)\nBranch from earliest common point you might want to merge to\n\n
  • Review->Build (BB3.1, 20% project)->complete merge/fixVersion & close JIRA\nFeature branch balance - size - life time - naturally evolve - big work - integrate from stable\n
  • Review->Build (BB3.1, 20% project)\nFeature branch balance - size - life time - naturally evolve - big work - integrate from stable\n
  • Review->Build (BB3.1, 20% project)\nFeature branch balance - size - life time - naturally evolve - big work - integrate from stable\n
  • Review->Build (BB3.1, 20% project)\nFeature branch balance - size - life time - naturally evolve - big work - integrate from stable\n
  • Review->Build (BB3.1, 20% project)\nFeature branch balance - size - life time - naturally evolve - big work - integrate from stable\n
  • Review->Build (BB3.1, 20% project)\nFeature branch balance - size - life time - naturally evolve - big work - integrate from stable\n
  • Review->Build (BB3.1, 20% project)\nFeature branch balance - size - life time - naturally evolve - big work - integrate from stable\n
  • Review->Build (BB3.1, 20% project)\nFeature branch balance - size - life time - naturally evolve - big work - integrate from stable\n
  • Review->Build (BB3.1, 20% project)\nFeature branch balance - size - life time - naturally evolve - big work - integrate from stable\n
  • Review->Build (BB3.1, 20% project)\nFeature branch balance - size - life time - naturally evolve - big work - integrate from stable\n
  • Review->Build (BB3.1, 20% project)\nFeature branch balance - size - life time - naturally evolve - big work - integrate from stable\n
  • Review->Build (BB3.1, 20% project)\nFeature branch balance - size - life time - naturally evolve - big work - integrate from stable\n
  • Review->Build (BB3.1, 20% project)\nFeature branch balance - size - life time - naturally evolve - big work - integrate from stable\n
  • Review->Build (BB3.1, 20% project)\nFeature branch balance - size - life time - naturally evolve - big work - integrate from stable\n
  • Review->Build (BB3.1, 20% project)\nFeature branch balance - size - life time - naturally evolve - big work - integrate from stable\n
  • Review->Build (BB3.1, 20% project)\nFeature branch balance - size - life time - naturally evolve - big work - integrate from stable\n
  • Review->Build (BB3.1, 20% project)\nFeature branch balance - size - life time - naturally evolve - big work - integrate from stable\n
  • Review->Build (BB3.1, 20% project)\nFeature branch balance - size - life time - naturally evolve - big work - integrate from stable\n
  • Review->Build (BB3.1, 20% project)\nFeature branch balance - size - life time - naturally evolve - big work - integrate from stable\n
  • Review->Build (BB3.1, 20% project)\nFeature branch balance - size - life time - naturally evolve - big work - integrate from stable\n
  • Works for feature branches too\nDid this on SVN, but as mentioned already - merges only merge new stuff & Traceability\nFeature Branches: can merge to others before integrated to stable\n\n
  • Options: All in one or gradual\n
  • Git SVN and HgSubversion allow you to work on a SVN repository using git/hg as a client - also used for converting\nCan pull at will - by setting up a cron job, can continuously pull changes into git/hg - then push them to your hosting service (github/bitbucket)\nCan also remap committer names, exclude file paths, more info on our blogs.\nMigrate any build/release/test processes that rely on the VCS\n\n
  • \n
  • RSS feeds of changes, activity streams, URL to changes, Search, Commit Graph\n Get Used to Commit hashes etc.\n
  • Start doing code reviews against synced DVCS\nDifferences\nEngage developers\n
  • we very happy, devs sceptical, but now all see benefits\n
  • Convinced you there is more to DVCS than you might have thought\n
  • * Slides will be available\n
  • Transcript

    • 1. DVCS: Making the Move?How Atlassian can help...Matthew WatsonFishEye/Crucible Team Lead, Atlassian 2
    • 2. Why DVCS?• Lots of people excited by it• Huge in Open Source• But what about Commercial in-house development?• What about the costs of migrating? 3
    • 3. What’s Great about DVCS?• Work offline• Easier branching and merging• Github and Bitbucket• Do we really need this? 4
    • 4. What’s really cool about DVCS!• What does ‘D’ in DVCS stand for? 5
    • 5. What’s really cool about DVCS!• What does ‘D’ in DVCS stand for?• Distributed • Commit often, push when ready • Fast, peer-to-peer, no central server • Flexibility: Clones vs Branches 5
    • 6. What’s really cool about DVCS?• What should the ‘D’ in DVCS stand for? 6
    • 7. What’s really cool about DVCS?• What should the ‘D’ in DVCS stand for?• DAG = Directed Acyclic Graph Time • No loops • Each commit has 1 or more parents • Commits uniquely identified 6
    • 8. SVN Commits Bob Mary Will r38 7
    • 9. SVN Commits A.java Bob Mary Will r38 r39 7
    • 10. SVN Commits A.java Bob B.java Mary Will r38 r39 r40 7
    • 11. SVN Commits A.java Bob B.java Mary C.java Will r38 r39 r40 r41 7
    • 12. SVN Commits Will svn commit svn update A.java r38 B.java r38 C.java r41 8
    • 13. SVN Commits Will svn commit svn update A.java r38 r39 B.java r38 r40 C.java r41 r41 8
    • 14. DAG Commits 38:fb38fed187ab 9
    • 15. DAG Commits Bob 38:fb38fed187ab A.java 39:bb0760b60a8b 9
    • 16. DAG Commits Bob 38:fb38fed187ab A.java 39:bb0760b60a8b Mary B.java 40:d0f08ba891a0 9
    • 17. DAG Commits Bob 38:fb38fed187ab A.java 39:bb0760b60a8b Mary B.java 40:d0f08ba891a0 Will C.java 41:38ff647618b5 9
    • 18. DAG Commits Bob 38:fb38fed187ab A.java 39:bb0760b60a8b Mary B.java 40:d0f08ba891a0 42:7d0e20243949 Will C.java 41:38ff647618b5 9
    • 19. DAG Commits Bob 38:fb38fed187ab A.java 39:bb0760b60a8b Mary B.java 40:d0f08ba891a0 42:7d0e20243949 Will C.java 41:38ff647618b5 43:5fcdd3657717 9
    • 20. The Power of the DAG• Deterministic• Annotate/blame works!• Easy and powerful merges - Don’t be scared of long running branches!• Easy and powerful branching 10
    • 21. Traceability• In SVN/CVS etc merges hide what happened Time• In DVCS, the DAG lets you see exactly what changed 11
    • 22. Flexibility• Single Integrator, Gatekeeper• Feature branches, git-flow• Clones• Automation• No central repository 12
    • 23. Workflows, Workflows, Workflows• Which workflow to use?• “With Great Power there must also come - Great Responsibility!” - Spider Man?• Take your time! 13
    • 24. Feature Branching• Branching and merging cheap and easy Time• All feature work done on branch• Can merge to any descendant 14
    • 25. Feature Branching Workflow default Time 15
    • 26. Feature Branching Workflow Create Feature Branch FE-143FE-143 default Time 15
    • 27. Feature Branching Workflow Squash Bugs!FE-143 default Time 15
    • 28. Feature Branching WorkflowFE-127 Complete FE-127FE-143 default Time 15
    • 29. Feature Branching Workflow Merge latest from default, build, test andFE-127FE-143 default Time 15
    • 30. Feature Branching Workflow Merge to default, close JIRA, set fix versionFE-127FE-143 default Time 15
    • 31. Feature Branching WorkflowFE-127 Stable code!FE-143 default Time 15
    • 32. Cross Branch Dependencies• Can merge to any downstream branch• Easily merge fixes for releases into subsequent versions• Also works for feature branches• Our code is naturally becoming more stable 16
    • 33. Migrating to DVCS• Which DVCS?• Small team - just go for it!• Large team - Don’t Fu$%! your devspeed!• Our goal - Zero downtime 17
    • 34. Sync from SVN• Git SVN and HgSubversion • Incremental conversion• Remap Committers • mwatson = Matthew Watson <mwatson@atlassian.com>• Build Processes 18
    • 35. Use Continuous Integration!• Vital part of dev cycle• Run same builds against old and new VCS• Continuous Validation 19
    • 36. Use FishEye!• Sales Pitch• Commit Graph• See your commits in SVN and DVCS 20
    • 37. Use Crucible!• Code reviews against DVCS Commits• Developers get used to the new way • New Commit ids • Committers map to Users 21
    • 38. Make the Switch• Setup Clones and IDE’s before hand• Make SVN read-only• Go DVCS! 22
    • 39. DVCS is Awesome! • More power = more opportunity to do things faster! • The DAG gives traceability, powerful branching and merging, speed • Migrating is easy! @mattw_watson #summit11 23
    • 40. Questions• Our Blogs: http://blogs.atlassian.com/developer• Mercurial: http://mercurial.selenic.com/ • https://bitbucket.org/durin42/hgsubversion/overview/• Git: http://git-scm.com • http://www.kernel.org/pub/software/scm/git/docs/git-svn.html • http://john.albin.net/git/convert-subversion-to-git • http://nvie.com/posts/a-successful-git-branching-model/ 24

    ×