Page MenuHomePhabricator

Upstream Schema.js from MobileFrontend to EventLogging
Closed, ResolvedPublic


Related Articles would like to log some events. MobileFrontend already has the Schama class which can be used by Related Articles too. This change would allow us not to pull code from MobileFrontend when the user is viewing the desktop site.

Schema.js should be updated to be an OOjs class and packaged in EventLogging. This would provide a common frontend API for beacon support and logging to servers and handling things such as sampling.

This would be useful for RelatedArticles, Gather, MobileFrontend and QuickSurveys

Event Timeline

bmansurov raised the priority of this task from to Needs Triage.
bmansurov updated the task description. (Show Details)
bmansurov added a subscriber: bmansurov.

Change 250057 had a related patch set uploaded (by Bmansurov):
Add Schema class

@Nuria brings up valid concerns about storing events in $storage and logging them when the user agent fully loads the next page.

I can't remember where exactly but we've had this conversation before around MediaWiki-extensions-GettingStarted and again (including mentions of both GS and MobileFrontend) in T44815.

I guess we migrate MF to use the upstreamed class – sans navigator.sendBeacon fallback – ASAP once it's merged /cc @Jdlrobson.

Yup. I've added a few more comments on the patchset. Baha let us know if you have any questions.

Jdlrobson triaged this task as Medium priority.Nov 3 2015, 7:30 PM

This task tracked a technical background-ish task. I'm signing this off in @Jdlrobson's absence.