alwyas Creating DifyAPIWorkflowNodeExecutionRepository from? #15932

Closed
opened 2026-02-21 19:24:01 -05:00 by yindo · 1 comment
Owner

Originally created by @wangsang555555 on GitHub (Aug 6, 2025).

Self Checks

  • I have read the Contributing Guide and Language Policy.
  • This is only for bug report, if you would like to ask a question, please head to Discussions.
  • 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.
  • 【中文用户 & Non English User】请使用英语提交,否则会被关闭 :)
  • Please do not modify this template :) and fill in all the required fields.

Dify version

1.7.1

Cloud or Self Hosted

Self Hosted (Docker)

Steps to reproduce

Image 1. Bug Description

I am experiencing an issue where long-running workflows consistently stop executing after approximately 3 to 4 minutes. There is no explicit error message or stack trace in the logs that indicates a crash. The workflow simply ceases to progress.

This behavior is periodic and predictable. Right before the workflow halts, I observe the following log message, which appears to be from a newly initialized process:
Creating DifyAPIWorkflowNodeExecutionRepository from: repositories.sqlalchemy_api_workflow_node_execution_repository.DifyAPISQLAlchemyWorkflowNodeExecutionRepository

who can help me

✔️ Expected Behavior

i need help

Actual Behavior

Image
Originally created by @wangsang555555 on GitHub (Aug 6, 2025). ### Self Checks - [x] I have read the [Contributing Guide](https://github.com/langgenius/dify/blob/main/CONTRIBUTING.md) and [Language Policy](https://github.com/langgenius/dify/issues/1542). - [x] This is only for bug report, if you would like to ask a question, please head to [Discussions](https://github.com/langgenius/dify/discussions/categories/general). - [x] I have searched for existing issues [search for existing issues](https://github.com/langgenius/dify/issues), including closed ones. - [x] I confirm that I am using English to submit this report, otherwise it will be closed. - [x] 【中文用户 & Non English User】请使用英语提交,否则会被关闭 :) - [x] Please do not modify this template :) and fill in all the required fields. ### Dify version 1.7.1 ### Cloud or Self Hosted Self Hosted (Docker) ### Steps to reproduce <img width="1077" height="401" alt="Image" src="https://github.com/user-attachments/assets/f5cd95ba-7206-45e7-938e-86ca283f410c" /> 1. Bug Description I am experiencing an issue where long-running workflows consistently stop executing after approximately 3 to 4 minutes. There is no explicit error message or stack trace in the logs that indicates a crash. The workflow simply ceases to progress. This behavior is periodic and predictable. Right before the workflow halts, I observe the following log message, which appears to be from a newly initialized process: Creating DifyAPIWorkflowNodeExecutionRepository from: repositories.sqlalchemy_api_workflow_node_execution_repository.DifyAPISQLAlchemyWorkflowNodeExecutionRepository who can help me ### ✔️ Expected Behavior i need help ### ❌ Actual Behavior <img width="782" height="291" alt="Image" src="https://github.com/user-attachments/assets/4b53af12-19cc-4b37-9dc5-ec9454978d14" />
yindo closed this issue 2026-02-21 19:24:01 -05:00
Author
Owner

@dosubot[bot] commented on GitHub (Aug 6, 2025):

Hi @wangsang555555! I'm Dosu and I’m helping the dify team.

The log message about "Creating DifyAPIWorkflowNodeExecutionRepository" is normal and just means the workflow node execution repository is being instantiated for a workflow run—it’s not an error or a sign of failure. This happens every time a workflow run starts or restarts, as part of Dify’s modular design, and is not directly related to your workflow halting issue (source).

If your long-running workflows consistently stop after 3–4 minutes with no error, the most common causes are workflow execution timeouts or SQLAlchemy session management issues. In self-hosted Docker setups, check these:

  • Make sure your .env or Docker environment has a sufficiently high value for WORKFLOW_MAX_EXECUTION_TIME (in seconds). If it’s set to 180 or 240, try increasing it to a higher value to allow longer runs (source).
  • Review Docker/container resource limits (CPU, memory) to ensure the container isn’t being killed or restarted.
  • For SQLAlchemy session issues (like DetachedInstanceError), make sure each long-running task manages its own session and that you’re not passing ORM objects between threads or tasks—always pass IDs and re-query as needed (source).
  • If you see no errors but the workflow just stops, check for session detachment or timeout logs at a lower log level (DEBUG).

These issues have been reported by others, and best practices include increasing timeouts, monitoring resource usage, and ensuring proper session management in long-running workflows (source). The repository creation log is not a bug—focus on timeout and session settings to resolve the halting.

To reply, just mention @dosu.


How did I do? Good | Irrelevant | Incorrect | Verbose | Hallucination | Report 🐛 | Other  Chat with Dosu Join Discord Share on X

@dosubot[bot] commented on GitHub (Aug 6, 2025): <!-- Greeting --> Hi @wangsang555555! I'm [Dosu](https://go.dosu.dev/dosubot) and I’m helping the dify team. <!-- Answer --> The log message about "Creating DifyAPIWorkflowNodeExecutionRepository" is normal and just means the workflow node execution repository is being instantiated for a workflow run—it’s not an error or a sign of failure. This happens every time a workflow run starts or restarts, as part of Dify’s modular design, and is not directly related to your workflow halting issue [(source)](https://github.com/langgenius/dify/blob/1f15cba9a0d417fab40437a6ed64bbc43ffb0fe8/api/core/repositories/factory.py). If your long-running workflows consistently stop after 3–4 minutes with no error, the most common causes are workflow execution timeouts or SQLAlchemy session management issues. In self-hosted Docker setups, check these: - Make sure your `.env` or Docker environment has a sufficiently high value for `WORKFLOW_MAX_EXECUTION_TIME` (in seconds). If it’s set to 180 or 240, try increasing it to a higher value to allow longer runs [(source)](https://github.com/langgenius/dify/issues/15500). - Review Docker/container resource limits (CPU, memory) to ensure the container isn’t being killed or restarted. - For SQLAlchemy session issues (like `DetachedInstanceError`), make sure each long-running task manages its own session and that you’re not passing ORM objects between threads or tasks—always pass IDs and re-query as needed [(source)](https://github.com/langgenius/dify/issues/11910). - If you see no errors but the workflow just stops, check for session detachment or timeout logs at a lower log level (`DEBUG`). These issues have been reported by others, and best practices include increasing timeouts, monitoring resource usage, and ensuring proper session management in long-running workflows [(source)](https://github.com/langgenius/dify/issues/12192). The repository creation log is not a bug—focus on timeout and session settings to resolve the halting. <!-- Dosu Comment Footer --> *To reply, just mention [@dosu](https://go.dosu.dev/dosubot).* --- <sup>How did I do? [Good](https://app.dosu.dev/response-feedback/96c09bc4-4076-43ee-8192-66bb69eb9fcc?feedback_type=great_response) | [Irrelevant](https://app.dosu.dev/response-feedback/96c09bc4-4076-43ee-8192-66bb69eb9fcc?feedback_type=irrelevant_answer) | [Incorrect](https://app.dosu.dev/response-feedback/96c09bc4-4076-43ee-8192-66bb69eb9fcc?feedback_type=incorrect_sources) | [Verbose](https://app.dosu.dev/response-feedback/96c09bc4-4076-43ee-8192-66bb69eb9fcc?feedback_type=too_verbose) | [Hallucination](https://app.dosu.dev/response-feedback/96c09bc4-4076-43ee-8192-66bb69eb9fcc?feedback_type=hallucination) | [Report 🐛](https://app.dosu.dev/response-feedback/96c09bc4-4076-43ee-8192-66bb69eb9fcc?feedback_type=bug_report) | [Other](https://app.dosu.dev/response-feedback/96c09bc4-4076-43ee-8192-66bb69eb9fcc?feedback_type=other)</sup>&nbsp;&nbsp;[![Chat with Dosu](https://dosu.dev/dosu-chat-badge.svg)](https://app.dosu.dev/6088a4f4-073a-43f3-b3d4-4f06fb0c05a0/ask?utm_source=github)&nbsp;[![Join Discord](https://img.shields.io/badge/join-5865F2?logo=discord&logoColor=white&label=)](https://go.dosu.dev/discord-bot)&nbsp;[![Share on X](https://img.shields.io/badge/X-share-black)](https://twitter.com/intent/tweet?text=%40dosu_ai%20helped%20me%20solve%20this%20issue!&url=https%3A//github.com/langgenius/dify/issues/23496)
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: langgenius/dify#15932