All Products
Search
Document Center

Mobile Platform as a Service:Upload logs

Last Updated:Mar 12, 2026

Logs written to local files on the client are uploaded to the log server in the following ways.

  • Automatic upload: Logs are uploaded automatically when certain conditions are met.

  • Upload based on log switch: In addition to automatic uploads, you can use server-side switch values to change the conditions that trigger automatic uploads.

  • Manual upload: You can force an upload by calling the log upload API.

Automatic upload

Logs are automatically uploaded when the following conditions are met:

  • An upload is triggered automatically when the number of cached local logs reaches a specific threshold.

    • Logs for keep-alive, startup speed, stuttering, freezes, and crashes are uploaded in real time.

    • Logs for custom events and automation are uploaded when their count reaches 50.

  • An upload is triggered when the application is sent to the background.

Upload based on log switch

In addition to the default log upload triggers, you can also dynamically control log upload timing on the Mobile Analysis > Log Management > Upload Switch Configuration > Tagging Configuration page in the console.

Where:

  • Upload Switch: The configurations on this page take effect only when this switch is turned on.

  • Network: Select whether to upload logs in All network environments or Only on Wi-Fi.

  • Business Code: Corresponds to the business code (bizType) used during client-side instrumentation. For common business codes, see View local logs.

  • Log Upload Count: Triggers an upload when the number of logs of this type in the local file reaches this value.

  • Log Upload Ratio: Sets the log upload ratio by user dimension. The value is based on parts per thousand. For example, a value of 1000 means logs are uploaded for all users.

  • Minimum Upload Level: Each log is assigned a level when it is written. Logs with a level less than or equal to this value are uploaded. For example, if you set Minimum Upload Level to 2, logs with levels 1 and 2 are uploaded, but logs with level 3 are not.

For more information, see Configure log upload switches.

Manual upload

You can manually report data as follows:

MPLogger.uploadAll();

Custom Device ID

Note

As of baseline version 10.2.3.75, custom Device IDs are supported.

MPLogger.setClientId(String clientId);