Skip to content

Support putting multiple Flutter bundles in a single APK/IPA #18185

Closed

Description

@mehmetf

In conjunction with #18114, we also need to support shipping multiple Flutter bundles in the same APK/IPA file. For this to work:

  • Need to stop assuming findAppBundlePath is going to return a single path.
  • Load the framework files (such as platform.dill) from a separate resource than application bundles.
  • Change the way we record the bundle entries in manifest/plist.
  • Come up with a way to discover all bundles in the app.
  • Pick a reasonable default if no preference is provided.

Activity

  1. added
    platform-androidAndroid applications specifically
    platform-iosiOS applications specifically
    a: existing-appsIntegration with existing apps via the add-to-app flow
    on Jun 4, 2018
  2. mravn-google commented on Jun 13, 2018

    @mravn-google
    Contributor

    @mehmetf Can you elaborate on why we need this? A single Flutter bundle should be able to handle all the views you'd want, if you specify initialRoute when creating each one.

  3. mehmetf commented on Jun 13, 2018

    @mehmetf
    ContributorAuthor

    @jason-simmons who is familiar with the discussions with mulligan.

    Several motivators for this:

    • Being able to load a section of Dart code only meant to execute in the background. I would want that isolate to have a rather small memory footprint and not load my entire Dart app (including Flutter framework itself).
    • Have multiple isolates being able to load different bundles so we get proper isolation. With the workaround we currently suggest you would need to load the entire app into memory multiple times to achieve the same effect.
    • We will need to support loading Flutter bundles off the wire. It seems that this requirement falls naturally from that.
  4. mehmetf commented on Jul 19, 2018

    @mehmetf
    ContributorAuthor

    I confirmed that customer: dream only needs to be able to dynamically load multiple apps. They don't care about multiple bundles in a single binary.

  5. sbaranov commented on Sep 6, 2018

    @sbaranov
    Contributor

    I think this can be closed, since Flutter already supports dynamically loaded bundles.

  6. mehmetf commented on Sep 7, 2018

    @mehmetf
    ContributorAuthor

    Sure. Let's close it.

    We get customers asking for this from time to time but the workaround we describe using initialRoute has been sufficient for them.

  7. github-actions commented on Sep 2, 2021

    @github-actions

    This thread has been automatically locked since there has not been any recent activity after it was closed. If you are still experiencing a similar issue, please open a new bug, including the output of flutter doctor -v and a minimal reproduction of the issue.

  8. locked as resolved and limited conversation to collaborators on Sep 2, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    a: existing-appsIntegration with existing apps via the add-to-app flowplatform-androidAndroid applications specificallyplatform-iosiOS applications specifically

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions