Diese Präsentation wurde erfolgreich gemeldet.
Wir verwenden Ihre LinkedIn Profilangaben und Informationen zu Ihren Aktivitäten, um Anzeigen zu personalisieren und Ihnen relevantere Inhalte anzuzeigen. Sie können Ihre Anzeigeneinstellungen jederzeit ändern.

What's new in Gerrit Code Review 3.0

312 Aufrufe

Veröffentlicht am

Gerrit 3.0 it out! If you‘ve tried 2.16, you may have already seen the new database backend (NoteDb) and UI (PolyGerrit). With 2.16 and 3.0, these features are better than ever. In Gerrit 3.0, we’ve deleted thousands and thousands of lines from Gerrit's codebase.

Join me for a tour of new features you can use today, and a discussion about even more things to look forward to once we've freed ourselves from the burden of some of our legacy code.

Veröffentlicht in: Technologie
  • Als Erste(r) kommentieren

  • Gehören Sie zu den Ersten, denen das gefällt!

What's new in Gerrit Code Review 3.0

  1. 1. 0Gerrit User Summit 2019 – Volvo Cars – Gothenburg - Sweden GerritForge.com 0 What’s new in Gerrit 3.0 … and beyond Luca Milanesio Gerrit Code Review Maintainer GerritForge
  2. 2. 1Gerrit User Summit 2019 – Volvo Cars – Gothenburg - Sweden GerritForge.com 1 About GerritForge Founded in the UK HQ in London Committed to OpenSource
  3. 3. 2Gerrit User Summit 2019 – Volvo Cars – Gothenburg - Sweden GerritForge.com 2 New features PolyGerrit is THE Gerrit UI GWT is gone FOREVER
  4. 4. 3Gerrit User Summit 2019 – Volvo Cars – Gothenburg - Sweden GerritForge.com 3 PolyGerrit in-line Edit Codemirror Syntax highlight
  5. 5. 4Gerrit User Summit 2019 – Volvo Cars – Gothenburg - Sweden GerritForge.com 4 PolyGerrit goodies Dark Mode Custom Themes
  6. 6. 5Gerrit User Summit 2019 – Volvo Cars – Gothenburg - Sweden GerritForge.com 5 PolyGerrit Mobile / Tablet view Fluid Layout
  7. 7. 6Gerrit User Summit 2019 – Volvo Cars – Gothenburg - Sweden GerritForge.com 6 PolyGerrit JavaScript plugins (e.g. Checks) UI extension points for plugins
  8. 8. 7Gerrit User Summit 2019 – Volvo Cars – Gothenburg - Sweden GerritForge.com 7 PolyGerrit out of the box experience First steps Help for new users
  9. 9. 8Gerrit User Summit 2019 – Volvo Cars – Gothenburg - Sweden GerritForge.com 8 Notedb happened NoteDB = NO(te) DB
  10. 10. 9Gerrit User Summit 2019 – Volvo Cars – Gothenburg - Sweden GerritForge.com 9 The journey to v3.0 Dave Borowitz – Gerrit User Summit 2017
  11. 11. 10Gerrit User Summit 2019 – Volvo Cars – Gothenburg - Sweden GerritForge.com 10 The journey to v3.0 Dave Borowitz – Gerrit User Summit 2017 Gerrit 2.16 Gerrit 3.0 2019
  12. 12. 11Gerrit User Summit 2019 – Volvo Cars – Gothenburg - Sweden GerritForge.com 11 Migration path v3.0 • v2.14 / ReviewDb • v2.15 / ReviewDb • v2.16 / ReviewDb • v2.16 / NoteDb •v3.0 https://www.workeastren.co.uk/case-studies/paul-steps-to-success-case-study/
  13. 13. 12Gerrit User Summit 2019 – Volvo Cars – Gothenburg - Sweden GerritForge.com 12 NoteDb the most innovative feature of Gerrit Commits + Reviews + Meta-data Accounts + Groups è ALL stored in Git
  14. 14. 13Gerrit User Summit 2019 – Volvo Cars – Gothenburg - Sweden GerritForge.com 13 NoteDb fully consistent backups Online backups 100% consistency
  15. 15. 14Gerrit User Summit 2019 – Volvo Cars – Gothenburg - Sweden GerritForge.com 14 NoteDb remove single-point-of-failure ONE LESS point of failure (DBMS)
  16. 16. 15Gerrit User Summit 2019 – Volvo Cars – Gothenburg - Sweden GerritForge.com 15 NoteDb on-line migrations NO MORE Schema Migration zero-downtime upgrade
  17. 17. 16Gerrit User Summit 2019 – Volvo Cars – Gothenburg - Sweden GerritForge.com 16 NoteDb disaster recovery Replication to DR site of ALL Gerrit data
  18. 18. 17Gerrit User Summit 2019 – Volvo Cars – Gothenburg - Sweden GerritForge.com 17 NoteDb full audit and compliance Account history Groups history Review history ALL in Git repo as JSON
  19. 19. 18Gerrit User Summit 2019 – Volvo Cars – Gothenburg - Sweden GerritForge.com 18 NoteDb full security ALL objects protected with uniform ACLs And Group-based access
  20. 20. 19Gerrit User Summit 2019 – Volvo Cars – Gothenburg - Sweden GerritForge.com 19 NoteDb allow data insight and analytics Expose ALL reviews Data as JSON for analytics
  21. 21. 20Gerrit User Summit 2019 – Volvo Cars – Gothenburg - Sweden GerritForge.com 20 NoteDb increased performance and low latency Read code and reviews In the same JGit access and cache
  22. 22. 21Gerrit User Summit 2019 – Volvo Cars – Gothenburg - Sweden GerritForge.com 21 NoteDb example $ git fetch origin refs/changes/95/218095/meta && git log -p FETCH_HEAD commit ac3c2780a9737356e3a494f772570608ca5fb66b Author: Gerrit User 1006192 <1006192@173816e5-2b9a-37c3-8a2e-48639d4f1153> Date: Mon Mar 18 17:54:15 2019 +0000 Update patch set 1 Change has been successfully merged by Luca Milanesio Patch-set: 1 Status: merged Tag: autogenerated:gerrit:merged Reviewer: Gerrit User 1006192 <1006192@173816e5-2b9a-37c3-8a2e-48639d4f1153> Label: SUBM=+1 Submission-id: 18095-1552931655231-726b23a Submitted-with: OK Submitted-with: OK: Verified: Gerrit User 1006192 <1006192@173816e5-2b9a-37c3-8a2e-48639d4f1153> Submitted-with: OK: Code-Review: Gerrit User 1029953 <1029953@173816e5-2b9a-37c3-8a2e-48639d4f1153> commit 92b2da48565dc807cb88a8df190452add9b150b2 Author: Gerrit User 1006192 <1006192@173816e5-2b9a-37c3-8a2e-48639d4f1153> Date: Mon Mar 18 17:54:11 2019 +0000 Update patch set 1 Patch Set 1: Verified+1
  23. 23. 22Gerrit User Summit 2019 – Volvo Cars – Gothenburg - Sweden GerritForge.com 22 Submit Rules bye bye PROLOG Submit rules extension point In ANY language (also PROLOG)
  24. 24. 23Gerrit User Summit 2019 – Volvo Cars – Gothenburg - Sweden GerritForge.com 23 Submit Rules PROLOG submit_rule(submit(R)) :- gerrit:unresolved_comments_count(0), !, gerrit:uploader(U), R = label('All-Comments-Resolved', ok(U)). submit_rule(submit(R)) :- gerrit:unresolved_comments_count(U), U > 0, R = label('All-Comments-Resolved', need(_)).
  25. 25. 24Gerrit User Summit 2019 – Volvo Cars – Gothenburg - Sweden GerritForge.com 24 Submit Rules Java public class NoUnresolvedCommentsRule implements SubmitRule { private static final SubmitRequirement REQUIREMENT = SubmitRequirement.builder() .setType("unresolved_comments") .setFallbackText("Resolve all comments") .build(); @Override public Collection<SubmitRecord> evaluate(ChangeData cd, SubmitRuleOptions options) { Integer unresolvedComments = cd.unresolvedCommentCount(); SubmitRecord sr = new SubmitRecord(); sr.requirements = Collections.singletonList(REQUIREMENT); sr.status = unresolvedComments == null || unresolvedComments > 0 ? SubmitRecord.Status.NOT_READY : SubmitRecord.Status.OK; return ImmutableList.of(sr); } }
  26. 26. 25Gerrit User Summit 2019 – Volvo Cars – Gothenburg - Sweden GerritForge.com 25 Core plugins plugin manager Discover and install with one click
  27. 27. 26Gerrit User Summit 2019 – Volvo Cars – Gothenburg - Sweden GerritForge.com 26 More core plugins Gitiles (!) Delete-project (finally !!) WebHooks (yeah !)
  28. 28. 27Gerrit User Summit 2019 – Volvo Cars – Gothenburg - Sweden GerritForge.com 27 Native Packages updates RPMs for RedHat & CentOS 7.6 Debs for Debian & Ubuntu 18.04 Support for Docker in production
  29. 29. 28Gerrit User Summit 2019 – Volvo Cars – Gothenburg - Sweden GerritForge.com 28 What’s coming in v3.1 Polymer 2.0 Git Protocol v2 (secured) Performance Stability and Fixes More CI integration
  30. 30. 29Gerrit User Summit 2019 – Volvo Cars – Gothenburg - Sweden GerritForge.com 29 Q&A: excited about the future of Gerrit? Image from: http://cypp.rutgers.edu/ru-voting/political-information/public-opinion-polls/
  31. 31. 30Gerrit User Summit 2019 – Volvo Cars – Gothenburg - Sweden GerritForge.com 30 Wants to know more? GerritForge.com/contact

×