New Relic in Android Studio - newrelic.properties - variants -


i'm integrating new relic in project (with android studio & gradle) has 2 variants. each variant has own generated token, store in each variant's string.xml file.

in new relic documentation, states following:

in project’s root directory (projectname/app), add newrelic.properties file following line:

com.newrelic.application_token=generated_token 

the problem is, if this, how can make correct token appear correct variant? if file must appear in project root, can't create 1 per variant, , i'm forced use same token both variants, doesn't work requirements.

any insight appreciated.

okay, after contacting support team @ new relic, there apparently no direct solution of today, although said they've opened feature request, , problem might solved soon.

from managed understand, reason file needed new relic system can display un-obfuscated error log when exception occurs on production version has been obfuscated proguard.

the new relic system, of file, upload proguard mapping.txt file new relic servers , associate app according specified token. this, new relic can un-obfuscate stack traces , display descriptive stack trace actual class & method names, rather a, b, c, etc.

as workaround, told can forego file together, if upload mapping file manually.

the mapping file can found at:

build/outputs/proguard/release/mapping.txt   

in order manually upload file, perform following via command line:

curl -v -f proguard=@"<path_to_mapping.txt>" -h "x-app-license-key:<application_token>" https://mobile-symbol-upload.newrelic.com/symbol 

this must done each variant being obfuscated proguard (classically, release builds).

source

hope helps else.


Comments

Popular posts from this blog

IF statement in MySQL trigger -

c++ - What does MSC in "// appease MSC" comments mean? -

javascript - Blogger related post gadget image Resize s72-c [ Need Expert Help ] -