Skip to content
This repository has been archived by the owner on Apr 26, 2024. It is now read-only.

Commit

Permalink
fixup! config: add option for max pending media uploads
Browse files Browse the repository at this point in the history
Signed-off-by: Sumner Evans <[email protected]>
  • Loading branch information
sumnerevans committed Jun 9, 2023
1 parent b0617e3 commit 156fe69
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 0 deletions.
2 changes: 2 additions & 0 deletions synapse/config/repository.py
Original file line number Diff line number Diff line change
Expand Up @@ -145,6 +145,8 @@ def read_config(self, config: JsonDict, **kwargs: Any) -> None:
config.get("unused_expiration_time", "24h")
)

self.max_pending_media_uploads = config.get("max_pending_media_uploads", 5)

self.media_store_path = self.ensure_directory(
config.get("media_store_path", "media_store")
)
Expand Down
1 change: 1 addition & 0 deletions synapse/media/media_repository.py
Original file line number Diff line number Diff line change
Expand Up @@ -80,6 +80,7 @@ def __init__(self, hs: "HomeServer"):
self.max_upload_size = hs.config.media.max_upload_size
self.max_image_pixels = hs.config.media.max_image_pixels
self.unused_expiration_time = hs.config.media.unused_expiration_time
self.max_pending_media_uploads = hs.config.media.max_pending_media_uploads

Thumbnailer.set_limits(self.max_image_pixels)

Expand Down

0 comments on commit 156fe69

Please sign in to comment.