By default, the SDK logs and stacks traces of the integration calls in the phone’s
internal storage. These logs are useful to troubleshoot the integration
issues.
However, in addition to this default logs, you can enable measurement logging,
also calle debug mode, which is helpful for debugging the service performance
issues. This can be done in two way :
The debug mode can be enabled for a selected apikey. However, it does mean
that the debug mode is automatically activated for all applications that load the
service with this apikey. This can be done by following the instructions
below.
Warning : Always ask Pole Star before enabling this feature. This mode can
saturate the storage, DO NOT enable it on production API key, as it could have
a detrimental effect on your users’ experience.
An alternative way to enable the measurement logging is to invoke the methods exposed
by the API. This implements a couple of methods : startLoggingMeasurements
and stopLoggingMeasurements which allow to start and stop the measurement
logging respectively.
To start and stop logging the debug measurements, use code similar to the
following.
[NAOServicesConfig startLoggingMeasurements];
...
[NAOServicesConfig stopLoggingMeasurements];
...
[NAOServicesConfig uploadNAOLogInfo];
NAOServicesConfig.startLoggingMeasurements();
...
NAOServicesConfig.stopLoggingMeasurements();
...
NAOServicesConfig.uploadNAOLogInfo();
In both the above cases, the debug measurement logs can be retrieved
manually from the phone (Android only), or sent to NAO Cloud through
the NAOServicesConfig.uploadNAOLogInfo() API. However :