go to bug id or search bugs for
when working on fixing problems with memcached after upgrading from PHP 5.3.13 to 5.3.15 recently (see bug 62801 I reported) we have discovered that we cannot use older PHP versions with the same memcached server any longer.
A simple situation:
PHP Server 1 has PHP 5.3.6 and cannot be upgraded
PHP Server 2 had PHP 5.3.13 but was upgraded to 5.3.15
Both of those servers connect to the same memcached server and use the same keys. Server 1 is a cron server so it uses CLI and server 2 is a frontend server so we connect via apache.
Before the server 2 upgrade everything was working fine - when we set some key on server 2 we were able to read it from memcached on server 1 without any problems.
After the upgrade each time we want to read on server 1 a key set by server 2 we get PAYLOAD FAILURE message from PHP memcached.
However, when we temporarily moved our cronjobs to a fresh server with 5.3.15, everything went back to normal.
My guess is that it means that some compression method was changed in PHP 5.3.14 or PHP 5.3.15 and users were not informed about it in any changelog.
Breaking backwards compatibility seems to me like a huge deal, something that you either shouldn't do or if you do you should inform about it with huge bold letters.
Along with PHP upgrade libmemcached was upgraded from libmemcached-1.0.2-1.el5.remi.x86_64 to libmemcached-1.0.4-1.el5.remi.x86_64
We set a following 3 options to PHP memcached (on both server 1 and server 2 of course):
$m->setOption( Memcached::OPT_BINARY_PROTOCOL, true));
There should have been a clear information about breaking comatiblity with previous PHP / libmemcached versions.
There was no info at all.
Add a Patch
Add a Pull Request
PHP doesn't include any memcache-specific code at all. So if you keep your
libmemcached and your PHP memcached extension the same from one PHP version to
the next I don't see how this would break. Within PHP 5.3.x we maintain binary
compatibility so there is no need to update your extensions when you update PHP.
This might be something you end up doing due to distro dependencies or
something, but it isn't something that is in any way forced by us.
So, as a test, try running 5.3.15 with the libmemcached library and memcached
extension you are using on the 5.3.6 box. I bet that will work and it means
something likely changed either in libmemcached or in the memcached extension.
Ah, I see, I thought that libmemcached upgrade was an integral part of the PHP upgrade.
I don't really want to test anything here, we're just gonna move our cronjobs to an upgraded PHP and libmemcached, as this seems like a good idea anyway.
Of course the libmemcached changelog also doesn't mention any change... but meh.