diff options
author | Robin Appelman <robin@icewind.nl> | 2023-03-29 18:03:03 +0200 |
---|---|---|
committer | backportbot-nextcloud[bot] <backportbot-nextcloud[bot]@users.noreply.github.com> | 2023-12-22 09:54:13 +0000 |
commit | 6ba6c95bab863197fd2922ac2e83567d643ebecc (patch) | |
tree | c22b45934840a617c9b76fd033604c8e059e3d35 /lib/public | |
parent | fecb3ea41cd9fe2e7f12fdb4b9b9a24845de281a (diff) | |
download | nextcloud-server-6ba6c95bab863197fd2922ac2e83567d643ebecc.tar.gz nextcloud-server-6ba6c95bab863197fd2922ac2e83567d643ebecc.zip |
restore shared lock ttl when releasing
Signed-off-by: Robin Appelman <robin@icewind.nl>
Diffstat (limited to 'lib/public')
-rw-r--r-- | lib/public/IMemcacheTTL.php | 19 |
1 files changed, 18 insertions, 1 deletions
diff --git a/lib/public/IMemcacheTTL.php b/lib/public/IMemcacheTTL.php index 8424e5b2bfa..250e727308b 100644 --- a/lib/public/IMemcacheTTL.php +++ b/lib/public/IMemcacheTTL.php @@ -35,5 +35,22 @@ interface IMemcacheTTL extends IMemcache { * @param int $ttl time to live in seconds * @since 8.2.2 */ - public function setTTL($key, $ttl); + public function setTTL(string $key, int $ttl); + + /** + * Get the ttl for an existing value, in seconds till expiry + * + * @return int|false + * @since 27 + */ + public function getTTL(string $key): int|false; + /** + * Set the ttl for an existing value if the value matches + * + * @param string $key + * @param mixed $value + * @param int $ttl time to live in seconds + * @since 27 + */ + public function compareSetTTL(string $key, $value, int $ttl): bool; } |