summaryrefslogtreecommitdiffstats
path: root/config
diff options
context:
space:
mode:
authorszaimen <szaimen@e.mail.de>2022-10-30 13:43:22 +0100
committerBowen Ding <6999708+dbw9580@users.noreply.github.com>2022-11-05 16:03:01 +0800
commitf9e9cd270dc1e6a7a6a7396b2f1af03512f81738 (patch)
tree9275419c3ac5910a5bfa2e742944789971762995 /config
parentc88aabd1252c00dad59f143853042fc05ebc8d40 (diff)
downloadnextcloud-server-f9e9cd270dc1e6a7a6a7396b2f1af03512f81738.tar.gz
nextcloud-server-f9e9cd270dc1e6a7a6a7396b2f1af03512f81738.zip
Limit-number-of-concurrent-preview-generations
Signed-off-by: Bowen Ding <dbw9580@live.com> Signed-off-by: szaimen <szaimen@e.mail.de>
Diffstat (limited to 'config')
-rw-r--r--config/config.sample.php22
1 files changed, 22 insertions, 0 deletions
diff --git a/config/config.sample.php b/config/config.sample.php
index 12bcdba7380..d6e60c40374 100644
--- a/config/config.sample.php
+++ b/config/config.sample.php
@@ -1118,6 +1118,28 @@ $CONFIG = [
* Defaults to ``true``
*/
'enable_previews' => true,
+
+/**
+ * Number of all preview requests being processed concurrently,
+ * including previews that need to be newly generated, and those that have
+ * been generated.
+ *
+ * This should be greater than 'preview_concurrency_new'.
+ * If unspecified, defaults to twice the value of 'preview_concurrency_new'.
+ */
+'preview_concurrency_all' => 8,
+
+/**
+ * Number of new previews that are being concurrently generated.
+ *
+ * Depending on the max preview size set by 'preview_max_x' and 'preview_max_y',
+ * the generation process can consume considerable CPU and memory resources.
+ * It's recommended to limit this to be no greater than the number of CPU cores.
+ * If unspecified, defaults to the number of CPU cores, or 4 if that cannot
+ * be determined.
+ */
+'preview_concurrency_new' => 4,
+
/**
* The maximum width, in pixels, of a preview. A value of ``null`` means there
* is no limit.