Open bbeygel opened 5 years ago
Had the same issues. No error while storing item. Pretty annoying.
I think you both might be running into this issue.
When the expiration time specified is 30 days or more in seconds, Memcache treats the expiration as an absolute date by converting the number of seconds specified to a Unix epoch date. Be careful, because specifying 40 days in seconds will set the expiration to a time in 1970, which will yield unknown results.
After setting value with a half year lifetime value i got a result of true but when trying to get the same value for the same key, nothing was returned.
const time = 60 * 60 * 24 * 7 * 27; this.client.set(key, JSON.stringify(value), time, (err, res) => { if (err) { reject(err); } else { resolve(res); } });
res returns true.