All Products
Search
Document Center

Solve comflict with dependency on fastjson

Last Updated: Mar 10, 2021

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.

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

    1. '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.

    • mPaaS Inside and Portal & Bundle

      1. mpaascomponents {
      2. excludeDependencies = [
      3. "com.alipay.android.phone.thirdparty:fastjson-build"
      4. ]
      5. }