elsa-workflows / elsa-workflows/elsa-core
MongoDb Persistence - Double quotes around data in the ActivityData property of the WorkflowInstances collection
- Dominant language
- C#
- Stars
- 7.9k
- Forks
- 1.5k
- Avg merge
- 15h 22m
- Merged PRs (30d)
- 114
Description
Hi,
I'm using persistence with MongoDb and I noticed that the data is persisted with double quotes in the **'ActivityData'** property of the **'WorkflowInstances'** collection, as we can see in the image below:

This causes the message body to be sent to RabbitMq as a string instead of pure JSON, using the activity **'Elsa.Activities.RabbitMq'**, as we can see in the image below:

When trying to deserialize the message, an error occurs because it is not valid JSON.
This behavior may be occurring because the **'ActivityData'** property type is defined as **'Dictionary'** in the entity.
More Info:
**Elsa.Persistence.MongoDb Version:** 2.13.0
**Elsa.Activities.RabbitMq Version:** 2.13.0
Tks!
Contributor guide
Research direction
Start by reproducing the ActivityData value in the MongoDB WorkflowInstances collection with Elsa.Persistence.MongoDb 2.13.0 and tracing it into the Elsa.Activities.RabbitMq message body. Compare the stored value with the expected JSON and confirm that deserialization succeeds without the extra quotes; the issue does not name source files or tests to inspect.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- csharp, mongodb, rabbitmq
- Domain
- database, distributed-systems
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 42/100