Android Development At Scale That Your SysOps Will Love (AnDevCon Santa Clara Dec. 2 2015)

E552215dd726801c644470feae8bb41c?s=47 mscheel
December 02, 2015

Android Development At Scale That Your SysOps Will Love (AnDevCon Santa Clara Dec. 2 2015)

Large software teams? Millions of users? There is no time for "works on my machine." Let's dive into professional build tools like Vagrant, Docker and Jenkins to attack the pitfalls of shipping Android at scale. Your Operations team will thank you. This class will cover real-world examples and show how the largest apps in the Play Store are built, tested and performance-enhanced.

E552215dd726801c644470feae8bb41c?s=128

mscheel

December 02, 2015
Tweet

Transcript

  1. @5280mark #AnDevCon Android Development at Scale That Your SysOps Will

    Love Mark Scheel
  2. @5280mark #AnDevCon Android Build Systems that inspire Love Mark Scheel

  3. @5280mark #AnDevCon EDUCATE

  4. @5280mark #AnDevCon ENTERTAIN

  5. @5280mark #AnDevCon What do you get …

  6. @5280mark #AnDevCon What do you get …

  7. @5280mark #AnDevCon CONSUME

  8. @5280mark #AnDevCon REMEMBER

  9. @5280mark #AnDevCon Life is better with consistent, repeatable build systems.

  10. @5280mark #AnDevCon CONSISTENT + REPEATABLE = #CONSISTABLE

  11. @5280mark #AnDevCon CONSISTABLE

  12. @5280mark #AnDevCon Mark Scheel

  13. @5280mark #AnDevCon Actionable Information for when back home

  14. @5280mark #AnDevCon Anti-Pattern

  15. @5280mark #AnDevCon

  16. @5280mark #AnDevCon Three Tools Two Stories

  17. @5280mark #AnDevCon

  18. @5280mark #AnDevCon

  19. @5280mark #AnDevCon

  20. @5280mark #AnDevCon

  21. @5280mark #AnDevCon

  22. @5280mark #AnDevCon

  23. Vagrant • Vagrant provides easy to configure, reproducible, and portable

    work environments built on top of industry-standard technology and controlled by a single consistent workflow to help maximize the productivity and flexibility of you and your team. • To achieve its magic, Vagrant stands on the shoulders of giants. Machines are provisioned on top of VirtualBox, VMware, AWS, or any other provider. Then, industry-standard provisioning tools such as shell scripts, Chef, or Puppet, can be used to automatically install and configure software on the machine.
  24. Vagrant • Recipe is called “Vagrantfile” • You can create

    reproducible and portable environments, excellent for experimentation AND sharing • A single file defines the machine, can be checked into source control • No more “works on my machine”
  25. Vagrant • Learn more at vagrantup.com • $ vagrant up

    • $ vagrant ssh • $ vagrant halt • $vagrant destroy
  26. @5280mark #AnDevCon Live Demo

  27. @5280mark #AnDevCon

  28. Docker • Initially written in Go by Solomon Hykes •

    Docker automates the deployment of applications inside software containers, by providing an additional layer of abstraction and automation of operating-system-level virtualization on Linux. • Docker uses resource isolation features of the Linux kernel such as groups and kernel namespaces to allow independent "containers" to run within a single Linux instance, avoiding the overhead of starting and maintaining virtual machines
  29. Docker • Build, Ship, Run • Make your SysAdmin or

    Ops guy happy • Great for apps with distributed resources
  30. @5280mark #AnDevCon

  31. @5280mark #AnDevCon

  32. Docker • Won’t run on Mac out of the box,

    OS X doesn’t support system-level virtualization even though BSD has jails • boot2docker or run inside vagrant Ubuntu • Google notes • Learn more - docker.com
  33. @5280mark #AnDevCon

  34. Jenkins • Java based, forked from Hudson after Oracle drama

    • Continuous Integration software • Monitors execution of builds • Makes it easy for anyone to make a build, turn source into product
  35. @5280mark #AnDevCon

  36. Jenkins • Pro Tip: Install in a container, avoid service

    sludge • Pro Tip: Name your jobs consistently • Pro Tip: Clean your workspace! • Pro Tip: Have a process for broken builds
  37. Jenkins • Jenkins builds can be triggered by a commit

    or many other triggers (cron, etc) • Consistently and repeatedly build your project the same way • Started by Kohsuke Kawaguchi
  38. Jenkins • Plugin Support • Publish to Play Store (Google

    Publish) • Git • Gradle • Credentials Binding (secrets) • Findbugs • Android emulator • Android Lint • Checkstyle • DRY • PMD - like findbugs, analyzes byte code for potential glitches • Warnings - Displays compiler warnings • Static Code Analysis - Compiles many of above and puts into a graph
  39. Jenkins • Slaves - can be docker instances • Master

    Slave model allows many builds from one master • Slaves can be local, remote, containers etc
  40. @5280mark #AnDevCon PARIS

  41. Mark Scheel ✤ @5280mark ✤ github.com/mscheel ✤ Open Source contributions

    to Google Glass and Square ✤ stackoverflow.com/mscheel ✤ speakerdeck.com/mscheel ✤ These slides available soon ✤ lanyrd.com/mscheel ✤ December 3, 2015: AnDevCon, Santa Clara, CA ✤ Your local GDG? ✤ meetup.com/gdg-denver ✤ Visit Denver and speak! You can do it. ✤ www.digitalconstruction.com ✤ www.itriagehealth.com ✤ airbnb.com/c/mscheel ($20 travel credit from me)