We rely on the datadog closure to set project.datadog.serviceName when setting a custom service name.
However, we need the datadog android gradle plugin to be added for the closure to be defined.
When android proguard mapping files upload is disabled, the plugin was not installed and so the gradle build was failing.
We could handle this case by using project.ext.datadog to set the serviceName in this particular case, but I think it's easier to always install the plugin and have only one way of setting the serviceName.
Review checklist (to be filled by reviewers)
[ ] Feature or bugfix MUST have appropriate tests
[ ] Make sure you discussed the feature or bugfix with the maintaining team in an Issue
[ ] Make sure each commit and the PR mention the Issue number (cf the CONTRIBUTING doc)
[ ] If this PR is auto-generated, please make sure also to manually update the code related to the change
What does this PR do?
We rely on the
datadog
closure to setproject.datadog.serviceName
when setting a custom service name. However, we need the datadog android gradle plugin to be added for the closure to be defined.When android proguard mapping files upload is disabled, the plugin was not installed and so the gradle build was failing.
We could handle this case by using
project.ext.datadog
to set the serviceName in this particular case, but I think it's easier to always install the plugin and have only one way of setting the serviceName.Review checklist (to be filled by reviewers)