question

ez4nick avatar image
ez4nick asked

No ads to show

This is the output from my logcat: 08-03 11:14:33.784: WARN/AmazonMobileAds AdLoader(11137): Server Message: no results. Try again in 30 seconds; code: 503 08-03 11:15:11.454: WARN/AmazonMobileAds AdLoader(11137): Server Message: no results. Try again in 30 seconds; code: 503 08-03 11:15:22.606: ERROR/AmazonMobileAds AdController(11137): SDK Message: no results. Try again in 18 seconds. 08-03 11:15:22.786: ERROR/AmazonMobileAds AdController(11137): SDK Message: no results. Try again in 18 seconds. 08-03 11:15:34.088: ERROR/AmazonMobileAds AdController(11137): SDK Message: no results. Try again in 7 seconds. 08-03 11:15:39.775: ERROR/AmazonMobileAds AdController(11137): SDK Message: no results. Try again in 1 seconds. 08-03 11:15:39.965: ERROR/AmazonMobileAds AdController(11137): SDK Message: no results. Try again in 1 seconds. 08-03 11:15:43.098: WARN/AmazonMobileAds AdLoader(11137): Server Message: no results. Try again in 30 seconds; code: 503 08-03 11:15:51.277: ERROR/AmazonMobileAds AdController(11137): SDK Message: no results. Try again in 21 seconds. 08-03 11:15:54.380: ERROR/AmazonMobileAds AdController(11137): SDK Message: no results. Try again in 18 seconds. 08-03 11:16:09.516: ERROR/AmazonMobileAds AdController(11137): SDK Message: no results. Try again in 3 seconds. 08-03 11:16:09.777: ERROR/AmazonMobileAds AdController(11137): SDK Message: no results. Try again in 3 seconds. 08-03 11:16:10.708: ERROR/AmazonMobileAds AdController(11137): SDK Message: no results. Try again in 2 seconds. 08-03 11:16:14.281: WARN/AmazonMobileAds AdLoader(11137): Server Message: no results. Try again in 30 seconds; code: 503 08-03 11:17:14.055: WARN/AmazonMobileAds AdLoader(11137): Server Message: no results. Try again in 30 seconds; code: 503 does this just mean that there are no ads to display?
mobile ads
10 |5000

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Pedro avatar image
Pedro answered
If you are outside US, your chances are brim of getting an ad. In fact I am having a very low fill rate also, even inside the US. In any case, you definitely need a fallback network to request when Amazon fails.
10 |5000

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

ez4nick avatar image
ez4nick answered
I am in the US and my fill rate has been very low (about 35%, with admob it was almost always 100%). It is kind of annoying to not have ads that will always appear in test mode like admob does because it is hard to get a feel for how the ads will actually look. do you know if there is a way to get a boolean for ads loaded from the amazon sdk? that way I could load ads from a different network when amazon has no ads
10 |5000

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Pedro avatar image
Pedro answered
You can set a listener and see if the ad succeeded or failed to load. https://developer.amazon.com/sdk/mobileads/event-tracking-and-errors.html Message was edited by: Pedro Ros
10 |5000

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

ez4nick avatar image
ez4nick answered
Thanks for that link but how do you do something in onAdFailedToLoad? That is confusing me. I also found this link: https://developer.amazon.com/sdk/mobileads/with-other-sdks.html#Mediator%20SDK%20Integration which isnt too clear either
10 |5000

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Pedro avatar image
Pedro answered
Ignore the link you posted, thats more advanced stuff. If you use AdMob Mediation, wait for them to integrate properly before diving into those waters. When you request an Ad with Amazon, either onAdFailedToLoad or onAdLoaded will be called. What you will do depends on your code, but most likely something along these lines: when Amazon ad fails to load you will hide Amazon's ad view ( with amazonAd.setVisibility(View.GONE); ) and show some other network (for example AdMob). Then on the next cycle (60s later or something) you try Amazon again (and AdMob also, if you dont have a mediation platform to do it for you) - if it succeeds you hide AdMob and show Amazon. If it fails, you keep Amazon hidden and show AdMob.
10 |5000

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

ez4nick avatar image
ez4nick answered
Ok but here is my issue, how do you actually make something happen when ads fail to load? This is what I have: public interface AdListener{ public void onAdFailedToLoad(AdLayout view, AdError error); AdView AdmobAdview = (AdView) findViewById(R.id.adView); AdmobAdview.loadAd(new com.google.ads.AdRequest()); } however I dont't know how in my oncreate method to call this because the onAdFailedToLoad method is never used as I currently have it. I did set up a listener but I am not sure that it actually is listening for anything now
10 |5000

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Pedro avatar image
Pedro answered
adLayout.setListener(myAdListener); myAdListener could be any class that implements the AdListener interface, or you could even do it inline, like: adLayout.setListener(new AdListener() { ... put methods here ... });
10 |5000

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Sujoy@Amazon avatar image
Sujoy@Amazon answered
@Pedro, thanks a lot for the prompt efforts to clear up the things to ez4nick. @ez4nick, Do you have any further query in the same note?
10 |5000

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

ez4nick avatar image
ez4nick answered
Yes I was able to figure everything out and get it working as expected. thanks everyone
10 |5000

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Karlyle G avatar image
Karlyle G answered
hi we are having same problem in india (mumbai) please advise the next steps
10 |5000

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.