Page MenuHomePhabricator

Echo notification table indexes don't support the new feature changes
Open, HighPublic

Description

Author: bsitu

Description:

  1. Notification creation timestamps is not part of the composite index for retrieving unread notifications. Ordering by notification_timestamp for unread notification may cause problem
  1. We now add filtering by notification types ( eg. flow vs others ), we may want to denormalize echo_notification by adding event_type and add this field to the indexes that needs the filtering.

Version: master
Severity: normal

Details

Reference
bz70363

Event Timeline

bzimport raised the priority of this task from to Needs Triage.Nov 22 2014, 3:46 AM
bzimport added a project: Notifications.
bzimport set Reference to bz70363.
bzimport added a subscriber: Unknown Object (MLST).
bzimport created this task.Sep 3 2014, 7:33 PM
EBernhardson triaged this task as High priority.Feb 25 2015, 6:48 PM
Legoktm moved this task from Backlog to Needs plan on the Notifications board.Jul 6 2015, 8:13 AM
Restricted Application added a project: Collaboration-Team-Triage. · View Herald TranscriptJul 6 2015, 8:13 AM

I think #1 will be fixed by https://gerrit.wikimedia.org/r/#/c/274690/:

CREATE INDEX /*i*/echo_notification_user_base_read_timestamp_timestamp ON /*_*/echo_notification (no
tification_user, notification_bundle_base, notification_read_timestamp, notification_timestamp, noti
fication_event);
Restricted Application added a subscriber: Aklapper. · View Herald TranscriptMar 31 2016, 11:17 PM
DannyH removed a subscriber: DannyH.Apr 2 2016, 8:24 AM

#2 is not done, but could be a good idea.

In light of T143964: Paginate notifications by event ID, not timestamp, I think we should not add notification_timestamp to the unread index, but just notification_event.

Restricted Application added a project: Growth-Team. · View Herald TranscriptJul 18 2018, 6:44 PM
SBisson moved this task from Inbox to Triaged but Future on the Growth-Team board.Jul 20 2018, 5:58 PM