dify - 💡(How to fix) Fix The local Docker deployment method. After modifying the .env file, the concurrency cannot be improved. There is a high latency issue and even failures occur.

Official PRs (…)
ON THIS PAGE

Recommended Tools

×6

Utilities matched from this issue’s tags and category — try them while you read without losing context.

GitHub issue graph ai analysis

Paste a GitHub issue URL. We fetch that issue, discover linked issues from bodies/comments/timeline, collect linked pull requests, and produce a structured English report.

The report is written in English Markdown for sharing and archival.

Helpful · Quick feedback

Loading…

Error Message

1.req_id: 7da9f30f18 PluginInvokeError: {"args":{},"error_type":"Exception","message":"read llm model failed: request failed: req_id: 3f9f69835f PluginInvokeError: {"args":{"description":"[models] Error: API request failed with status code 503: {\"error\":{\"message\":\"system cpu overloaded (current: 99.3%, threshold: 90%)\",\"type\":\"new_api_error\",\"param\":\"\",\"code\":\"system_cpu_overloaded\"}}"},"error_type":"InvokeError","message":"[models] Error: API request failed with status code 503: {\"error\":{\"message\":\"system cpu overloaded (current: 99.3%, threshold: 90%)\"}}"} 90%)\",\"type\":\"new_api_error\",\"param\":\"\",\"code\":\"system_cpu_overloaded\"}}"}"} 2.Failed to transform agent message: req_id: 86c43ca377 PluginInvokeError: {"args":{},"error_type":"Exception","message":"invoke llm model failed: request failed with status code: 400 and respond with: {"code":"invalid_param","message":"tenant not found","status":400}\n"}

RAW_BUFFERClick to expand / collapse

Self Checks

  • I have read the Contributing Guide and Language Policy.
  • I have searched for existing issues search for existing issues, including closed ones.
  • I confirm that I am using English to submit this report, otherwise it will be closed.
  • Please do not modify this template :) and fill in all the required fields.

1. Is this request related to a challenge you're experiencing? Tell me about your story.

The local Docker deployment method. After modifying the .env file, the concurrency cannot be improved. There is a high latency issue and even failures occur. When sending 10 concurrent requests instantly, the agent workflow delay is significantly sluggish, and it takes up to 60 seconds to complete the response.

<img width="846" height="915" alt="Image" src="https://github.com/user-attachments/assets/a5aae269-f5c6-4e96-8bbc-113725ab9df3" />

When 20 concurrent transmissions occur simultaneously, the delay can be as high as 120 seconds, and it may even directly show failure or CPU overload.

Repeatedly modifying the concurrent parameter settings in the .env file still failed to improve the situation. Failed message: 1.req_id: 7da9f30f18 PluginInvokeError: {"args":{},"error_type":"Exception","message":"read llm model failed: request failed: req_id: 3f9f69835f PluginInvokeError: {"args":{"description":"[models] Error: API request failed with status code 503: {\"error\":{\"message\":\"system cpu overloaded (current: 99.3%, threshold: 90%)\",\"type\":\"new_api_error\",\"param\":\"\",\"code\":\"system_cpu_overloaded\"}}"},"error_type":"InvokeError","message":"[models] Error: API request failed with status code 503: {\"error\":{\"message\":\"system cpu overloaded (current: 99.3%, threshold: 90%)\"}}"} 90%)\",\"type\":\"new_api_error\",\"param\":\"\",\"code\":\"system_cpu_overloaded\"}}"}"}

2.Failed to transform agent message: req_id: 86c43ca377 PluginInvokeError: {"args":{},"error_type":"Exception","message":"invoke llm model failed: request failed with status code: 400 and respond with: {"code":"invalid_param","message":"tenant not found","status":400}\n"}

=============================================================== Here are some of the main configuration parameters in my .env file SERVER_WORKER_CLASS=gevent(I also tried changing this to the sync mode, but it still didn't work.) SERVER_WORKER_CONNECTIONS=20 CELERY_WORKER_CLASS=(I also tried changing this to the sync mode, but it still didn't work.) GUNICORN_TIMEOUT=360 CELERY_WORKER_AMOUNT=4 CELERY_AUTO_SCALE=true CELERY_MAX_WORKERS=8 CELERY_MIN_WORKERS=2 API_TOOL_DEFAULT_CONNECT_TIMEOUT=10 API_TOOL_DEFAULT_READ_TIMEOUT=60 SQLALCHEMY_POOL_SIZE=300 SQLALCHEMY_MAX_OVERFLOW=10 SQLALCHEMY_POOL_RECYCLE=3600 SQLALCHEMY_ECHO=false SQLALCHEMY_POOL_PRE_PING=false SQLALCHEMY_POOL_USE_LIFO=false SQLALCHEMY_POOL_TIMEOUT=60 SQLALCHEMY_POOL_SIZE=250 POSTGRES_SHARED_BUFFERS=2GB POSTGRES_WORK_MEM=32MB POSTGRES_MAINTENANCE_WORK_MEM=1GB POSTGRES_EFFECTIVE_CACHE_SIZE=24GB POSTGRES_STATEMENT_TIMEOUT=0 POSTGRES_IDLE_IN_TRANSACTION_SESSION_TIMEOUT=0 MYSQL_MAX_CONNECTIONS=1000 MYSQL_INNODB_BUFFER_POOL_SIZE=512M MYSQL_INNODB_LOG_FILE_SIZE=128M MYSQL_INNODB_FLUSH_LOG_AT_TRX_COMMIT=2

2. Additional context or comments

SERVER_WORKER_CLASS=gevent(I also tried changing this to the sync mode, but it still didn't work.) The workflow only consists of a very simple set of 9 tools and 5 nodes.

<img width="1884" height="651" alt="Image" src="https://github.com/user-attachments/assets/c8e671af-ba9b-40ae-857b-989bffc0ebea" />

3. Can you help us with this feature?

  • I am interested in contributing to this feature.

Vote matrix · Quick signals

Works
Did the solution work? Tap to confirm.
Easy Fix
Was it a quick fix?
Time Saver
Did it save you time?
Blocking
Was it severely blocking?
Common Issue
Are others likely hitting this too?
Flaky / Intermittent
Is it intermittent?
Verified / Reproducible
Can you reproduce it reliably?
Loading…

Still need to ship something?

×6

Another batch ranked right after the header list — different links, same matching logic.

Back to top recommendations

TRENDING