open-webui/backend/open_webui
Classic298 a9adb2b78e
perf: posting in a channel takes seconds when many members are online (#32889)
Every message posted in a channel waited until the server had re-checked the login of every online member of that channel, one connected session at a time with a few database lookups each, before the post went through. In a large channel that added seconds to every single message. The result only decides who gets a notification, and the message is already delivered to everyone before this step, so the check now runs right after the post returns, as the first step of the work that sends notifications and bot replies. Members are re-checked exactly as before, including disconnecting any session whose login is no longer valid.

Postgres 16, standard channel, median time for a post to return:

| Online members | Before | After |
| --- | --- | --- |
| 100 | 0.37 s | 0.03 s |
| 300 | 1.6 s | 0.05 s |
| 1,000 | 3.4 s | 0.10 s |
2026-10-22 07:48:19 +09:00
..
data refac: mv backend files to /open_webui dir 2024-09-04 16:54:48 +02:00
internal fix: requests hang or fail with 503 after pages are closed while loading (#32617) 2026-10-21 03:23:05 +09:00
migrations refac 2026-10-14 18:49:51 +04:00
models perf: changing permissions on a large group is slow (#32883) 2026-10-22 07:08:30 +09:00
retrieval chore: Python 3.12 and Debian 13 base image (#32861) 2026-10-22 04:51:57 +09:00
routers perf: posting in a channel takes seconds when many members are online (#32889) 2026-10-22 07:48:19 +09:00
socket perf: changing permissions on a large group is slow (#32883) 2026-10-22 07:08:30 +09:00
static refac 2026-09-06 17:27:30 -04:00
storage refac 2026-10-05 12:03:19 +04:00
tools refac 2026-10-21 09:53:09 +09:00
utils refac 2026-10-22 07:40:01 +09:00
__init__.py chore: Python 3.12 and Debian 13 base image (#32861) 2026-10-22 04:51:57 +09:00
alembic.ini fix: Alembic CLI commands from failing 2025-08-15 04:17:47 -04:00
config.py refac 2026-10-16 18:58:58 +04:00
constants.py fix: SSO login failures show the email/password error (#31629) 2026-09-30 19:07:49 +04:00
env.py refac 2026-10-01 03:31:20 +04:00
events.py perf: saving a group or changing its members takes seconds when many users are online (#32882) 2026-10-22 07:08:49 +09:00
functions.py fix: pipes and tools get None instead of a file list when nothing is attached (#32380) 2026-10-14 12:18:55 +04:00
main.py feat: let everyone who can use a model pick its model controls (#32860) 2026-10-22 04:44:53 +09:00
tasks.py refac 2026-10-16 04:20:53 +04:00