07 Jul 2022 09:00 PM - last edited on 08 Jul 2022 12:48 AM by MaciejNeumann
Hello everyone, I'm using Unity version 2020.3.30f1 and I want to add Dynatrace plugin into my project
I was refer the following document for adding:
and my gradle file before and after added:
I can build normally with default .gradle file but had been some error with the new gradle file
Someone can help me for this issue or any way to add Dynatrace plugin in Unity? Thanks.
Solved! Go to Solution.
The documentation you are referring is not for Unity or iOS but more for android.
Try using this 3rd party plugin nativescript-dynatrace-gradle-plugin | NativeScript Marketplace
Or reach out to your CSM via support to help with iOS application instrumentation using cocoapods.
The Dynatrace Android Gradle plugin is used to instrument "native" Android apps. It instruments UI components from the Android SDK. I'm not familiar with Unity and therefore I can't determine which parts of an Unity app can be monitored by the Dynatrace Android Gradle plugin. Our assumption is that Dynatrace will not monitor user interactions, because the Unity app doesn't use the standard Android UI components.
Android Gradle plugin version 3.6.0:
Starting with OneAgent SDK for Android version 8.245, we're ending support for the following versions of Android and Gradle plugin: Android 4.0.3 - 4.4 (API level 15 - 19) Android Gradle plugin 3.1 - 3.6. After the release, we'll support the following versions: Android 5.0+ (API level 21+) Android Gradle plugin 4.0+
You have to either upgrade the used Android Gradle plugin version or use an old Dynatrace Android Gradle plugin version.
Plugin id "com.android.library":
The Dynatrace Android Gradle plugin only instruments Android app projects. But the shared build.gradle file is used for building an Android library.
I found this page but it does not exist for version 2020.3. Based on the specification on this page you would have to add the Dynatrace plugin configuration to the file root/build.gradle and then it should automatically detect the Android app module in the location root/launcher/build.gradle
Can you share the build error message? Without it, we are not able to determine the problem.