Ori.livneh has uploaded a new change for review.
https://gerrit.wikimedia.org/r/273954
Change subject: Revert "Prevent duplicate memcached lookups for user record"
......................................................................
Revert "Prevent duplicate memcached lookups for user record"
This reverts commit 7d67b4d9195346e1.
Caused T128246, T128263, T128275.
Change-Id: I639ea59e2d42ffbbf700451074174720f2f45cf4
---
M includes/user/User.php
1 file changed, 5 insertions(+), 11 deletions(-)
git pull ssh://gerrit.wikimedia.org:29418/mediawiki/core
refs/changes/54/273954/1
diff --git a/includes/user/User.php b/includes/user/User.php
index 90c05d8..eb3853a 100644
--- a/includes/user/User.php
+++ b/includes/user/User.php
@@ -458,18 +458,12 @@
}
$cache = ObjectCache::getMainWANInstance();
- $key = $this->getCacheKey( $cache );
-
- $processCache = ObjectCache::getLocalServerInstance( 'hash' );
- $data = $processCache->get( $key );
- if ( !is_array( $data ) ) {
- $data = $cache->get( $key );
- if ( !is_array( $data ) || $data['mVersion'] <
self::VERSION ) {
- // Object is expired
- return false;
- }
- $processCache->set( $key, $data );
+ $data = $cache->get( $this->getCacheKey( $cache ) );
+ if ( !is_array( $data ) || $data['mVersion'] < self::VERSION ) {
+ // Object is expired
+ return false;
}
+
wfDebug( "User: got user {$this->mId} from cache\n" );
// Restore from cache
--
To view, visit https://gerrit.wikimedia.org/r/273954
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings
Gerrit-MessageType: newchange
Gerrit-Change-Id: I639ea59e2d42ffbbf700451074174720f2f45cf4
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/core
Gerrit-Branch: master
Gerrit-Owner: Ori.livneh <[email protected]>
_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits