Closed Bug 1021922 Opened 6 years ago Closed 6 years ago

Record telemetry for browser database operations

Categories

(Firefox for Android :: Data Providers, defect)

All
Android
defect
Not set

Tracking

()

RESOLVED FIXED
Firefox 33
Tracking Status
firefox32 --- fixed
firefox33 --- fixed
fennec + ---

People

(Reporter: rnewman, Assigned: rnewman)

Details

Attachments

(1 file, 1 obsolete file)

As far as I can tell, we don't do this, so we don't know how much time we spend in awesomebar queries, recording history items, etc.

We should, so we know how to prioritize performance work.

There's a related set of bugs that I won't file yet, which is a task-oriented version of this: how long does it take to show awesomebar results after the user presses a key? Etc.

I'd like for us to get this into 32.
Oh hey, we already have at least one relevant unused histogram:

  "FENNEC_AWESOMEBAR_ALLPAGES_EMPTY_TIME": {
    "expires_in_version": "never",
    "kind": "exponential",
    "low": 10,
    "high": "20000",
    "n_buckets": 20,
    "description": "Fennec: Time for the Awesomebar Top Sites query to return with no filter set (ms)",
    "cpp_guard": "ANDROID"
  },
Who should I tag for a sanity check on Histogram.json?
Attachment #8437231 - Flags: review?(mark.finkle)
Assignee: nobody → rnewman
Status: NEW → ASSIGNED
Verified this patch by hand.
Attachment #8437416 - Flags: review?(mark.finkle)
Attachment #8437231 - Attachment is obsolete: true
Attachment #8437231 - Flags: review?(mark.finkle)
Comment on attachment 8437416 [details] [diff] [review]
Record telemetry for browser database operations. v2

Looks OK. I wouldn't mind seeing the Log.d calls removed. I think we are getting too chatty in logcat.

Also, see bug 966485 for cleanup/fixup too. I believe we don't think we can track about:home startup speed anymore.
Attachment #8437416 - Flags: review?(mark.finkle) → review+
Pushed without logging:

https://hg.mozilla.org/integration/fx-team/rev/515dbeff1513
Flags: needinfo?(rnewman)
I noticed debug logging in https://tbpl.mozilla.org/php/getParsedLog.php?id=41472231&tree=Fx-Team:

14:25:47     INFO -  06-10 14:21:05.933 D/GeckoGlobalHistory(  424): GlobalHistory.add took 4771msec.
14:25:47     INFO -  06-10 14:21:05.963 D/GeckoGlobalHistory(  424): GlobalHistory.update took 36msec.
14:25:47     INFO -  06-10 14:21:06.003 D/GeckoGlobalHistory(  424): GlobalHistory.add took 37msec.
14:25:47     INFO -  06-10 14:21:06.043 D/GeckoGlobalHistory(  424): GlobalHistory.update took 40msec.
14:25:47     INFO -  06-10 14:21:06.043 W/GeckoGlobalHistory(  424): Rebuilding visited link set...
14:25:47     INFO -  06-10 14:21:06.742 D/GeckoGlobalHistory(  424): GlobalHistory.add took 26msec.
14:25:47     INFO -  06-10 14:21:13.502 D/GeckoGlobalHistory(  424): GlobalHistory.update took 6509msec.
14:25:47     INFO -  06-10 14:21:13.532 D/GeckoGlobalHistory(  424): GlobalHistory.add took 35msec.
14:25:47     INFO -  06-10 14:21:13.542 D/GeckoGlobalHistory(  424): GlobalHistory.update took 12msec.
14:25:47     INFO -  06-10 14:21:13.582 D/GeckoGlobalHistory(  424): GlobalHistory.add took 32msec.
14:25:47     INFO -  06-10 14:21:13.642 D/GeckoGlobalHistory(  424): GlobalHistory.update took 58msec.
14:25:47     INFO -  06-10 14:21:13.652 W/GeckoGlobalHistory(  424): Rebuilding visited link set...
14:25:47     INFO -  06-10 14:21:20.412 D/GeckoGlobalHistory(  424): GlobalHistory.add took 4333msec.
14:25:47     INFO -  06-10 14:21:20.432 D/GeckoGlobalHistory(  424): GlobalHistory.update took 19msec.
14:25:47     INFO -  06-10 14:21:20.452 D/GeckoGlobalHistory(  424): GlobalHistory.add took 28msec.
14:25:47     INFO -  06-10 14:21:20.472 D/GeckoGlobalHistory(  424): GlobalHistory.update took 15msec.
14:25:47     INFO -  06-10 14:21:20.512 D/GeckoGlobalHistory(  424): GlobalHistory.add took 38msec.
14:25:47     INFO -  06-10 14:21:20.532 D/GeckoGlobalHistory(  424): GlobalHistory.update took 20msec.

Is everything okay there? (Noticed this in bug 1023568.)
Piss, missed touching one file when I reduced logging. Will land a follow-up.

But still, leaving in the logging is useful: those are some terrifying extremes, and some disappointing averages!
Flags: needinfo?(rnewman)
https://hg.mozilla.org/mozilla-central/rev/515dbeff1513
Status: ASSIGNED → RESOLVED
Closed: 6 years ago
Resolution: --- → FIXED
Target Milestone: --- → Firefox 33
Comment on attachment 8437416 [details] [diff] [review]
Record telemetry for browser database operations. v2

[Approval Request Comment]
Bug caused by (feature/regressing bug #): 
  None. We want more data on browser DB perf issues.

User impact if declined: 
  None.

Testing completed (on m-c, etc.): 
  Landed on m-c. Tested locally.

Risk to taking this patch (and alternatives if risky): 
  Should be slim. Adds new histograms and writes to them.

String or IDL/UUID changes made by this patch:
  None.
Attachment #8437416 - Flags: approval-mozilla-aurora?
tracking-fennec: ? → +
Update on approval request?
Flags: needinfo?(sledru)
Comment on attachment 8437416 [details] [diff] [review]
Record telemetry for browser database operations. v2

Aurora approval granted. (Sorry for the delay.) Thanks for cleaning up some unused Telemetry probes.
Attachment #8437416 - Flags: approval-mozilla-aurora? → approval-mozilla-aurora+
Flags: needinfo?(sledru)
You need to log in before you can comment on or make changes to this bug.