Closed
Bug 1457472
Opened 6 years ago
Closed 6 years ago
Support a single storage clearing point in the GeckoView API
Categories
(Toolkit :: Telemetry, enhancement, P2)
Toolkit
Telemetry
Tracking
()
RESOLVED
FIXED
mozilla62
People
(Reporter: Dexter, Assigned: esawin)
References
Details
Attachments
(2 files, 2 obsolete files)
5.14 KB,
patch
|
esawin
:
review+
|
Details | Diff | Splinter Review |
5.70 KB,
patch
|
esawin
:
review+
|
Details | Diff | Splinter Review |
In order to ensure that the meaning of "subsession" is consistent across all the different probe types, we need to make sure that "clear" is called almost at the same time for all of them.
We need to change the GeckoView API so that:
- the snapshotting function returns the data for all the measurement types by taking a snapshot for each of them without calling clear;
- calling nsITelemetry.clearProbes (which is getting exposed in bug 1453591.
Additionally, we could also address:
- removal of the opt-in/opt-out flags for snapshotting: we can always snapshot for opt-in and trust Telemetry to give back the right data based on the flags that are set (which depend on the build and the channel);
- return the snapshot after the initialization topic introduced in bug 1453591 gets notified.
Please note that we didn't have this problem on Desktop as we controlled TelemetrySession and implicitly did that.
Assignee | ||
Comment 1•6 years ago
|
||
Assignee: nobody → esawin
Attachment #8972587 -
Flags: review?(snorp)
Attachment #8972587 -
Flags: review?(nchen)
Assignee | ||
Comment 2•6 years ago
|
||
The telemetry controller now has to wait for the load complete event before handling snapshot requests, support the new GV API, use the unified clear method and default to opt-in telemetry.
Attachment #8972588 -
Flags: review?(nchen)
Attachment #8972588 -
Flags: review?(alessio.placitelli)
Assignee | ||
Comment 3•6 years ago
|
||
Alessio, do you consider this a blocker for bug 1453591? I think with patch 2 we may have a cyclic bug dependency now.
Attachment #8972587 -
Flags: review?(snorp) → review+
Comment 4•6 years ago
|
||
Comment on attachment 8972587 [details] [diff] [review]
0001-Bug-1457472-1.0-Simplify-telemetry-snapshot-API-to-r.patch
Review of attachment 8972587 [details] [diff] [review]:
-----------------------------------------------------------------
::: mobile/android/geckoview/src/main/java/org/mozilla/geckoview/RuntimeTelemetry.java
@@ -16,2 @@
> import android.support.annotation.NonNull;
> import android.support.annotation.Nullable;
Not used
@@ -16,3 @@
> import android.support.annotation.NonNull;
> import android.support.annotation.Nullable;
> import android.util.Log;
Not used
@@ +34,5 @@
> + * The response bundle will contain following snapshots:
> + * - histogram
> + * - keyedHistogram
> + * - scalars
> + * - keyedScalars
This will not be formatted correctly unfortunately. You have to use HTML, e.g.
> <ul>
> <li>histogram</li>
> <li>keyedHistogram</li>
> ...
Attachment #8972587 -
Flags: review?(nchen) → review+
Comment 5•6 years ago
|
||
> This will not be formatted correctly unfortunately. You have to use HTML,
Or use something like <pre>
Comment 6•6 years ago
|
||
Comment on attachment 8972588 [details] [diff] [review]
0002-Bug-1457472-2.0-Adjust-telemetry-controller-to-suppo.patch
Review of attachment 8972588 [details] [diff] [review]:
-----------------------------------------------------------------
::: toolkit/components/telemetry/geckoview/GeckoViewTelemetryController.jsm
@@ +27,5 @@
> * Setup the Telemetry recording flags. This must be called
> * in all the processes that need to collect Telemetry.
> */
> setup() {
> debug `setup`;
Don't need this
Attachment #8972588 -
Flags: review?(nchen) → review+
Reporter | ||
Comment 7•6 years ago
|
||
Comment on attachment 8972588 [details] [diff] [review]
0002-Bug-1457472-2.0-Adjust-telemetry-controller-to-suppo.patch
Review of attachment 8972588 [details] [diff] [review]:
-----------------------------------------------------------------
::: toolkit/components/telemetry/geckoview/GeckoViewTelemetryController.jsm
@@ +89,5 @@
> + */
> + retrieveSnapshots(aClear, aCallback) {
> + debug `retrieveSnapshots`;
> +
> + const dataset = Ci.nsITelemetry.DATASET_RELEASE_CHANNEL_OPTIN;
nit: can you drop a comment here explaining why we're always snapshotting opt-in? Basically, we trust the Telemetry core to only record probes we can record to (opt-in probes if canRecordPreRelease is true, opt-out if canRecordRelease is true). So, even if the snapshot always asks for opt-in, it will just return opt-out stuff if we're on Release. Please note that this is only true in recent versions of Firefox :)
Attachment #8972588 -
Flags: review?(alessio.placitelli) → review+
Reporter | ||
Comment 8•6 years ago
|
||
(In reply to Eugen Sawin [:esawin] from comment #3)
> Alessio, do you consider this a blocker for bug 1453591? I think with patch
> 2 we may have a cyclic bug dependency now.
Whoops, sorry, I almost missed this. I think that bug 1453591 is a blocker for this. I've changed the dependency direction in the bug. I'm planning to land the persistence bug as soon as the code freeze is over, so Monday (I hope :) ).
Assignee | ||
Comment 9•6 years ago
|
||
Addressed comments.
Attachment #8972587 -
Attachment is obsolete: true
Attachment #8974094 -
Flags: review+
Assignee | ||
Comment 10•6 years ago
|
||
Addressed comments.
Attachment #8972588 -
Attachment is obsolete: true
Attachment #8974095 -
Flags: review+
Reporter | ||
Comment 11•6 years ago
|
||
Hey Eugen, bug 1453591 finally landed :) Can we land this as well? Sorry for the delay!
Flags: needinfo?(esawin)
Comment 12•6 years ago
|
||
Pushed by esawin@mozilla.com:
https://hg.mozilla.org/integration/mozilla-inbound/rev/29375577d699
[1.1] Simplify telemetry snapshot API to reflect new implementation constraints. r=snorp,jchen
https://hg.mozilla.org/integration/mozilla-inbound/rev/23532c17a812
[2.1] Adjust telemetry controller to support the simplified GeckoView API, the unified clear method and the snapshot persistence lifecycle. r=Dexter,jchen
Assignee | ||
Updated•6 years ago
|
Flags: needinfo?(esawin)
Comment 13•6 years ago
|
||
bugherder |
https://hg.mozilla.org/mozilla-central/rev/29375577d699
https://hg.mozilla.org/mozilla-central/rev/23532c17a812
Status: NEW → RESOLVED
Closed: 6 years ago
status-firefox62:
--- → fixed
Resolution: --- → FIXED
Target Milestone: --- → mozilla62
Updated•6 years ago
|
You need to log in
before you can comment on or make changes to this bug.
Description
•