Skip to content

andr(example): Prototype a Webview instrumenter - #803

Merged
murki merged 4 commits into
mainfrom
murki/webview-proto
Dec 18, 2025
Merged

murki merged 4 commits into
mainfrom
murki/webview-proto

Conversation

@murki

@murki murki commented Dec 17, 2025

Copy link
Copy Markdown
Contributor

Example of how an android class that instruments webviews could look in our SDK.

Usage:

val webView = view.findViewById<WebView>(R.id.webView)
// Instrument the WebView with bitdrift capture
WebViewCapture.instrument(webView)
webView.loadUrl("https://bitdrift.io/")

Right now it only instruments basic webview.pageLoad events, handling success, and 2 types of errors: connection and http. It models these as a Span with duration, result, etc. Example session: https://timeline.bitdrift.dev/session/3f56ba04-ee59-4ba4-a651-13aeb615b22c?utm_source=sdk&utilization=0&s=logType...is...Span&expanded=3927384652037360634&sf=true
Screenshot 2025-12-17 at 4 10 47 PM

If/when we decide to include this we'd just need to move the WebViewCapture into our SDK module.


  • CHANGELOG.md's "Unreleased" section has been updated, if applicable.

@github-actions

Copy link
Copy Markdown

Size Comparison Report (x86_64)

Metric APK (KB) SO (KB)
Baseline 3374 1252
Current 3374 1252
Difference 0 0

APK size unchanged. SO size unchanged.

@murki murki changed the title andr(example): Prototype a closer example of how a Webview instrumenter could look like andr(example): Prototype a Webview instrumenter Dec 17, 2025
@murki
murki marked this pull request as ready for review December 17, 2025 21:18
@murki
murki merged commit 87e735c into main Dec 18, 2025
16 checks passed
@murki
murki deleted the murki/webview-proto branch December 18, 2025 13:05
@github-actions github-actions Bot locked and limited conversation to collaborators Dec 18, 2025
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants