aboutsummaryrefslogtreecommitdiffstats
path: root/lib/public/ISession.php
diff options
context:
space:
mode:
authorJulius Härtl <jus@bitgrid.net>2022-04-26 12:57:58 +0200
committerJulius Härtl <jus@bitgrid.net>2022-08-17 12:10:26 +0200
commit9b4b72826ade5ab1bc7fb06048e62910ef607cd8 (patch)
treeef8d14e06608c0491361eb9d2666f8523647272e /lib/public/ISession.php
parent312b719acf686f51065e83290cd88704d703a50c (diff)
downloadnextcloud-server-9b4b72826ade5ab1bc7fb06048e62910ef607cd8.tar.gz
nextcloud-server-9b4b72826ade5ab1bc7fb06048e62910ef607cd8.zip
Reopen sessions if we need to write to them instead of keeping them open
Sessions are a locking operation until we write close them, so close them early and reopen later in case we want to write to them Signed-off-by: Julius Härtl <jus@bitgrid.net>
Diffstat (limited to 'lib/public/ISession.php')
-rw-r--r--lib/public/ISession.php8
1 files changed, 8 insertions, 0 deletions
diff --git a/lib/public/ISession.php b/lib/public/ISession.php
index 2709e09d4ca..12cd716ec3f 100644
--- a/lib/public/ISession.php
+++ b/lib/public/ISession.php
@@ -84,6 +84,14 @@ interface ISession {
public function clear();
/**
+ * Reopen a session for writing again
+ *
+ * @return bool true if the session was actually reopened, otherwise false
+ * @since 25.0.0
+ */
+ public function reopen(): bool;
+
+ /**
* Close the session and release the lock
* @since 7.0.0
*/