All Products
Document Center

Mobile Platform as a Service:Adapt to targetsdkversion 29

Last Updated:Feb 24, 2023

The former mPaaS standard baseline only supports up to 26 for targetSdkVersion. However, The support to targetSdkVersion is added since If your app needs to upgrade targetSdkVersion to 29, refer to Use mPaaS plug-in to update the SDK to or later, and add configuration according to the following description and return to the relevant function.

Update SDK

Update the SDK and related configuration with reference to mPaaS supports for multi-CPU architecture.

Adapt targetSdkVersion 29


Adapt targetSdkVersion 28 with reference to Adaptation of targetSdkVersion 28 to mPaaS

Modify targetSdkVersion


Modify the attribute targetSdkVersion 29 in the build.gradle file under the main module of the project.


  • Modify the attribute targetSdkVersion 29 in the build.gradle file under the main module of the Portal project.

  • The targetSdkVersion in the Bundle project may be left unchanged, but may not be later than that of the Portal project.

Universal configurations

Modify the project AndroidManifest.xml and add the following attributes under the application node:

    ... >

The backend uses location function

If your app needs to use the location function while in the backend, you need to add and request the following permissions:

  • Add the following permissions to AndroidManifest.xml:

    <uses-permission android:name="android.permission.ACCESS_BACKGROUND_LOCATION" />
  • Ensure that the permission is dynamically requested before calling the locator API:

    String[] permissions;
    if (android.os.Build.VERSION.SDK_INT >= android.os.Build.VERSION_CODES.Q) {
      permissions = new String[]{
    } else {
      permissions = new String[]{
    ActivityCompat.requestPermissions(this, permissions, 101);

    Use the Bluetooth function of the mini program

If your app needs to use Bluetooth-related APIs in the mini program, you need to add and request the following permissions.

  • Add the following permissions to AndroidManifest.xml:

    <uses-permission android:name="android.permission.ACCESS_FINE_LOCATION" />
  • Ensure that the permission has been requested before calling the Bluetooth API:

    String[] permissions = new String[]{
    ActivityCompat.requestPermissions(this, permissions, 101);

    Regression test

Android 10.0+ devices must be included in the full regression test.

For regression test, you need to focus on the following component functions, if used:


Validation project

Unified data storage

- Whether Database encrypted storage functions well.

Mobile Analytics Service

- Whether the lag monitoring of Mobile Analytics Service functions well.

Mini programs

- Whether Mini program file API functions well.

- Whether Mini program Bluetooth API functions well.

- Whether the map component of the mini program functions well.


- Whether Locatingfunctions well.