Open WebUI is the fastest way I know to give a team a private, ChatGPT-style interface over Amazon Bedrock. Run it on your laptop and it just works. Put it behind a load balancer with a few hundred people hitting it at once and it falls over in ways that aren’t obvious from the docs.

The reason is simple: the defaults assume one process, one user, one machine. Local SQLite-backed vector store. Files on local disk. A 40-thread pool. An LLM call every time you pause typing.

I built a reference deployment on EKS (Open WebUI, LiteLLM as the OpenAI-compatible proxy, Aurora PostgreSQL with pgvector, ElastiCache, S3, all Terraform) and kept a running list of every environment variable I changed from the default. Here’s that list, grouped by the problem each change solves.

Problem 1: Multiple pods have to share state

The moment you run more than one replica, anything stored in a single pod’s memory or disk becomes a bug. A user’s websocket lands on pod A, their next request lands on pod B, and things get weird.

VariableDefaultSet toWhy
WEBSOCKET_MANAGERnoneredisWebsocket state shared across pods
REDIS_CLUSTER / WEBSOCKET_REDIS_CLUSTERfalsetrueElastiCache Serverless is a cluster; without these, connections fail
VECTOR_DBchromapgvectorChroma is SQLite-backed and not safe across pods
STORAGE_PROVIDERlocals3An upload on one pod is invisible to the others otherwise
WEBUI_SECRET_KEYgeneratedshared K8s secretEvery pod must sign and verify the same JWTs

The REDIS_CLUSTER one cost me the most time. The error doesn’t tell you “you’re talking to a cluster.” It just fails.

Problem 2: Concurrency limits you don’t know you have

VariableDefaultSet toWhy
THREAD_POOL_SIZE40 threads2000The default pool exhausts quickly and the app stalls
UVICORN_WORKERS11Left alone on purpose: scale with pod replicas, not workers per pod
CHAT_RESPONSE_STREAM_DELTA_CHUNK_SIZE17Send 7 tokens per SSE event instead of 1
ENABLE_CHAT_RESPONSE_BASE64_IMAGE_URL_CONVERSIONfalsetrueMove big base64 images to S3 URLs instead of shipping them through Redis and the DB

The thread pool is the big one. Open WebUI does a lot of blocking work in that pool, and 40 threads disappear fast when everyone is streaming at once. The symptom looks like the model is slow. It isn’t. The app is queuing behind its own threads.

Streaming one token per event is lovely on a laptop. At scale it’s a lot of tiny events for every pod and every browser to process. Batching 7 at a time is invisible to users and noticeably cheaper on CPU.

Problem 3: The database connection pool

VariableDefaultSet toWhy
DATABASE_POOL_SIZESQLAlchemy default10Explicit per-pod pool, no unbounded growth
DATABASE_POOL_MAX_OVERFLOW020Headroom for spikes before requests queue
DATABASE_ENABLE_SESSION_SHARINGfalsetrueReuse sessions across requests
ENABLE_REALTIME_CHAT_SAVEfalsefalseLeft off on purpose: on writes every token to the database

Do the math before you set the pool: pods times (pool size plus overflow) has to fit inside what your Aurora capacity allows. Autoscaling the app tier without thinking about this just moves the bottleneck to the database.

Problem 4: Background LLM calls you’re paying for

Open WebUI quietly makes a lot of extra model calls. On a laptop you never notice. Across a whole company it’s real money and real quota.

VariableDefaultSet toWhy
ENABLE_AUTOCOMPLETE_GENERATIONtruefalseFires a model call on every pause while typing
ENABLE_FOLLOW_UP_GENERATIONtruefalseOne extra call per response
ENABLE_TAGS_GENERATIONtruefalseOne extra call per new chat
TASK_MODEL / TASK_MODEL_EXTERNALmain modelClaude HaikuTitles and query generation don’t need your biggest model
ENABLE_BASE_MODELS_CACHE + MODELS_CACHE_TTLoff / 1on / 300Stop polling the proxy for the model list every second

The task model is the one I’d change first on any deployment. Nobody needs Opus to write a chat title.

Problem 5: RAG that’s kind to your quota

VariableDefaultSet toWhy
RAG_EMBEDDING_BATCH_SIZE1100100 chunks per embedding call instead of 1
RAG_EMBEDDING_CONCURRENT_REQUESTSunlimited100Cap per pod so a big upload can’t eat your Bedrock quota
RAG_SYSTEM_CONTEXTfalsetruePut retrieved context in the system message so prompt caching can kick in
RAG_WEB_SEARCH_BYPASS_EMBEDDINGfalsetrueDon’t embed throwaway web results
CHUNK_SIZE / CHUNK_OVERLAP1000 / 1001600 / 200More context per chunk, fewer split sentences
RAG_TOP_K310Give the reranker more to work with

The concurrency cap is about quota math: pods times concurrent requests should stay under your Bedrock requests-per-minute limit with room left for chat traffic. Check your account’s actual quotas in Service Quotas rather than trusting a number in a blog post (including this one).

RAG_SYSTEM_CONTEXT is my favorite small change. Moving retrieved context into the system message keeps the front of the prompt stable, which is what prompt caching needs to work. Lower latency and lower token cost for one boolean.

Problem 6: Timeouts that assume short answers

Long Opus responses and big document jobs blow past the default 300-second client timeout. I raised AIOHTTP_CLIENT_TIMEOUT to 1800 and bumped the model-list timeouts a little to survive proxy cold starts.

The takeaway

None of these are exotic. They’re all documented somewhere. The trouble is that the defaults are tuned for the first five minutes of using the product, and nothing tells you which ones bite when you scale. If you’re putting Open WebUI in front of Bedrock for more than a handful of people:

  1. Make every piece of state shared before you add a second pod.
  2. Raise the thread pool before you blame the model.
  3. Turn off the background LLM features you don’t need, and route the rest to a small model.
  4. Do the quota and connection-pool math up front.
  5. Load test with streaming responses, not just page loads.

Next, I want to see how much of the proxy layer I can remove entirely.