prebid / prebid-mobile-android

Prebid Mobile SDK for Android applications
Apache License 2.0
58 stars 82 forks source link

Support Termination Handling API #740

Open takenorim opened 3 months ago

takenorim commented 3 months ago

Is your feature request related to a problem? Please describe. For some reason (e.g. prevent memory usage), app developers may want to terminate WebView(s) intentionally if it becomes unresponsive for a while. So, the main application may want to run WebViewRenderProcess#terminate() towards such webViews (including webView created by Prebid SDK).

Describe the solution you'd like I think this requires all WebViews (created by main app and all other SDKs) to implement WebViewClient.onRenderProcessGone method. So, Prebid SDK also should implement the onRenderProcessGone public method maybe at the AdWebViewClient class.

Additional context I'm assuming the GAM original API integration, but it may be the same thing for all other integration type as well.

shinwan2 commented 3 months ago

I'd like to suggest to also update OM SDK that's used by Prebid to at least 1.4.7. From their changelog.

1.4.7 - 2023-07-07 Gracefully manage WebView render process crash.

justadreamer commented 3 months ago

This is Android specific and would not concern Original API, because in that case the Primary Ad SDK owns the WebViews (usually GMA SDK).

In the case of Rendering API - Prebid SDK manages its WebViews (this is also the case of the mediation adapters use s.a. AppLovin, AdMob etc.) Is the request for the SDK to implement this event handler for the WebViews it owns and expose a callback interface for the app developer - so they can take action?

jsligh commented 3 weeks ago

@takenorim is this any update on this issue?