0

Do Android dynamic feature modules have an isolated classpath, or do they share a classpath with the rest of the application? My companies app has grown large enough that we have multiple teams owning separate features. We're currently considering breaking up our application into feature modules that can be shipped and updated separately.

It seems like in order to be able to ship a feature separately and safely, it would need to have a separate classpaths so that any changes to dependencies didn't cause classpath conflicts.

spierce7
  • 14,797
  • 13
  • 65
  • 106

1 Answers1

0

Dynamic features may or may not depend upon the base feature, but if they depend on the base feature then you have to be conscious about the base module's classpath. but vice-versa is not true, that is base module can not depend upon dynamic features due to obvious reasons, as base module does not have information that what dynamic features user is going to have, also not aware if dynamic features are configured for on-install mode or on-demand mode.

Although if you want to divide the app into small modules with least dependencies, then you should consider the development in the form of the libs (or say .aar files), you can share .aar among the teams or can upload on the maven and sort out dependencies by including them into build.gradle.

Gaurav Bansal
  • 604
  • 5
  • 11