Upgrade to Pro — share decks privately, control downloads, hide ads and more …

Android App Bundle

Android App Bundle

Souleymane Sidibe

November 24, 2018
Tweet

More Decks by Souleymane Sidibe

Other Decks in Programming

Transcript

  1. @soulesidibe
    Android App
    Bundle

    View full-size slide

  2. App Release Process

    View full-size slide

  3. App Release Process
    • Coding

    View full-size slide

  4. App Release Process
    • Coding
    • Build a signed APK

    View full-size slide

  5. App Release Process
    • Coding
    • Build a signed APK
    • Upload to Google Play console

    View full-size slide

  6. App Release Process
    • Coding
    • Build a signed APK
    • Upload to Google Play console
    • Deploy to users

    View full-size slide

  7. App Release Process
    • Coding
    • Build a signed APK
    • Upload to Google Play console
    • Deploy to users
    • !

    View full-size slide

  8. App Release Process
    • Coding
    • Build a signed APK
    • Upload to Google Play console
    • Deploy to users
    • !
    This works for years!

    View full-size slide

  9. App Release Process
    + Developer Friendly
    + Secure
    + Easy distribution
    - Lose signing key
    - Apk size bigger

    View full-size slide

  10. App Release Process
    + Developer Friendly
    + Secure
    + Easy distribution
    - Lose signing key
    - Apk size bigger

    View full-size slide

  11. Multiple APKs to the
    rescue
    • Upload multiple apk
    • 1 configuration 1 apk
    • Same Package name and same signing key
    • Must have different versionCode
    • A configuration should be unique

    View full-size slide

  12. Multiple APKs to the
    rescue
    • Upload multiple apk
    • 1 configuration 1 apk
    • Same Package name and same signing key
    • Must have different versionCode
    • A configuration should be unique
    But not developer friendly

    View full-size slide

  13. Android App
    Bundle
    The solution

    View full-size slide

  14. “An Android App Bundle is a new upload format that
    includes all your app’s compiled code and resources,
    but defers APK generation and signing to Google Play.”

    View full-size slide

  15. App Bundle
    “Fat” APK

    View full-size slide

  16. New App Release
    Process
    Android App Bundle format

    View full-size slide

  17. Base APK
    • Common code and resources
    • Basic features of you app
    • Downloaded first (be careful about the
    size)

    View full-size slide

  18. Dynamic feature APKs
    • Code and resources for a Feature
    • Google Play generates split APKs
    • Installed on demand (Play Core Library)
    • Depends on base APKs

    View full-size slide

  19. Configuration APKs
    • 1 device configuration !=> 1 APK
    • A configuration?
    Screen size
    API level
    CPU Architecture
    Language

    View full-size slide

  20. Configuration APKs
    • 1 device configuration !=> 1 APK
    • A configuration?
    Screen size
    API level
    CPU Architecture
    Language
    Google Play automatically generates configuration APKs for you.

    View full-size slide

  21. App Bundle
    Split APKs

    View full-size slide

  22. New App Release
    Process
    • Coding
    • Build a signed Android App bundle

    View full-size slide

  23. New App Release
    Process
    • Coding
    • Build a signed Android App bundle
    • You must use App Sign in by Google

    View full-size slide

  24. New App Release
    Process
    • Coding
    • Build a signed Android App bundle
    • You must use App Sign in by Google
    • Upload the AAB file to Play Store Console

    View full-size slide

  25. New App Release
    Process
    • Coding
    • Build a signed Android App bundle
    • You must use App Sign in by Google
    • Upload the AAB file to Play Store Console
    • Google Play generates split APKs for you

    View full-size slide

  26. New App Release
    Process
    • Coding
    • Build a signed Android App bundle
    • You must use App Sign in by Google
    • Upload the AAB file to Play Store Console
    • Google Play generates split APKs for you
    • Dynamic delivery

    View full-size slide

  27. Why?
    • Easy to switch to app bundle

    View full-size slide

  28. Why?
    • Easy to switch to app bundle
    • ./gradlew assembleRelease becomes ./gradlew
    bundleRelease

    View full-size slide

  29. Why?
    • Easy to switch to app bundle
    • ./gradlew assembleRelease becomes ./gradlew
    bundleRelease
    • Small APK size

    View full-size slide

  30. Why?
    • Easy to switch to app bundle
    • ./gradlew assembleRelease becomes ./gradlew
    bundleRelease
    • Small APK size
    • Secure

    View full-size slide

  31. Why?
    • Easy to switch to app bundle
    • ./gradlew assembleRelease becomes ./gradlew
    bundleRelease
    • Small APK size
    • Secure
    • Dynamic Features

    View full-size slide

  32. HOW?
    • ./gradlew bundleDebug

    View full-size slide

  33. HOW?
    • ./gradlew bundleRelease
    • generate …build/out/release/app.aab

    View full-size slide

  34. HOW?
    • ./gradlew bundleDebug
    • generate …build/out/debug/app.aab
    • Bundletool

    View full-size slide

  35. That’s it!
    @soulesidibe

    View full-size slide

  36. Links
    •Official doc !=> https:!//bit.ly/2Knmc28
    •What a new publishing format means for the
    future of Android !=> https:!//bit.ly/2QZuSjc
    •Android developer blog !=> https:!//bit.ly/2PYM8F2
    •Play Core library !=> https:!//bit.ly/2Pjpla3
    •Google IO 18 !=> https:!//bit.ly/2OQgaOM
    •All About android !=> https:!//bit.ly/2PSf41f

    View full-size slide