elsa-workflows / elsa-workflows/elsa-core
[ENH] Support TypeName Overriding in IActivityDescriptorModifier Without Breaking Workflow Builder API
- Dominant language
- C#
- Stars
- 7.9k
- Forks
- 1.5k
- Avg merge
- 15h 22m
- Merged PRs (30d)
- 114
Description
Currently, the `IActivityDescriptorModifier` interface allows overriding various activity descriptor attributes such as Display Name, Description, Inputs, and Outputs. This is implemented before the activities are registered in the activity registry. However, attempts to override the `TypeName` attribute can disrupt the functioning of programmatically created workflows using the workflow builder API. This occurs because the instantiation of an activity directly relies on the `ActivityAttribute.TypeName` or defaults to the activity's .NET type if `TypeName` is not set.
To address this, we propose enhancing the handling of `TypeName` overrides. Specifically, we need to implement a mechanism that checks and updates the `TypeName` of activity instances dynamically. This approach should ensure that any changes to the `TypeName` through the `IActivityDescriptorModifier` are accurately reflected.
### Expected Outcome:
- Allow dynamic overriding of `TypeName` in `IActivityDescriptorModifier` without breaking the integrity and functionality of workflows constructed using the workflow builder API.
This enhancement will contribute to greater flexibility in modifying and extending activities without risking the stability of programmatically created workflows.
Contributor guide
Assessment
This issue has not been assessed yet.