MMKV icon indicating copy to clipboard operation
MMKV copied to clipboard

ANR in MMKV

Open Jack6Wolf opened this issue 6 years ago • 17 comments

The language of MMKV

Java

The version of MMKV

v1.1.0

The platform of MMKV

Android

The installation of MMKV

Maven

ANR Input dispatching timed out (Waiting because no window has focus but there is a focused application that may eventually add a window when it finishes starting up.)

1 com.tencent.mmkv.MMKV.long getMMKVWithID(java.lang.String,int,java.lang.String,java.lang.String)(Native Method)

2 com.tencent.mmkv.MMKV.com.tencent.mmkv.MMKV mmkvWithID(java.lang.String)(MMKV.java:155) 3 com.star.util.mmkv.MMKVUtil.void (java.lang.String)(MMKVUtil.java:39)

Jack6Wolf avatar May 13 '20 05:05 Jack6Wolf

Logs please.

lingol avatar May 13 '20 05:05 lingol

#1 main

Input dispatching timed out

ANR Input dispatching timed out (Waiting because no window has focus but there is a focused application that may eventually add a window when it finishes starting up.)

1 com.tencent.mmkv.MMKV.long getMMKVWithID(java.lang.String,int,java.lang.String,java.lang.String)(Native Method)

2 com.tencent.mmkv.MMKV.com.tencent.mmkv.MMKV mmkvWithID(java.lang.String)(MMKV.java:155) 3 com.star.util.mmkv.MMKVUtil.void (java.lang.String)(MMKVUtil.java:39) 4 com.star.mobile.video.okhttpdns.HttpDnsHelper.com.star.mobile.video.okhttpdns.IpModelBean getIpModelBean(java.lang.String)(HttpDnsHelper.java:162) 5 com.star.mobile.video.androidServices.BackupServices.void handleAction4Login(java.lang.String,java.lang.String,com.star.cms.model.ums.LoginRequest,int)(BackupServices.java:262) 6 com.star.mobile.video.androidServices.BackupServices.void startAction4Login(boolean)(BackupServices.java:138) 7 com.star.mobile.video.activity.WelcomeActivity$1.void onDeviceIdRetrieved(java.lang.String)(WelcomeActivity.java:372) 8 com.star.mobile.video.sharePrefrernces.DeviceSharePre$1.void run()(DeviceSharePre.java:119) 9 android.os.Handler.handleCallback(Handler.java:790) 10 android.os.Handler.dispatchMessage(Handler.java:99) 11 android.os.Looper.loop(Looper.java:164) 12 android.app.ActivityThread.main(ActivityThread.java:6549) 13 java.lang.reflect.Method.invoke(Native Method) 14 com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:438) 15 com.android.internal.os.ZygoteInit.main(ZygoteInit.java:888)

Jack6Wolf avatar May 13 '20 06:05 Jack6Wolf

I mean Logs from Logcat.

lingol avatar May 13 '20 06:05 lingol

抱歉!这是我们线上Bugly平台反馈的!只有这么多信息!

Jack6Wolf avatar May 13 '20 06:05 Jack6Wolf

Well, I can't help you with that limited info.

lingol avatar May 13 '20 06:05 lingol

好吧,你需要的是还原这个bug的所有Logcat日志信息是吧?

Jack6Wolf avatar May 13 '20 06:05 Jack6Wolf

That would be very helpful.

lingol avatar May 13 '20 06:05 lingol

目前我们自己无法还原,我们尽量尝试吧!后续有最新情况会回复您的!谢谢!

Jack6Wolf avatar May 13 '20 07:05 Jack6Wolf

Hi, have you collected helpful logs yet?

lingol avatar May 25 '20 02:05 lingol

抱歉,目前仍然没有!

On 5/13/2020 13:58,Guo Ling[email protected] wrote:

Logs please.

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub, or unsubscribe.

Jack6Wolf avatar May 25 '20 05:05 Jack6Wolf

Still no updates?

lingol avatar Jun 15 '20 02:06 lingol

If there's still no more information, I will have to close this inactive issue.

lingol avatar Jun 22 '20 13:06 lingol

抱歉,目前仍然没有! On 5/13/2020 13:58,Guo Ling[email protected] wrote: Logs please. — You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub, or unsubscribe.

我也遇到了这个问题 由bugly反馈 你有解决方案吗

JackliJ avatar Mar 09 '22 03:03 JackliJ

抱歉,目前仍然没有! On 5/13/2020 13:58,Guo Ling[email protected] wrote: Logs please. — You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub, or unsubscribe.

我也遇到了这个问题 由bugly反馈 你有解决方案吗

The requirement is still the same. We need logs from MMKV when this ANR happens, to further diagnose the problem.

lingol avatar Mar 09 '22 03:03 lingol

Any prefix of mmkv log or ways make mmkv to print more log? Sadly I can't find any log printed from mmkv expect anr stack

xxrlzzz avatar Sep 27 '22 06:09 xxrlzzz

https://blog.csdn.net/xiaobaaidaba123/article/details/127834494?spm=1001.2014.3001.5501 4. com.tencent.mmkv.MMKV.getMMKVWithID ANR

this helps me : preload can avoid om.tencent.mmkv.MMKV.long getMMKVWithID anr

mikelhm avatar Mar 12 '23 04:03 mikelhm

We also encounter similar issues. are these logs sufficient? The file size is not large, but it seems to occur more easily when high CPU load and there are muti mmkv files to open, such as during a cold launch.

The language of MMKV Java

The version of MMKV v1.2.12

The platform of MMKV Android

"main" prio=5 tid=1 Native | group="main" sCount=1 ucsCount=0 flags=1 obj=0x715af0c8 self=0xb4000070e7a8bc00 | sysTid=13702 nice=-10 cgrp=default sched=0/0 handle=0x718c9874f8 | state=S schedstat=( 1266727187 524768432 1665 ) utm=63 stm=62 core=3 HZ=100 | stack=0x7fd6532000-0x7fd6534000 stackSize=8188KB | held mutexes= native: #00 pc 0000000000088270 /apex/com.android.runtime/lib64/bionic/libc.so (syscall+32) Retrace Result: () native: #01 pc 000000000028dc74 /apex/com.android.art/lib64/libart.so (art::ConditionVariable::WaitHoldingLocks(art::Thread*)+152) Retrace Result: () native: #02 pc 00000000004abc28 /apex/com.android.art/lib64/libart.so (art::JNI::NewStringUTF(_JNIEnv*, char const*)+696) Retrace Result: () native: #03 pc 00000000000094d8 /data/app/~~mnoaCV6ygWNYwnSdMAQEMg==/com.android.lark-BgOzZjlUV9t5VuaSLSGHsQ==/lib/arm64/libmmkv.so (???) Retrace Result: () native: #04 pc 000000000001b5b0 /data/app/~~mnoaCV6ygWNYwnSdMAQEMg==/com.android.lark-BgOzZjlUV9t5VuaSLSGHsQ==/lib/arm64/libmmkv.so (???) Retrace Result: () native: #05 pc 0000000000020504 /data/app/~~mnoaCV6ygWNYwnSdMAQEMg==/com.android.lark-BgOzZjlUV9t5VuaSLSGHsQ==/lib/arm64/libmmkv.so (???) Retrace Result: () native: #06 pc 00000000000219f8 /data/app/~~mnoaCV6ygWNYwnSdMAQEMg==/com.android.lark-BgOzZjlUV9t5VuaSLSGHsQ==/lib/arm64/libmmkv.so (???) Retrace Result: () native: #07 pc 00000000000220a0 /data/app/~~mnoaCV6ygWNYwnSdMAQEMg==/com.android.lark-BgOzZjlUV9t5VuaSLSGHsQ==/lib/arm64/libmmkv.so (???) Retrace Result: () native: #08 pc 0000000000013ed8 /data/app/~~mnoaCV6ygWNYwnSdMAQEMg==/com.android.lark-BgOzZjlUV9t5VuaSLSGHsQ==/lib/arm64/libmmkv.so (???) Retrace Result: () native: #09 pc 0000000000014730 /data/app/~~mnoaCV6ygWNYwnSdMAQEMg==/com.android.lark-BgOzZjlUV9t5VuaSLSGHsQ==/lib/arm64/libmmkv.so (???) Retrace Result: () native: #10 pc 000000000000633c /data/app/~~mnoaCV6ygWNYwnSdMAQEMg==/com.android.lark-BgOzZjlUV9t5VuaSLSGHsQ==/lib/arm64/libmmkv.so (???) Retrace Result: () at com.tencent.mmkv.MMKV.getMMKVWithID(MMKV.java) at com.tencent.mmkv.MMKV.mmkvWithID(MMKV.java:328) at com.tencent.mmkv.MMKV.getMMKVWithID(MMKV.java) at com.tencent.mmkv.MMKV.mmkvWithID(MMKV.java:328)

beefeng avatar Jul 17 '24 11:07 beefeng