[3.4.0][线程] 升级线程库和插件版本

This commit is contained in:
renwj
2023-07-17 20:51:49 +08:00
parent e60f6b6271
commit f3d30026ce
4 changed files with 19 additions and 2 deletions

View File

@@ -2,9 +2,12 @@ package com.mogo.eagle.core.function.startup.stageone
import android.content.*
import android.os.Process
import android.os.Trace
import android.util.*
import com.mogo.thread.ext.core.*
import com.mogo.thread.ext.core.config.*
import com.mogo.thread.ext.core.config.priority.*
import com.mogo.thread.ext.core.trace.*
import com.rousetime.android_startup.*
import java.io.*
import java.text.*
@@ -23,6 +26,18 @@ class ThreadOptStartup: AndroidStartup<Boolean>() {
.setPriority("GLThread\\s+\\d+", Process.THREAD_PRIORITY_BACKGROUND)
.setPriority("Dispatch-\\w+", Process.THREAD_PRIORITY_BACKGROUND)
.build())
.traceConfig(TraceConfig.Builder()
.enabled(false)
.trace(object : ITrace {
override fun enter(section: String) {
//Trace.beginSection(section)
//Log.d("TTTTTT", "enter->$section" )
}
override fun exit() {
//Trace.endSection()
}
})
.build())
/*.dump(DumpConfig.Builder()
.dumpLogFilePath(File(context.getExternalFilesDir(null), "thread_dump_log_${ SimpleDateFormat("yyyy-MM-dd-HH-mm-ss", Locale.ROOT).format(Date()) }.txt").absolutePath)
.dumpPeriod(5, SECONDS)