Doubleclick For Publishers (DFP) ListView Performance issue

133 views
Skip to first unread message

Caner Aksoy

unread,
Oct 23, 2017, 11:36:02 AM10/23/17
to Google Mobile Ads SDK Developers
Hi There,

I use ListView in my application with a BaseAdapter. In my baseadapter we have 6 view type and one of them for DFP ads. The issue is when adapter add video ads to listview, application gets slowing down. I do not have any code then regular baseadapter and only video ads creates problems. Simply case is:
  1. Application Starts
  2. Scroll and see video
  3. The scroll a few time up and down until ad video goes out of window and re enter.
After these steps, all application animations getting slower. Even i remove listview and open another fragment app still stay slow. I tried this to 5 or 6 different devices which has different brands and models and android versions.


  • Google Play services SDK version you're integrating with : 11.4.0
  • Version of the Google Play services apk installed on your device : 11.5.18(440-170253583)
  • model and OS version of the device that exhibits the issue : Android 7.0
  • DFP ads : NativeCustomTemplateAd

Bharani Cherukuri (Mobile Ads SDK Team)

unread,
Oct 23, 2017, 4:25:52 PM10/23/17
to Google Mobile Ads SDK Developers
Hello, 

Thank you for providing the details with a detailed explanation. I'd suggest that you take a look at our sample app as a reference for the ListView implementation. If you continue to have an issue with this, would you be able to provide us a sample project of your implementation where the issue is reproducible, so we can take a look and assist you further?

Regards,
Bharani Cherukuri
Mobile Ads SDK Team

Caner Aksoy

unread,
Oct 24, 2017, 4:20:56 AM10/24/17
to Google Mobile Ads SDK Developers
Hello,

We already made our app with your sample app and sample codes and"https://developers.google.com/mobile-ads-sdk/docs/dfp/android/native"  tutorial. In sample app there is no any video. If you add MediaView in your application, i believe your sample app will have the same problem too.

With thanks,
Caner AKSOY


23 Ekim 2017 Pazartesi 23:25:52 UTC+3 tarihinde Bharani Cherukuri (Mobile Ads SDK Team) yazdı:

Bharani Cherukuri (Mobile Ads SDK Team)

unread,
Oct 24, 2017, 3:40:04 PM10/24/17
to Google Mobile Ads SDK Developers
Hello Caner, 

Thank you for getting back to support. It is recommended that you use RecyclerView instead of ListView for better performance and reuse the Native views if possible. You may refer to our sample app as a reference to the Recycler view implementation. This is more of an implementation specific issue, if you continue to have an issue with this, a sample app would be really helpful to debug the issue further. 

Regards,
Bharani Cherukuri
Mobile Ads SDK Team 

On Monday, October 23, 2017 at 11:36:02 AM UTC-4, Caner Aksoy wrote:

Caner Aksoy

unread,
Oct 24, 2017, 4:56:03 PM10/24/17
to Google Mobile Ads SDK Developers
Hi again,

Changing listview is not possible for now but i will try it later. Thanks a lot for your concern. Can you give me some information about MediaView or how to clear it from cache, because documention about it none. In my opinion after i remove the listview, all ads(MediaViews) should be garbage collected or at least videos should be released, but it seems when i put a mediavie in a list item, it stays always there. By the way, after i checked again my performance problem is much more effective on samsung devices :S.

24 Ekim 2017 Salı 22:40:04 UTC+3 tarihinde Bharani Cherukuri (Mobile Ads SDK Team) yazdı:

Bharani Cherukuri (Mobile Ads SDK Team)

unread,
Oct 25, 2017, 3:33:20 PM10/25/17
to Google Mobile Ads SDK Developers
Hi Caner, 

Thank you for contacting us. You may refer to this guide on how to destroy a Native ad which might help with your implementation. As your concern is more implementation specific, I'd suggest that you post your questions on StackOverflow for further assistance.

Regards,
Bharani Cherukuri
Mobile Ads SDK Team

On Monday, October 23, 2017 at 11:36:02 AM UTC-4, Caner Aksoy wrote:

Caner Aksoy

unread,
Oct 26, 2017, 4:16:15 AM10/26/17
to Google Mobile Ads SDK Developers
Hi Bharani,

Thanks for your replay. I will try it myself. As i say before i am using NativeCustomTemplateAd and setNativeAd(this guide) method is not compatible with custom ads. 

25 Ekim 2017 Çarşamba 22:33:20 UTC+3 tarihinde Bharani Cherukuri (Mobile Ads SDK Team) yazdı:

Deepika Uragayala- MobileAds SDK team

unread,
Oct 26, 2017, 3:18:28 PM10/26/17
to Google Mobile Ads SDK Developers
Hi Caner,

Bharani is out of office today and I'll be assisting you with your issue today.

I have not found any performance issues while using our RecyclerView sample apps and Native Advanced AdViews. Now, we would always recommend that you hold onto your AdView from a separate reference, sort of like a cache, and then bind it to your ListView when needed. We would suggest that you do not try to create a new instance each time the item is not in view if the AdView exists. Also, note that as performance cannot be the same across all types of devices so we would recommend that you try to gauge with different devices and also share this with us.

Regards,
Deepika Uragayala
Mobile Ads SDK Team
Reply all
Reply to author
Forward
0 new messages