Commit graph

7 commits

Author SHA1 Message Date
addshore
846d373c28 Add countUnreadNotifications to WatchedItemStore
This query / logic has been extracted from
ApiQueryUserInfo.

Unit & Integration tests have also been added.

Relating to the task linked this is the last change
needed in this ApiQueryUserInfo!

Bug: T129482
Change-Id: I91aa109416c16cd1f257c9de46669e35d6fd34d7
2016-03-14 16:00:47 +00:00
addshore
0b852c5717 Move countVisitingWatchers to WatchedItemStore
Also adds tests

Bug: T129479
Change-Id: I2868c31fc09121de381d822e8f49194e3022bb42
2016-03-14 15:56:43 +00:00
addshore
6e2d6a0b44 Move counting of watchers to WatchedItemStore
Also adds tests

Bug: T129479
Bug: T129482
Change-Id: I5a465773599cce9f8c9e94847cede6d12282c827
2016-03-14 15:56:16 +00:00
addshore
59e7587ed2 Improve cache assertions in WatchedItemStoreUnitTest
Change-Id: If4b2086cc29fcfc73dee2e9f96591a9e4aa50da9
2016-03-14 15:55:55 +00:00
addshore
8d984cebb2 Uncache things in WatchedItemStore::updateNotificationTimestamp
When the notification timestamp for a LinkTarget is
updated all items relating to that LinkTarget should
be uncached!..

This also switches this class from a BagOStuff to
a HashBagOStuff as this cache index is only maintained
per process..

Change-Id: I5dc58e018a6a4a15903abc1e0b326b4220abc75e
2016-03-14 15:13:19 +00:00
addshore
a683b11b23 Move EmailNotification::updateWatchlistTimestamp to WatchedItemStore
Flow is the only thing remaining that uses this deprecated method.

Change-Id: Iaa4e1e34cb3f2a91c163565fb0107c500e3852d7
2016-03-08 18:44:05 +00:00
addshore
fee0afdc8a Move WatchedItem logic to WatchedItemStore
This also removes assumptions that when a page
in one Namespace should be watched / removed
that the page in the talk / subject ns for the
page should have the same action applied

This should maintain all backward compatability
for the WatchedItem class

This also includes tests written by:
 - WMDE-leszek
 - Addshore

Bug: T127956
Change-Id: Iad9abafe4417bb479151a3bfbee6e1c78a3afe3c
2016-03-08 15:41:22 +00:00