Add breakdown metrics for BeginNavigatiion
Shunya Shishidonit but Navigation.
You can omit one of two 'i's.
Oh! Thanks for pointing it out. Fixed.
Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |
Code-Review | +1 |
base::ElapsedTimer duration;
{
SCOPED_UMA_HISTOGRAM_TIMER("WebContentsObserver.DidStartNavigation");
observers_.NotifyObservers(&WebContentsObserver::DidStartNavigation,
navigation_handle);
}
base::UmaHistogramTimes(
base::StrCat(
{"WebContentsObserver.DidStartNavigation.",
navigation_handle->IsInMainFrame() ? "MainFrame" : "Subframe"}),
duration.Elapsed());
nit: Perhaps it's better to use one ElapsedTimer.
```
base::ElapsedTimer duration;
observers_.NotifyObservers(&WebContentsObserver::DidStartNavigation,
navigation_handle);
base::TimeDelta elapsed = duration.Elapsed();
base::UmaHistogramTimes("WebContentsObserver.DidStartNavigation", elapsed);
base::UmaHistogramTimes(
base::StrCat(
{"WebContentsObserver.DidStartNavigation.",
navigation_handle->IsInMainFrame() ? "MainFrame" : "Subframe"}),
elapsed);
```
expires_after="2024-12-02">
Shunya Shishido[WARNING] This histogram is expired for more than a month. It might have already stopped reporting. If you're extending this histogram, please be careful of data discontinuity: https://chromium.googlesource.com/chromium/src/+/HEAD/tools/metrics/histograms/README.md#extending.
Please fix.
Actually the fllowing two entries are duplicated.
- WebContentsObserver.DidStartNavigation.{FrameType}
- WebContentsObserver.{Method}
I think you need to merge them into one such as:
- WebContentsObserver.{Method}{FrameType}
And define FrameType like the following.
```
<token key="FrameType">
<variant name=".MainFrame"/>
<variant name=".Subframe"/>
</token>
```
Minoru ChikamuneThanks. Merged them into one entry. Also added `<variant name="" summary="all frames"/>` to`FrameType` because FrameType based breakdown UMAs are reported only for DidStartNavigation.
Thank you. LGTM.
Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |
base::ElapsedTimer duration;
{
SCOPED_UMA_HISTOGRAM_TIMER("WebContentsObserver.DidStartNavigation");
observers_.NotifyObservers(&WebContentsObserver::DidStartNavigation,
navigation_handle);
}
base::UmaHistogramTimes(
base::StrCat(
{"WebContentsObserver.DidStartNavigation.",
navigation_handle->IsInMainFrame() ? "MainFrame" : "Subframe"}),
duration.Elapsed());
nit: Perhaps it's better to use one ElapsedTimer.
```
base::ElapsedTimer duration;
observers_.NotifyObservers(&WebContentsObserver::DidStartNavigation,
navigation_handle);
base::TimeDelta elapsed = duration.Elapsed();
base::UmaHistogramTimes("WebContentsObserver.DidStartNavigation", elapsed);
base::UmaHistogramTimes(
base::StrCat(
{"WebContentsObserver.DidStartNavigation.",
navigation_handle->IsInMainFrame() ? "MainFrame" : "Subframe"}),
elapsed);
```
Done
Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |
Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |
Code-Review | +1 |
bool is_primary_main_frame_for_uma = is_primary_main_frame_;
nit: const bool
<summary>
Can you give the summary attributes to the FrameTypes variants definition, and embed the {FrameType} in the summary so that the description can explain the variants?
Measures the time taken to register navigation throttles in
ditto
Inspect html for hidden footers to help with email filtering. To unsubscribe visit settings. |