websupport-sk / pecl-memcache

PHP Extension - Memcache module with support of newer PHP 7.x and PHP 8.x
https://pecl.php.net/package/memcache
Other
328 stars 101 forks source link

get() can return invalid values after a PHP OOM #111

Open WPprodigy opened 1 year ago

WPprodigy commented 1 year ago

If a php request OOM's while requesting a key from memcached, then the next request (using persistent connections) will be given the value for that last request regardless of what key it actually requested. This obviously results in very unfun behavior application-side 😬

I've created a repo for easy replication: https://github.com/WPprodigy/memcache-inconsistency-debugging, using the latest release of this extension.

WPprodigy commented 1 year ago

This is likely the same thing that was reported here: https://bugs.php.net/bug.php?id=74235. I wanted to open up a Github issue to help others that are looking for an explanation to some pretty maddening behavior :)