Page MenuHomePhabricator

Upstream Schema.js from MobileFrontend to EventLogging
Closed, ResolvedPublic

Description

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

Details

Related Gerrit Patches:
mediawiki/extensions/EventLogging : masterAdd Schema class

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.
Restricted Application added a subscriber: Aklapper. · View Herald TranscriptOct 30 2015, 12:11 AM

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

https://gerrit.wikimedia.org/r/250057

@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.

kaldari removed a subscriber: kaldari.Nov 2 2015, 9:03 PM
Jdlrobson triaged this task as Normal priority.Nov 3 2015, 7:30 PM

Waiting for some responses from @Tgr

Jdlrobson moved this task from Backlog to Tasks on the MobileFrontend board.Nov 4 2015, 4:47 PM

Change 250057 merged by jenkins-bot:
Add Schema class

https://gerrit.wikimedia.org/r/250057

phuedx closed this task as Resolved.Nov 9 2015, 9:18 AM

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