Last Comment Bug 722368 - Report slow SQL created from dynamic strings to Telemetry
: Report slow SQL created from dynamic strings to Telemetry
Status: RESOLVED FIXED
[Snappy:P2]
: perf
Product: Toolkit
Classification: Components
Component: Storage (show other bugs)
: Trunk
: All All
: -- normal (vote)
: mozilla14
Assigned To: Vladan Djeric (:vladan)
:
: Marco Bonardo [::mak]
Mentors:
Depends on: 712109
Blocks:
  Show dependency treegraph
 
Reported: 2012-01-30 09:58 PST by Vladan Djeric (:vladan)
Modified: 2012-03-22 06:28 PDT (History)
7 users (show)
See Also:
Crash Signature:
(edit)
QA Whiteboard:
Iteration: ---
Points: ---
Has Regression Range: ---
Has STR: ---


Attachments
Report full SQL strings locally & aggregate private stats for Telemetry, v1 (19.53 KB, patch)
2012-03-01 18:25 PST, Vladan Djeric (:vladan)
taras.mozilla: review-
Details | Diff | Splinter Review
Sample about:telemetry output and corresponding Telemetry Ping report (2.03 KB, text/plain)
2012-03-01 18:42 PST, Vladan Djeric (:vladan)
no flags Details
about-telemetry change (1.73 KB, patch)
2012-03-02 07:13 PST, Vladan Djeric (:vladan)
no flags Details | Diff | Splinter Review
New about-telemetry, v0.9.2 (4.71 KB, application/x-xpinstall)
2012-03-02 07:14 PST, Vladan Djeric (:vladan)
no flags Details
about-telemetry change, v2 (2.41 KB, patch)
2012-03-07 16:26 PST, Vladan Djeric (:vladan)
no flags Details | Diff | Splinter Review
New about-telemetry, v0.9.2 (4.65 KB, application/x-xpinstall)
2012-03-07 16:28 PST, Vladan Djeric (:vladan)
no flags Details
Report full SQL strings locally & aggregate private stats for Telemetry, v2 (21.09 KB, patch)
2012-03-07 16:29 PST, Vladan Djeric (:vladan)
taras.mozilla: review+
Details | Diff | Splinter Review
Sample about:telemetry output, v2 (1.01 KB, text/plain)
2012-03-07 16:30 PST, Vladan Djeric (:vladan)
no flags Details

Description Vladan Djeric (:vladan) 2012-01-30 09:58:41 PST
As a privacy safeguard, we are currently only reporting on the slow execution of prepared SQL statements. Consequently we are missing a lot of time-consuming SQL created from dynamic strings. We should investigate collecting metrics on such SQL and perhaps reporting only its JavaScript call stack instead of the actual SQL string.
Comment 1 Vladan Djeric (:vladan) 2012-03-01 18:25:05 PST
Created attachment 602230 [details] [diff] [review]
Report full SQL strings locally & aggregate private stats for Telemetry, v1
Comment 2 Vladan Djeric (:vladan) 2012-03-01 18:42:42 PST
Created attachment 602234 [details]
Sample about:telemetry output and corresponding Telemetry Ping report
Comment 3 Vladan Djeric (:vladan) 2012-03-02 07:13:21 PST
Created attachment 602352 [details] [diff] [review]
about-telemetry change
Comment 4 Vladan Djeric (:vladan) 2012-03-02 07:14:16 PST
Created attachment 602353 [details]
New about-telemetry, v0.9.2
Comment 5 (dormant account) 2012-03-02 11:19:59 PST
Comment on attachment 602352 [details] [diff] [review]
about-telemetry change

s/fullSlowSQL/debugSlowSQL/. I'm still pondering rest of the stuff
Comment 6 (dormant account) 2012-03-02 11:33:00 PST
Comment on attachment 602234 [details]
Sample about:telemetry output and corresponding Telemetry Ping report

I'm not sure of utility of telling addon dbs apart from non-addon dbs within the ping.

For now we should report a cumulative number like "dynamic query on x.sqlite"

We should also add a toolkit.telemetry.debugSlowSQL=false pref and gate private sql recording on that.
Comment 7 (dormant account) 2012-03-02 16:14:33 PST
Comment on attachment 602230 [details] [diff] [review]
Report full SQL strings locally & aggregate private stats for Telemetry, v1

r- based on irc discussion
Comment 8 Vladan Djeric (:vladan) 2012-03-07 16:26:53 PST
Created attachment 603907 [details] [diff] [review]
about-telemetry change, v2
Comment 9 Vladan Djeric (:vladan) 2012-03-07 16:28:05 PST
Created attachment 603908 [details]
New about-telemetry, v0.9.2
Comment 10 Vladan Djeric (:vladan) 2012-03-07 16:29:15 PST
Created attachment 603909 [details] [diff] [review]
Report full SQL strings locally & aggregate private stats for Telemetry, v2
Comment 11 Vladan Djeric (:vladan) 2012-03-07 16:30:34 PST
Created attachment 603910 [details]
Sample about:telemetry output, v2
Comment 12 (dormant account) 2012-03-09 13:33:46 PST
Comment on attachment 603909 [details] [diff] [review]
Report full SQL strings locally & aggregate private stats for Telemetry, v2

AddonDb -> TrackedDB

+    fullSql.AppendPrintf(" /* addon DB %s */", dbName.BeginReading());

-- is the proper comment prefix for SQL.
s/addon/untracked/
Comment 14 Marco Bonardo [::mak] 2012-03-22 06:28:30 PDT
https://hg.mozilla.org/mozilla-central/rev/b411890365e8

Note You need to log in before you can comment on or make changes to this bug.