Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Matrix TracePlugin 没有输出具体的耗时调用栈:doFrame #864

Open
lonelyssl opened this issue Sep 1, 2023 · 7 comments
Open

Comments

@lonelyssl
Copy link

lonelyssl commented Sep 1, 2023

在使用TracePlugin进行卡顿方法监控的时候,输出符合条件的卡顿信息中,没有具体的调用方法栈 ,这个是什么情况?求助

maybe happens Jankiness!(56ms) <<<<<<<<<<<<<<<<<<<<<
|* [Status]
|* Scene: com.iclick.LivePlusPlus.features.push.CameraPushActivity
|* Foreground: true
|* Priority: -13 Nice: 0
|* is64BitRuntime: true
AppMethodBeat is close[true].
=========================================================================

Tasks

No tasks being tracked yet.
@lonelyssl
Copy link
Author

demo中也是相同的问题,是自己使用错误,配置有问题还是什么原因哪?
2023-09-01 14:16:10.303 20394-20431/sample.tencent.matrix W/Matrix.EvilMethodTracer: -
>>>>>>>>>>>>>>>>>>>>> maybe happens Jankiness!(125ms) <<<<<<<<<<<<<<<<<<<<<
|* [Status]
|* Scene: sample.tencent.matrix.trace.TestTraceMainActivity
|* Foreground: true
|* Priority: -13 Nice: -10
|* is64BitRuntime: true
AppMethodBeat is close[true].
=========================================================================

@lonelyssl lonelyssl reopened this Sep 1, 2023
@zengyunpeng
Copy link

貌似是项目有bug 可以参考其他反馈, (#844) 但是改进之后还是打印不出堆栈日志,不知道是不是gradle版本的原因导致的

@lonelyssl
Copy link
Author

目前使用的是gradle 4.0.0; 应该使用那个版本的gradle哪?

@tennkou
Copy link

tennkou commented Sep 4, 2023

调用 UIThreadMonitor.init(), 不过这个已经被 deprecated 了。 851

@yangjie10930
Copy link

遇到同样的问题,不知道谁能解答下

@ErfengLi
Copy link

就挺离谱的,TracePlugin中会init UIThreaMonitor,但是增加了一个版本判断:

if (sdkInt < Build.VERSION_CODES.N && willUiThreadMonitorRunning(traceConfig)) {
                    if (!UIThreadMonitor.getMonitor().isInit()) {
                        try {
                            UIThreadMonitor.getMonitor().init(traceConfig);
                        } catch (java.lang.RuntimeException e) {
                            MatrixLog.e(TAG, "[start] RuntimeException:%s", e);
                            return;
                        }
                    }
                }

所以Android version 24以下才好使……如果想用,需要手动init

@wsdydeni
Copy link

遇到同样的问题,不知道谁能解答下

build:gradle:4.0.1 Android14
在plugin start()之前调用 UIThreadMonitor.init() 可以

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

6 participants