All Products
Search
Document Center

Mobile Platform as a Service:Solve conflict with dependency on fastjson

Last Updated:Sep 07, 2023

Conflict description

mPaaS uses fastjson for JSON parsing, if you also use fastjson in your project, there will be a fastjson conflict.

Solution

Remove fastjson-build from mPaaS.

Procedure

  1. Confirm the current version of fastjson used by mPaaS.

    'com.alibaba:fastjson:1.x.x.android@jar'
  2. Get the group:artifact information for the third-party SDK used by mPaaS.

    'com.alipay.android.phone.thirdparty:fastjson-build'
  3. Remove the mPaaS library.

    • AAR method

      If you are accessing mPaaS by a native AAR, there is no need to actively remove it, and dependency passing of gradle will automatically use a later version. The version chosen for use by mPaaS is highly stable and secure, and we recommend you to use the version provided by mPaaS. If versions are inconsistent, please test the mPaaS function before its launch to ensure stability.

    • Portal & Bundle

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