danielgerlag / danielgerlag/workflow-core
SQL Server database size
- Dominant language
- C#
- Stars
- 5.9k
- Forks
- 1.3k
- Avg merge
- 1d 1h
- Merged PRs (30d)
- 5
Description
**Describe the bug**
WorkflowCore 3.13.0
WorkflowCore.QueueProviders.SqlServer 3.13.0
WorkflowCore.Persistence.SqlServer 3.13.0
Our SQL Server db size increased nearly 30 times in one day (from some MB to 5 GB).
This are the stats of our current DB:

Regarding the queues: The only queue containing items is "//workflow-core/workflowQueue" with 2k entries.
The only thing I discovered is that there are 6mio conversations (Is this normal?).
**To Reproduce**
1. Create a simple workflow application
2. Start 10 - 40 workflows
3. Let it run for a day
4. Check db
**Expected behavior**
Consistent database size that is not increasing if nothing happens (or at least not 33 times)
**UPDATE:** After deleting them with `END CONVERSATION xxx WITH CLEANUP`, and shrinking the db, it got back to its normal size.
Contributor guide
No contributing guide indexed for this repository
Research direction
Reproduce the reported setup with WorkflowCore 3.13.0, the SQL Server queue and persistence providers, and 10–40 workflows running for a day. Inspect the database queues and conversation count, then verify that the fix prevents runaway growth and that cleanup with END CONVERSATION is no longer required.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- csharp, sql
- Domain
- backend, databases
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 30/100