* Add tenant headers support to BackgroundWorkflowCancellationDispatcher (#7040)
* Add tenant headers support to BackgroundWorkflowCancellationDispatcher
* Fix 'CreateHeaders' call
* Fix memory leak: Dispose IronCompressResult in Zstd codec (#7193)
* Initial plan
* Fix memory leak: Dispose IronCompressResult in Zstd codec and add tests
Co-authored-by: sfmskywalker <938393+sfmskywalker@users.noreply.github.com>
* Refactor tests to be more DRY using Theory and InlineData
Co-authored-by: sfmskywalker <938393+sfmskywalker@users.noreply.github.com>
---------
Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: sfmskywalker <938393+sfmskywalker@users.noreply.github.com>
* Introduce `IMaterializerRegistry` to manage workflow materializers and ensure availability checks.
* Extend `IWorkflowDefinitionService` and `CachingWorkflowDefinitionService` with workflow graph lookup methods (`TryFindWorkflowGraphAsync`). Refactor caching and materialization logic for consistency.
* Refactor caching interface and implementation: add `FindOrCreateAsync`, update `GetOrCreateAsync` to ensure non-null results, and improve exception handling.
* Refactor `GetWorkflowGraphAsync` to use `TryFindWorkflowGraphAsync` and improve exception handling for missing workflow definitions and materializers.
* Refactor caching logic to replace `GetOrCreateAsync` with `FindOrCreateAsync` for improved clarity and consistency.
* Update workflow model, add event, and mark exception obsolete
Updated `TimestampFilter.Column` to use a `null!` default value for clarity. Added `Event1` in the `hello-world.elsa` workflow and removed an unused folder entry from the project. Marked `WorkflowGraphNotFoundException` as obsolete with guidance to use `WorkflowDefinitionNotFoundException` instead.
* Add new workflow files and exception classes for Elsa
Introduced a workflow definition file "eventing.json" and new exception classes (`WorkflowDefinitionNotFoundException` and `WorkflowMaterializerNotFoundException`) to enhance handling of workflow-related errors. Also added a `WorkflowGraphFindResult` model for better workflow graph management. These changes improve the structure and functionality of the workflow system.
* Add unit tests for `CachingWorkflowDefinitionService` and related helpers
Introduce comprehensive unit tests to validate caching logic, workflow graph/materialization behavior, and cache key generation in `CachingWorkflowDefinitionService`. Add `WorkflowDefinitionServiceTests` and helper methods for streamlined test setup.
* Enable `UseElsaScriptBlobStorage` in workflow server configuration
* Refactor `BackgroundWorkflowCancellationDispatcher` to simplify object initialization and clean up XML documentation comments
* Address PR #7195 review feedback: optimize caching, improve exceptions, add test coverage (#7196)
* Initial plan
* Apply PR review feedback: Fix exceptions, optimize caching, improve error handling
Co-authored-by: sfmskywalker <938393+sfmskywalker@users.noreply.github.com>
* Add unit tests for MaterializerRegistry and LocalWorkflowClient exception handling
Co-authored-by: sfmskywalker <938393+sfmskywalker@users.noreply.github.com>
* Add unit tests for BackgroundWorkflowCancellationDispatcher tenant headers
Co-authored-by: sfmskywalker <938393+sfmskywalker@users.noreply.github.com>
* Refactor `WorkflowMaterializerNotFoundException` to improve structure and usability, update related references, and simplify object initialization in test cases.
* Update `WorkflowDefinitionServiceTests` to use `WorkflowMaterializerNotFoundException` in place of `InvalidOperationException` for materializer not found scenario
---------
Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: sfmskywalker <938393+sfmskywalker@users.noreply.github.com>
Co-authored-by: Sipke Schoorstra <sipkeschoorstra@outlook.com>
* Potential fix for pull request finding 'Inefficient use of ContainsKey'
Co-authored-by: Copilot Autofix powered by AI <223894421+github-code-quality[bot]@users.noreply.github.com>
* Refactor tests and services: simplify object initialization, use target-typed `new()` syntax, and replace `CancellationToken` with `CancellationToken.None` where applicable.
* Refactor tests in `BackgroundWorkflowCancellationDispatcherTests`: improve tenant initialization and optimize header checks by replacing `TryGetValue` with `ContainsKey`.
---------
Co-authored-by: Sverre Winkelmans <69142682+Sverre-W@users.noreply.github.com>
Co-authored-by: Copilot <198982749+Copilot@users.noreply.github.com>
Co-authored-by: sfmskywalker <938393+sfmskywalker@users.noreply.github.com>
Co-authored-by: Copilot Autofix powered by AI <223894421+github-code-quality[bot]@users.noreply.github.com>