fix: add stability configuration file to the core maps-compose projec…
…t. The currently configured types are all the immutable data types from com.google.android.gms.maps.model that are currently used in android-maps-compose:maps-compose. These types will now be considered @Stable by the compiler. Making immutable data types @Stable can be a more effective measure than relying on strong skipping, as stable types can use structural equality, whereas strong skipping merely relies on referential equality, as of today.
This commit also makes compose compiler report generation available via command-line options (-PcomposeCompilerMetrics=true, -PcomposeCompilerReports=true)
Fixes #152
@kikoso are you open to reviewing this PR?
@wangela can this PR receive a review, please?
Hi @bubenheimer . Thanks for the PR, and for the patience while getting this reviewed.
This should improve the stability and performance. Is there a reason why you would not include the other types in the model folder?
@kikoso The types in model are not generally immutable, which commonly would make them non-stable for Compose purposes. They would be covered by the upcoming strong skipping changes for handling non-stable types in Compose, which is a little less powerful than what we can achieve with stability configuration files.
I've validated for the types in the stability configuration file that they are immutable. These are all the Maps SDK model types currently in use in the maps-compose library.
I did not look at what's being used in maps-compose-utils, and did not provide a stability configuration file there, as I don't use that lib, not familiar with it. It can be done independently of this PR.
@kikoso Actually, maps-compose uses some mutable types from model as well (e.g. Marker), but they need to be handled via strong skipping changes, not stability configuration file, for the the reason I gave above.
Thanks @bubenheimer , that makes sense. We will wait until the strong skipping mode exits its experimental phase before adopting it. However, this already represents an improvement in terms of performance.
:tada: This PR is included in version 4.3.4 :tada:
The release is available on:
v4.3.4- GitHub release
Your semantic-release bot :package::rocket: