Kevin Posted August 20, 2018 Share Posted August 20, 2018 Hi, Anybody got memcached working with PrestaShop 1.7.4.2? First of all pressing the Test button will always result in a red box, looks like it's not validated although it is and it's working. After saving and trying to load the frontpage i get the following error: FatalErrorException Error: Maximum execution time of 60 seconds exceeded in CacheMemcached.php line 94 If i debug i see that the set works a lot of times but at one moment it fails(maybe when the set is too big?). Anybody knows how to solve this? Thanks, Kevin Link to comment Share on other sites More sharing options...
Kevin Posted August 20, 2018 Author Share Posted August 20, 2018 So it looks like it breaks as soon as it tries to set an array with 8561 records.. Anybody has an idea what to do? Link to comment Share on other sites More sharing options...
Kevin Posted August 20, 2018 Author Share Posted August 20, 2018 For everyone experiencing this problem. It seems memcached cannot handle too large arrays. PrestaShop doesn't check for this. Solution would be to change the set function of the CacheMemcached.php class to something like: /** * @inheritdoc */ public function set($key, $value, $ttl = 0) { if(sizeof($value) <= 2000){ return $this->_set($key, $value, $ttl); }else{ return false; } } Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now