Closed
Bug 1066816
Opened 9 years ago
Closed 9 years ago
Allow OT toolkit to set GUID for analytics
Categories
(Hello (Loop) :: Client, defect)
Hello (Loop)
Client
Tracking
(firefox34 fixed, firefox35 fixed)
RESOLVED
FIXED
mozilla35
People
(Reporter: abr, Assigned: abr)
References
Details
Attachments
(1 file, 1 obsolete file)
2.88 KB,
patch
|
standard8
:
review+
lmandel
:
approval-mozilla-aurora+
|
Details | Diff | Splinter Review |
As discussed in Bug 1033587 comment 3, an ongoing source of pain for TokBox is the inability to get clean analytics for the desktop client due to the absence of origins in the context that Loop runs. The latest OpenTok library (2.2.9; see Bug 1066219) incorporates a new API explicitly designed to address this situation. We need a small bit of glue on our side to attach this new API to a persistent data store.
Assignee | ||
Comment 1•9 years ago
|
||
Patch to store OpenTok client GUIDs in a "loop.ot.guid" string pref
Attachment #8488821 -
Flags: review?(standard8)
OT2.2.9 should resolve this issue. Here's some information about modifying GUID: OT.overrideGuidStorage(storageInterface) Assigns the object storageInterface as the storage interface for the entire framework. storageInterface must implement get and set methods to be valid. If storageInterface is invalid then it will be rejected and an exception will be raised. Storage Interface A valid Storage Interface implements set and get methods. set(guid, completionHandler) set takes the guid to set and a function (completionHandler) to call when the set succeeds or fails. The signature of completionHandler is function(error), where erroris Null if no error occurred or a String. get(completionHandler) get takes a function (completionHandler) to call when the guid is either retrieved or an error occurs. The signature of completionHandler is function(error, guid). error is Null if no error occurred or a String. guid is a string representing the retrieved Guid. Usage // Implement our default storage mechanism, which sets/gets a cookie // called 'opentok_client_id' OT.overrideGuidStorage({ get: function(completion) { completion(null, OT.$.getCookie('opentok_client_id')); }, set: function(guid, completion) { OT.$.setCookie('opentok_client_id', guid); completion(null); } }); // Implement a more complicated storage mechanism var ComplexStorage = function() { // Do a bunch of complex stuff, track internal state, etc // expose get and set APIs this.set = function(guid, completion) { AwesomeBackendService.set(guid, function(response) { completion(response.error || null); }); }; this.get = function(completion) { AwesomeBackendService.get(function(response, guid) { completion(response.error || null, guid); }); }; }; OT.overrideGuidStorage(new ComplexStorage());
Comment 3•9 years ago
|
||
Comment on attachment 8488821 [details] [diff] [review] Allow OT toolkit to set GUID for analytics Review of attachment 8488821 [details] [diff] [review]: ----------------------------------------------------------------- r=Standard8 with the comment extended. ::: browser/components/loop/content/js/conversation.jsx @@ +409,5 @@ > // Do the initial L10n setup, we do this before anything > // else to ensure the L10n environment is setup correctly. > mozL10n.initialize(navigator.mozLoop); > > + // Plug in an alternate client ID mechanism Lets just extend the comment slightly: "... as localStorage and cookies don't work in the conversation window"
Attachment #8488821 -
Flags: review?(standard8) → review+
Assignee | ||
Comment 4•9 years ago
|
||
https://hg.mozilla.org/integration/fx-team/rev/ecc5cb4dcdfe
Comment 5•9 years ago
|
||
Backed out for: https://tbpl.mozilla.org/php/getParsedLog.php?id=48198564&tree=Fx-Team https://tbpl.mozilla.org/php/getParsedLog.php?id=48200322&tree=Fx-Team remote: https://hg.mozilla.org/integration/fx-team/rev/6f609219f77a
Assignee | ||
Comment 6•9 years ago
|
||
Assignee | ||
Updated•9 years ago
|
Attachment #8488821 -
Attachment is obsolete: true
Assignee | ||
Comment 7•9 years ago
|
||
This should fix the tree burn issue -- checking to make double-sure: https://tbpl.mozilla.org/?tree=Try&rev=ca80038a0035
Assignee | ||
Comment 8•9 years ago
|
||
Comment on attachment 8493373 [details] [diff] [review] Allow OT toolkit to set GUID for analytics Now checks for OT object (and appropriate method) so we don't hose the unit tests.
Attachment #8493373 -
Flags: review?(standard8)
Comment 9•9 years ago
|
||
Comment on attachment 8493373 [details] [diff] [review] Allow OT toolkit to set GUID for analytics So normally we stub in the tests rather than the code, but I looked at this earlier and it is indeed difficult to stub with the way it is. I therefore think we should leave it as you've got it, and we can improve it later.
Attachment #8493373 -
Flags: review?(standard8) → review+
Assignee | ||
Comment 10•9 years ago
|
||
https://hg.mozilla.org/integration/fx-team/rev/f0c025c53090
https://hg.mozilla.org/mozilla-central/rev/f0c025c53090
Status: ASSIGNED → RESOLVED
Closed: 9 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla35
Comment 12•9 years ago
|
||
Deprioritizing this for QE verification. Please needinfo me to request testing.
Flags: qe-verify-
Comment 13•9 years ago
|
||
Comment on attachment 8493373 [details] [diff] [review] Allow OT toolkit to set GUID for analytics Approval Request Comment Uplift request for patches staged and tested on Fig
Attachment #8493373 -
Flags: approval-mozilla-aurora?
Comment 14•9 years ago
|
||
https://hg.mozilla.org/releases/mozilla-aurora/rev/623abe4840e5 https://hg.mozilla.org/releases/mozilla-aurora/rev/1d2300d17d3b
Updated•9 years ago
|
status-firefox34:
--- → fixed
status-firefox35:
--- → fixed
Comment 15•9 years ago
|
||
Comment on attachment 8493373 [details] [diff] [review] Allow OT toolkit to set GUID for analytics I worked with Randell and Maire on uplifting a large number of Loop bugs at once. All of the bugs have been staged on Fig and tested by QE before uplift to Aurora. As well, all of the bugs are isolated to the Loop client. Randell handled the uplift with my approval. I am adding approval to the bug after the fact for bookkeeping.
Attachment #8493373 -
Flags: approval-mozilla-aurora? → approval-mozilla-aurora+
You need to log in
before you can comment on or make changes to this bug.
Description
•