Last modified: 2010-05-15 15:59:45 UTC

Wikimedia Bugzilla is closed!

Wikimedia migrated from Bugzilla to Phabricator. Bug reports are handled in Wikimedia Phabricator.
This static website is read-only and for historical purposes. It is not possible to log in and except for displaying bug reports and their history, links might be broken. See T16159, the corresponding Phabricator task for complete and up-to-date bug report information.
Bug 14159 - Got notice, about MEMCACHE_COMPRESSED constant
Got notice, about MEMCACHE_COMPRESSED constant
Status: RESOLVED FIXED
Product: MediaWiki
Classification: Unclassified
General/Unknown (Other open bugs)
1.11.x
PC Windows XP
: Normal minor (vote)
: ---
Assigned To: Nobody - You can work on this!
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2008-05-17 10:01 UTC by Alexander Obuhovich
Modified: 2010-05-15 15:59 UTC (History)
2 users (show)

See Also:
Web browser: ---
Mobile Platform: ---
Assignee Huggle Beta Tester: ---


Attachments

Description Alexander Obuhovich 2008-05-17 10:01:17 UTC
When I've enabled memcached in LocalSettings.php ($wgMainCacheType = CACHE_MEMCACHED; $wgMemCachedServers = array('127.0.0.1:11211');) there is a php notice showing on every page:

Notice: Constant MEMCACHE_COMPRESSED already defined in <path_here>\includes\memcached-client.php on line 78

Don't know, how to test if memcached is really used, because page load speed doesn't seem to be changed.
Comment 1 Jim Hu 2008-07-07 04:40:00 UTC
I'm also seeing this on Mac OSX with 1.12.0.  Oddly it doesn't complain about the other define statements surrounding line 78.  Looking at the PHP documentation, I am wondering if some installations have MEMCACHE_COMPRESSED predefined.

http://us2.php.net/manual/en/memcache.constants.php

if I insert echo MEMCACHE_COMPRESSED; at line 79, the wiki prints 2.
Comment 2 Alexander Obuhovich 2008-07-07 18:37:54 UTC
Constant is defined by memcached module, that is used by php (e.g. "LoadModule memcached.so" in php.ini). I propose using

if (defined('MEMCACHE_COMPRESSED')) {
  define('MEMCACHE_COMPRESSED ...
}

or not to define constant at all if it is always defined by php module ifself :)
Comment 3 Chad H. 2008-07-08 00:44:02 UTC
Constant renamed in r37295
Comment 4 Brion Vibber 2008-07-09 01:10:38 UTC
Reverted in r37360 -- r37295 changed Memcache::COMPRESSED, not MEMCACHE_COMPRESSED.

In fact I see no sign of MEMCACHE_COMPRESSED in the entire source tree. It appears to have been replaced with the class constant some time since 1.12 branching, making the issue moot.

Note You need to log in before you can comment on or make changes to this bug.


Navigation
Links