Commit graph

27 commits

Author SHA1 Message Date
bsitu 700271500a Bundle message should show diff of all included revisions
bug: 54391
Change-Id: I6c726d9d36e87fb5092b3c3e205e10ae0de557b4
2013-10-02 16:11:11 -07:00
kaldari a4b62d8d82 Fixing More... button so it doesn't always skip a notification
Bug: 53718

Change-Id: I021580b740b90772c98d32850f5f1a2521bd1a14
2013-09-03 11:51:35 -07:00
bsitu bca96e30ed Attempt to fix 'welcome notification' exception
It throws very randomly in job queue for enwiki, about 15 exceptions in 4 hours

Bug: 53425 

Change-Id: I1d7e45e33ffb8df1a91183e263daf007b0affc7f
2013-08-27 23:16:46 +00:00
jenkins-bot a334ca1350 Merge "LIMIT is not a supported DatabaseBase::update option" 2013-06-13 17:24:21 +00:00
jenkins-bot fea4484b68 Merge "Database updates for respecting oversight within Echo" 2013-06-11 00:01:02 +00:00
Erik Bernhardson f38ce97efd Database updates for respecting oversight within Echo
Provides the first step of adding and populating a new database field
for Echo oversight deployment.  The new field is populated via a
maintenance script and Event::loadFromRow will accept both new and old
results.  Everything will still run when the 2 now unused fields are
later dropped from the db.

Bug: 48059
Change-Id: I24d4b61a061f94ed9aaaa6087f33b2ab37f773cd
2013-06-10 14:52:18 -07:00
bsitu 71f250e0c6 (bug 47912) Visiting talk page should mark talk notif as read
This needs some more manual testing and adding unit testing

Change-Id: Iadfe3cf7927d5318f89ba17f067000f9399060af
2013-05-29 20:43:57 -07:00
bsitu e50f5a55a6 (bug 48821) Echo badge count always lags by 1
This bug was introduced during fixing the implicit database transaction,
the badge count logic happens before the transaction completes on idle,
moving the badge count code to only after a successful notification creation
should solve the issue

Change-Id: Ia564ed0d386e7cf2da1af3d23ae83d71ad472df5
2013-05-25 19:44:09 -07:00
Erik Bernhardson 59c5bc4c8d LIMIT is not a supported DatabaseBase::update option
LIMIT on an UPDATE statement is not standard SQL and is not supported by
DatabaseBase::update.

Change-Id: Ibb3b85548b42457dcc1163968152ee65570da25b
2013-05-24 11:40:40 -07:00
jenkins-bot 021a9213be Merge "(bug 48521) Echo should not implicitly commit other transaction" 2013-05-22 19:37:41 +00:00
bsitu 4a581f7882 Make return type consistent
Notification count should return 0 if user has no enabled notification type

Change-Id: Ice8f524349a3b760c00aeac64c3a47ba5ecec8db
2013-05-17 14:16:14 -07:00
bsitu 51aa0de16a (bug 48521) Echo should not implicitly commit other transaction
Change-Id: I30abd7155b12370aea97218080cc8798f7f0df55
2013-05-15 17:36:04 -07:00
bsitu 40d962bf33 Fix notification listing query.
In some rare cases, an event with a bigger event_id may have a smaller timestamp,
in such cases, those records will not get pulled by the existing query, since
it's always filtered by <= notification_timestamp AND < event_id

Change-Id: I61620a9b93331814ad42253ca380a31301555cda
2013-05-13 17:21:31 -07:00
jenkins-bot 9a2f91e18f Merge "(bug 48054) Echo API should use a standard continue parameter" 2013-05-13 23:23:04 +00:00
bsitu c130197682 Add extra security check to Echo API to prevent vandalism
1. Only trigger mark as read if the unread notification count is > 0
1. Add a limit to the number of notification that can be marked as read
2. Only update those records with read_timestamp = null

Change-Id: I12456c504787f45f594ef9283e98d98692956935
2013-05-04 19:58:37 -07:00
bsitu a70208e8fe (bug 48054) Echo API should use a standard continue parameter
Change-Id: I1d5333db4a4d58a1ecfa8dfe562cda5a35093f8b
2013-05-03 18:15:46 -07:00
kaldari 5a4704e357 Only create notifications that are wanted by the recipients
Also moving getUserEnabledEvents from EchoBackend to
NotificationController since it has nothing to do with the backend.

Bug: 47664
Change-Id: I4f9682b861d9f035ae45f206c37ec0ae1c09ab64
2013-04-28 11:09:15 -07:00
bsitu b34e30cefb Fix a possible db cache issue for job runner
Do not cache db object, this may be causing issue for inter wikis

Change-Id: I127fe05c919c1d20d466c7281f01eef1983270de
2013-04-18 16:01:12 -07:00
jenkins-bot 5833846c44 Merge "Add 'Mark all as read' button to overlay" 2013-04-18 18:41:47 +00:00
kaldari 9448c6cab0 Add 'Mark all as read' button to overlay
Button is only shown if there are more unread notifications than
fit in the overlay.

To avoid performance issues, this version only works for cases where
the number of unread notifications is less than the maximum count
(99 currently). Otherwise the button to mark all as read isn't
displayed (it's also limited on the server-side for good measure).

Bug: 47092
Change-Id: Ifcb0a436e2b31062741c441cca239d35ddefa0e1
2013-04-18 00:29:36 -07:00
bsitu a98aaacf38 Add nextSequenceValue() to support dbs like PostGres
Change-Id: I7af8391fc88d0336b83dba449f52709f309b6833
2013-04-17 13:58:13 -07:00
bsitu d44ed993a2 Add email bundling function to Echo notification
* This patch needs intensive testing on Redis delayed job queue
* This patch is -2 mainly for redis/phpredis are not ready on test/test2/mediawiki

To test this locally, you need to:
* set up Redis and phpredis locally
* add the following to localSettings.php
    $wgJobTypeConf['MWEchoNotificationEmailBundleJob'] = array(
        'class'       => 'JobQueueRedis',
        'redisServer' => '127.0.0.1',
        'redisConfig' => array( 'connectTimeout' => 1 ),
        'claimTTL'    => 3600,
        'checkDelay'  => true
    );
* set $wgMainCacheType to CACHE_DB or memcache
* set $wgEchoBundleEmailInterval to smaller number for testing purpose, 0 to disable email bundling

Change-Id: I9313e7f6ed3e13478cec294b5b8408fe8e941faf
2013-04-11 11:25:14 -07:00
bsitu 2be8a547a0 Add external db support to Echo
Change-Id: I84b0d904795d858d88d8e52c22f00d81c0e81303
2013-04-09 17:59:17 -07:00
bsitu 6a3624b0e4 Add web bundling function to Echo notification
* add web bundling feature
* unify event_timestamp with notification_timestamp
* remove echo_subscription
* update article_link to page_link notification with new logic
* remove duplicated function from MWDbEchoEmailBatch since it's defined in parent class

Change-Id: I2fa91c44edb020209b468fe13f894d9db3732e69
2013-04-04 10:53:46 -07:00
bsitu a05cb46922 Excludes user-dismissed events from count
Change-Id: I44e9707ba279a737dadb8c59013d53f3c67a5177
2013-02-14 11:14:08 -08:00
Kaldari af06e26de6 Adding dismiss functionality to special page
Includes new web preferences for Echo

Also adding ability to set dismissability per notification type

Still need to arrange subscription options into a friendly format

Still need to add dismiss functionality to flyout

Change-Id: I484a24b424e69be3640e63b76f82735edae6f13a
2013-02-12 11:33:50 -08:00
bsitu 78ad57d43a Abstracting MySQL in Echo so storage type can be swapped easily
Patch Set 6:
	* remove redundant JobQueueDB because it's the default
	* remove extra ;

Change-Id: I25dc0203ed5be1e4989242a87f4fde9c8799de28
2013-02-08 10:34:50 -08:00