Howdy 👋 I just happened to come on here at the right time to ask my question so, great timing 😅
We have a screen where we recalculate and re-render a report when the user changes a form value.
I want to measure the user waiting time, meaning between the user typing (as close to keystroke as possible) to the report being rendered. And there's API calls in the middle of this so ideally I use tracing rather than metrics to capture them underneath.
However we have debounce logic (500ms), so that if a user is making changes in quick succession, we don't fire off several requests.
I'm trying to figure out the best approach here. I could
- start my span after the debounce, but then I'm missing the 500ms after their last change.
- start my span before the debounce, but if for example the user spends, 2000ms typing every 400ms, we are capturing 2000ms extra time they weren't actually waiting
3.start the span before the debounce, but update the start time somehow** (is this possible?)** - start the span before the debounce, but discard and create a new span if the user makes another action (is this possible?)
- I am trying too hard and should approach this problem differently