[opt3.0]调整第一阶段初始化的顺序

This commit is contained in:
chenfufeng
2022-12-21 18:09:56 +08:00
parent ae7e608ce0
commit 733c4d3f3d
5 changed files with 8 additions and 11 deletions

View File

@@ -8,8 +8,6 @@ import com.mogo.test.crashreport.CrashReportConstants
class APMStartup : AndroidStartup<Boolean?>() {
override fun create(context: Context): Boolean? {
// bugly
ARouter.getInstance().build(UpgradeReportConstants.PATH).navigation()
// apm
ARouter.getInstance().build(CrashReportConstants.PATH).navigation()
return true
@@ -24,6 +22,6 @@ class APMStartup : AndroidStartup<Boolean?>() {
}
override fun dependenciesByName(): List<String> {
return listOf("com.mogo.launcher.stageone.ARouterStartUp")
return listOf("com.mogo.launcher.stageone.ARouterStartUp", "com.mogo.launcher.stageone.ConfigStartUp")
}
}

View File

@@ -70,8 +70,7 @@ class HttpDnsStartUp : AndroidStartup<Boolean>() {
override fun dependenciesByName(): List<String> {
return listOf(
"com.mogo.launcher.stageone.APMStartup",
"com.mogo.launcher.stageone.ConfigStartUp"
"com.mogo.launcher.stageone.APMStartup"
)
}

View File

@@ -6,8 +6,8 @@ android {
compileSdkVersion rootProject.ext.android.compileSdkVersion
defaultConfig {
applicationId "com.zhidao.adas.magic"
minSdkVersion 21
targetSdkVersion 25
minSdkVersion 27
targetSdkVersion 27
multiDexEnabled true
versionCode 1
versionName "1.0"

View File

@@ -70,7 +70,7 @@ public class ApmCrashReportProvider implements ITestCrashReportProvider {
mLogt = SharedPrefsMgr.getInstance(context).getString(SharedPrefsConstants.LOCATION_LONGITUDE);
// Log.d("liyz", "cityCode = " + mCityCode + " --lat = " +mLat + " --logt = " + mLogt);
//地图版本
String mapSDKVersion = AppUtils.getCustomMapSDKVersion(context);
String mapSDKVersion = DebugConfig.getMapVersion();
map.put("MAP_SDK_VERSION", mapSDKVersion);
map.put("CITYCODE", mCityCode);
map.put("LATITUDE", mLat);
@@ -85,8 +85,8 @@ public class ApmCrashReportProvider implements ITestCrashReportProvider {
return map;
}
});
String mapSDKVersion = AppUtils.getCustomMapSDKVersion(context);
crash.config().setChannel("MAP_SDK_VERSION:"+mapSDKVersion);
String mapSDKVersion = DebugConfig.getMapVersion();
crash.config().setChannel("MAP_SDK_VERSION:" + mapSDKVersion);
//可选可以设置自定义did,不设置会使用内部默认的
String sn = SharedPrefsMgr.getInstance(context).getString("sn");
if (sn != null && !sn.isEmpty()) {

View File

@@ -42,7 +42,7 @@ public class UpgradeReportProvider implements IProvider {
if (sn != null && !sn.isEmpty()) {
Bugly.putUserData(context, "serial", sn);
}
String mapSDKVersion = AppUtils.getCustomMapSDKVersion(context);
String mapSDKVersion = DebugConfig.getMapVersion();
Bugly.putUserData(context, "MAP_SDK_VERSION", mapSDKVersion);
}