Adding multihost - locking

Adding Unit-Tests for it
This commit is contained in:
Philipp Holzer 2018-07-04 23:37:22 +02:00
parent b07dfbb03f
commit aac94d1d74
No known key found for this signature in database
GPG key ID: 58160D7D6AF942B6
22 changed files with 741 additions and 154 deletions

View file

@ -33,11 +33,11 @@ class DatabaseCacheDriver implements ICacheDriver
return null;
}
public function set($key, $value, $duration = Cache::MONTH)
public function set($key, $value, $ttl = Cache::FIVE_MINUTES)
{
$fields = [
'v' => serialize($value),
'expires' => DateTimeFormat::utc('now + ' . $duration . ' seconds'),
'expires' => DateTimeFormat::utc('now + ' . $ttl . ' seconds'),
'updated' => DateTimeFormat::utcNow()
];