mirror of
https://github.com/fawney19/Aether.git
synced 2026-09-03 09:50:21 +08:00
chore: 调整 Nginx 代理超时配置并移除废弃的 concurrency_slot_ttl
- proxy_connect_timeout 从 600s 降至 60s - proxy_send_timeout/proxy_read_timeout 从 600s 升至 3600s 以支持长时间流式响应 - 移除已无引用的 concurrency_slot_ttl 配置项
This commit is contained in:
@@ -94,9 +94,9 @@ RUN printf '%s\n' \
|
|||||||
' chunked_transfer_encoding on;' \
|
' chunked_transfer_encoding on;' \
|
||||||
' gzip off;' \
|
' gzip off;' \
|
||||||
' add_header X-Accel-Buffering no;' \
|
' add_header X-Accel-Buffering no;' \
|
||||||
' proxy_connect_timeout 600s;' \
|
' proxy_connect_timeout 60s;' \
|
||||||
' proxy_send_timeout 600s;' \
|
' proxy_send_timeout 3600s;' \
|
||||||
' proxy_read_timeout 600s;' \
|
' proxy_read_timeout 3600s;' \
|
||||||
' }' \
|
' }' \
|
||||||
'' \
|
'' \
|
||||||
' # API 文档路由 → 代理到后端' \
|
' # API 文档路由 → 代理到后端' \
|
||||||
|
|||||||
@@ -105,9 +105,9 @@ RUN printf '%s\n' \
|
|||||||
' chunked_transfer_encoding on;' \
|
' chunked_transfer_encoding on;' \
|
||||||
' gzip off;' \
|
' gzip off;' \
|
||||||
' add_header X-Accel-Buffering no;' \
|
' add_header X-Accel-Buffering no;' \
|
||||||
' proxy_connect_timeout 600s;' \
|
' proxy_connect_timeout 60s;' \
|
||||||
' proxy_send_timeout 600s;' \
|
' proxy_send_timeout 3600s;' \
|
||||||
' proxy_read_timeout 600s;' \
|
' proxy_read_timeout 3600s;' \
|
||||||
' }' \
|
' }' \
|
||||||
'' \
|
'' \
|
||||||
' # API 文档路由 → 代理到后端' \
|
' # API 文档路由 → 代理到后端' \
|
||||||
|
|||||||
@@ -132,9 +132,7 @@ class Config:
|
|||||||
self.db_pool_warn_threshold = int(os.getenv("DB_POOL_WARN_THRESHOLD", "70"))
|
self.db_pool_warn_threshold = int(os.getenv("DB_POOL_WARN_THRESHOLD", "70"))
|
||||||
|
|
||||||
# 并发控制配置
|
# 并发控制配置
|
||||||
# CONCURRENCY_SLOT_TTL: 并发槽位 TTL(秒),防止死锁
|
|
||||||
# CACHE_RESERVATION_RATIO: 缓存用户预留比例(默认 10%,新用户可用 90%)
|
# CACHE_RESERVATION_RATIO: 缓存用户预留比例(默认 10%,新用户可用 90%)
|
||||||
self.concurrency_slot_ttl = int(os.getenv("CONCURRENCY_SLOT_TTL", "600"))
|
|
||||||
self.cache_reservation_ratio = float(os.getenv("CACHE_RESERVATION_RATIO", "0.1"))
|
self.cache_reservation_ratio = float(os.getenv("CACHE_RESERVATION_RATIO", "0.1"))
|
||||||
|
|
||||||
# 限流降级策略配置
|
# 限流降级策略配置
|
||||||
|
|||||||
Reference in New Issue
Block a user