Splunk AppDynamics

Android Proguard mapping files are not found when using product flavour & build type combinations

Pablo_Coberly
Explorer

Android agent plugin version: 

com.appdynamics:appdynamics-gradle-plugin:20.10.0

Using the Android Gradle plugin and calling an assembly task for a particular Android product flavour & build type puts the mapping files in an output folder that the AppDynamics Android plugin cannot find.

For example, where "test" is the product flavour and "prod" is the build type.

./gradlew assembleTestProd

Gives the output:

> Task :app:appDynamicsUploadProguardMappingTestProd
<UploadProguardMappingFileTask_Decorated> Proguard is enabled but mapping file was not generated. Please check your build configuration.

Gradle puts the mapping file in:

build/outputs/mapping/testProd/

But the Appdynamics plugin seems to expect the mapping file to be in

build/outputs/mapping/test/

Expectation:

AppDynamics plugin should create tasks that upload the mapping file from the same output location as the specific product flavour and build type that was assembled.

Labels (1)
Tags (2)
0 Karma

Pablo_Coberly
Explorer

I raised a support ticket with AppDynamics support and they were able to reproduce the issue. The dev team are working on a resolution.

0 Karma

Pablo_Coberly
Explorer

Appdynamics says "Developers confirmed that this issue will be fixed for the next Agent update, which should come out next month."

Boggles my mind that I have to give these updates in this forum and not Appdynamics people themselves.

Pablo_Coberly
Explorer

I've tried specifying the mapping file location in the proguard-rules.pro:

-printmapping build/outputs/mapping/test/mapping.txt

But again, it seems the task appDynamicsUploadProguardMappingTestProd is looking for the mapping files before they are there. 

I've also tried hooking into the task to add a dependency: 

// Put the proguard mapping files where appd expects them.
task copyProguardMappingFiles(type: Copy) {
from "$buildDir/outputs/mapping/testProd"
include "*.*"
into "$buildDir/outputs/mapping/test"
} 
tasks.matching { it.name == 'appDynamicsUploadProguardMappingTestProd' }.all { Task task ->
task.dependsOn 'copyProguardMappingFiles'
}

Now if I run the task twice in succession, the second run doesn't warn about not finding the mapping files, because it seems to be uploading the files that were copied to the expected location the first time.

0 Karma

Pablo_Coberly
Explorer

FYI, I've updated the Gradle plugin and run time versions to the latest versions:

// App dynamics Plugin
classpath "com.appdynamics:appdynamics-gradle-plugin:21.2.1"
implementation 'com.appdynamics:appdynamics-runtime:21.2.1'

 And the same thing happens.

0 Karma
Get Updates on the Splunk Community!

Dashboards: Hiding charts while search is being executed and other uses for tokens

There are a couple of features of SimpleXML / Classic dashboards that can be used to enhance the user ...

Splunk Observability Cloud's AI Assistant in Action Series: Explaining Metrics and ...

This is the fourth post in the Splunk Observability Cloud’s AI Assistant in Action series that digs into how ...

Brains, Bytes, and Boston: Learn from the Best at .conf25

When you think of Boston, you might picture colonial charm, world-class universities, or even the crack of a ...