Permissionsdispatcher: Gradle鈥榮 daemon leak

Created on 21 Mar 2020  路  3Comments  路  Source: permissions-dispatcher/PermissionsDispatcher

https://github.com/gradle/gradle/issues/12571

Similar problems:https://github.com/google/dagger/issues/1645

contributionwelcome

Most helpful comment

this issue is solved by update the gradle to 4.0.0 and the kotlin version

classpath 'com.android.tools.build:gradle:4.0.0'

All 3 comments

thx, do you have more insights? checked dagger's PR but I'm not super familiar around there.. 馃 @fanmingyi

From what I can gather by looking at the referenced issues, it seems like there is a memory leak within kapt when certain static caches or utilities are being used. In our case, the culprit seems to be this guy.

Screen Shot 2020-03-25 at 10 04 11

ELEMENT_UTILS is only used by a singular helper function. Maybe it's possible to rid ourselves of that static reference, which should in turn allow for proper GC. FWIW, we also have a static TYPE_UTILS, but I cannot see if that contributes to the leak as well.

this issue is solved by update the gradle to 4.0.0 and the kotlin version

classpath 'com.android.tools.build:gradle:4.0.0'

Was this page helpful?
0 / 5 - 0 ratings