All Products
Search
Document Center

Mobile Platform as a Service:Adapt mPaaS 10.1.68 to Android 13 Beta

Last Updated:Feb 24, 2023

This topic introduces the adaptation work that users need to do for Android 13 when using the mPaaS 10.1.68 baseline.

Google has released the official version of Android 13 on August 16, 2022. As the base library, mPaaS has been adapted on the 10.1.68 baseline. Before mPaaS adaptation, HTML5 containers and applets will not be able to enable the UC kernel when using the mPaaS SDK on Android 13 devices.

Upgrade SDK

For more information on how to upgrade the mPaaS SDKs, see Use mPaaS plug-in.

Important

Please upgrade the baseline version to 10.1.68.52 or above.

Enable UC kernel

To enable the UC kernel, you need to use a specific version of UC kernel on Android 13 and add the corresponding configuration. If you do not perform the following adaptation operations, HTML5 containers and mini programs will enable WebView by default on Android 13, and some problems such as white screen errors or API exceptions may occur.

implementation('com.alipay.android.phone.wallet:nebulaucsdk-build:999.3.22.2.46.220614210535@aar') {
    force = true
}

The Portal&Bundle integration methods also need to remove the original UC kernel in the SDK, and add the following content to the build.gradle of the main module (the Portal&Bundle access method is in the Portal project):

mpaascomponents {
    excludeDependencies = [
            "com.alipay.android.phone.wallet:nebulaucsdk-build"
    ]
}

Add configuration to enable the UC kernel on Android 13

Create the custom_config.json file under the config directory in assets and add the following content to the file:

[
  {
    "value":"{\"h5_enableExternalWebView\":\"YES\",\"h5_externalWebViewSdkVersion\":{\"min\":11,\"max\":33}}",
    "key":"h5_webViewConfig"
  },
  {
  "key":"h5_useLastCommitUrl",
  "value":"YES"
  }
]

Perform regression tests

Upgrading the UC kernel may be accompanied by changes to some browser features. Please perform regression tests on H5 containers, applets and other related services that use the UC browser.

Safety guarantee

When developing apps based on the mPaaS framework, apps using HTML5 containers/mini programs will use JSAPI more. It is recommended to verify the URL when opening the URL and when using the JSAPI to ensure that the URL within the App business can be loaded to open or limit the URL's JSAPI calling scope and permissions to prevent problems caused by unauthenticated.

  1. Set JSAPI authentication

  2. Set URL whitelist

Process custom libraries

Each component of version 10.1.68 has incorporated customized requirements. If your dependencies include custom libraries, you need to deal with the following conditions:

If you upgrade an mPaaS SDK from an earlier version such as 10.1.60 to 10.1.68, you may need to re-customize custom libraries based on 10.1.68. Submit a ticket or contact the technical support staff of mPaaS.