初始化AdMob时:
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.activity_menu);
MobileAds.initialize(getApplicationContext(), "ca-app-pub-123");
...
我的应用程序比平时多花了2秒钟来加载这个Activity并在Log:
中得到了它W/art: Long monitor contention event with owner method=void java.lang.Thread.nativeCreate(java.lang.Thread, long, boolean) from Thread.java:4294967294 waiters=1 for 439ms
>
W/art: Long monitor contention event with owner method=void java.lang.Thread.nativeCreate(java.lang.Thread, long, boolean) from Thread.java:4294967294 waiters=0 for 441ms
>
W/art: Long monitor contention event with owner method=void java.lang.Thread.nativeCreate(java.lang.Thread, long, boolean) from Thread.java:4294967294 waiters=2 for 442ms
>
W/art: Long monitor contention event with owner method=void java.lang.Thread.nativeCreate(java.lang.Thread, long, boolean) from Thread.java:4294967294 waiters=4 for 442ms
>
W/art: Long monitor contention event with owner method=void java.lang.Thread.nativeCreate(java.lang.Thread, long, boolean) from Thread.java:4294967294 waiters=5 for 442ms
>
W/art: Long monitor contention event with owner method=void java.lang.Thread.nativeCreate(java.lang.Thread, long, boolean) from Thread.java:4294967294 waiters=6 for 440ms
如果我删除初始化行,则所有内容都快速运行,而Log中没有任何内容。
(即使出现此错误,广告仍有效,但延迟很烦人)
有人知道这是从哪里来的吗?我清理了项目,但没有任何改变。