Admob ad request causes deadlock and application hang.

175 views
Skip to first unread message

Bogumil

unread,
Feb 10, 2015, 5:42:06 PM2/10/15
to google-adm...@googlegroups.com
I'm using com.google.android.gms:play-services-ads:6.5.87

Sometimes, my application hangs and I suppose that it is caused by admob ad request. Here is part of the trace:

Could it be a bug in admob?

"AsyncTask #1" prio=5 tid=13 WAIT
  | group="main" sCount=1 dsCount=0 obj=0xa543b1f0 self=0xb953fb88
  | sysTid=1727 nice=10 sched=0/0 cgrp=[fopen-error:2] handle=-1186335736
  | state=S schedstat=( 4487156 45244807 24 ) utm=0 stm=0 core=0
  at java.lang.Object.wait(Native Method)
  - waiting on <0xa5440838> (a java.lang.VMThread) held by tid=13 (AsyncTask #1)
  at java.lang.Thread.parkFor(Thread.java:1205)
  at sun.misc.Unsafe.park(Unsafe.java:325)
  at java.util.concurrent.locks.LockSupport.park(LockSupport.java:159)
  at java.util.concurrent.locks.AbstractQueuedSynchronizer$ConditionObject.await(AbstractQueuedSynchronizer.java:2019)
  at java.util.concurrent.LinkedBlockingQueue.take(LinkedBlockingQueue.java:413)
  at com.google.android.gms.common.b.a(SourceFile:56)
  at com.google.android.gms.ads.identifier.a.a(SourceFile:376)
  at com.google.android.gms.ads.identifier.a.a(SourceFile:188)
  at com.google.android.gms.ads.identifier.a.a(SourceFile:173)
  at com.google.android.a.u.a(SourceFile:79)
  at com.google.android.a.u.doInBackground(SourceFile:75)
  at android.os.AsyncTask$2.call(AsyncTask.java:287)
  at java.util.concurrent.FutureTask.run(FutureTask.java:234)
  at android.os.AsyncTask$SerialExecutor$1.run(AsyncTask.java:230)
  at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1080)
  at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:573)
  at java.lang.Thread.run(Thread.java:841)

"AdWorker #2" prio=5 tid=18 WAIT
  | group="main" sCount=1 dsCount=0 obj=0xa5475e58 self=0xb949b980
  | sysTid=1723 nice=10 sched=0/0 cgrp=[fopen-error:2] handle=-1186349592
  | state=S schedstat=( 574827878 55375421 101 ) utm=55 stm=2 core=0
  at java.lang.Object.wait(Native Method)
  - waiting on <0xa5418df8> (a java.lang.VMThread) held by tid=18 (AdWorker #2)
  at java.lang.Thread.parkFor(Thread.java:1205)
  at sun.misc.Unsafe.park(Unsafe.java:325)
  at java.util.concurrent.locks.LockSupport.park(LockSupport.java:159)
  at java.util.concurrent.locks.AbstractQueuedSynchronizer$ConditionObject.await(AbstractQueuedSynchronizer.java:2019)
  at java.util.concurrent.LinkedBlockingQueue.take(LinkedBlockingQueue.java:413)
  at java.util.concurrent.ThreadPoolExecutor.getTask(ThreadPoolExecutor.java:1013)
  at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1073)
  at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:573)
  at java.lang.Thread.run(Thread.java:841)

"AdWorker #1" prio=5 tid=17 WAIT
  | group="main" sCount=1 dsCount=0 obj=0xa5455340 self=0xb94707e0
  | sysTid=1721 nice=10 sched=0/0 cgrp=[fopen-error:2] handle=-1186526136
  | state=S schedstat=( 40900162 292769262 85 ) utm=4 stm=0 core=0
  at java.lang.Object.wait(Native Method)
  - waiting on <0xa5455490> (a java.lang.VMThread) held by tid=17 (AdWorker #1)
  at java.lang.Thread.parkFor(Thread.java:1205)
  at sun.misc.Unsafe.park(Unsafe.java:325)
  at java.util.concurrent.locks.LockSupport.park(LockSupport.java:159)
  at java.util.concurrent.locks.AbstractQueuedSynchronizer$ConditionObject.await(AbstractQueuedSynchronizer.java:2019)
  at java.util.concurrent.LinkedBlockingQueue.take(LinkedBlockingQueue.java:413)
  at java.util.concurrent.ThreadPoolExecutor.getTask(ThreadPoolExecutor.java:1013)
  at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1073)
  at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:573)
  at java.lang.Thread.run(Thread.java:841)

"pool-2-thread-1" prio=5 tid=16 WAIT
  | group="main" sCount=1 dsCount=0 obj=0xa5410050 self=0xb9443c10
  | sysTid=1720 nice=10 sched=0/0 cgrp=[fopen-error:2] handle=-1186709384
  | state=S schedstat=( 2298606 19581643 33 ) utm=0 stm=0 core=0
  at java.lang.Object.wait(Native Method)
  - waiting on <0xa5410170> (a java.lang.VMThread) held by tid=16 (pool-2-thread-1)
  at java.lang.Thread.parkFor(Thread.java:1205)
  at sun.misc.Unsafe.park(Unsafe.java:325)
  at java.util.concurrent.locks.LockSupport.park(LockSupport.java:159)
  at java.util.concurrent.locks.AbstractQueuedSynchronizer$ConditionObject.await(AbstractQueuedSynchronizer.java:2019)
  at java.util.concurrent.LinkedBlockingQueue.take(LinkedBlockingQueue.java:413)
  at java.util.concurrent.ThreadPoolExecutor.getTask(ThreadPoolExecutor.java:1013)
  at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1073)
  at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:573)
  at java.lang.Thread.run(Thread.java:841)

Andrew Brogdon (Mobile Ads SDK Team)

unread,
Feb 11, 2015, 4:40:51 PM2/11/15
to google-adm...@googlegroups.com
I'm going to check with one of our engineers on this in order to make sure I give you a correct response.  Would you mind giving me some more information about when you've seen the deadlock?

1) What kind of device are you testing on, and have you seen the issue on more than one?
2) What version of Play Services is installed on the device(s) you're testing with?
3) What is your app doing when you see this happen?

Thanks!

-Andrew

Bogumil

unread,
Feb 13, 2015, 10:57:41 AM2/13/15
to google-adm...@googlegroups.com
Thank you for you answer.

I think that I found the source of a problem. It was not admob causing the deadlock, but google analytics. I found help here:

Thanks,
Bogumil

google-adm...@googlegroups.com

unread,
Feb 17, 2015, 1:34:48 PM2/17/15
to google-adm...@googlegroups.com
No problem.  I'm glad you were able to find the right solution.  Thanks for linking to it, as well.

-Andrew

--

---
You received this message because you are subscribed to the Google Groups "Google Mobile Ads SDK Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-admob-ads-sdk+unsub...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Reply all
Reply to author
Forward
0 new messages