elsa-core/src/modules/Elsa.EntityFrameworkCore.Common
Sipke Schoorstra e2288d0b34
Fix infinitely waiting Alterations Workflow (#6561)
* Refactor TenantId string handling and nullability checks.

Moved `StringExtensions` to a common module for reuse. Updated tenant-related logic to utilize null-safe string extensions, enhancing consistency and simplifying nullability handling across the codebase.

* Set StrictMode to false by default in ObjectConverter

Modified the default value of StrictMode to `false` to enable the original flexible behavior. Developers can opt into strict mode by explicitly setting it to `true`. This change aims to enhance backward compatibility and minimize unexpected strict conversions.

* Add tenant ID retrieval to ElsaDbContextBase constructor

Retrieve the current tenant ID if available using ITenantAccessor and assign it to the TenantId property. This ensures proper handling of multi-tenancy scenarios in the database context initialization.

* Disable DbContext pooling, manual OTEL instrumentation, and strict mode.

DbContext pooling is turned off to prevent potential issues with shared context instances. Manual OpenTelemetry instrumentation is disabled to rely on automatic instrumentation instead. Strict mode is also disabled to allow more flexibility in object conversion.

* Fix infinitely waiting Alterations Workflow

Replaced workflow dispatch logic with BookmarkQueue and StimulusHasher for triggering workflows. This fixes the issue where the Alterations workflow would signal completion while a later step awaits a completion bookmark. The Bookmark Queue now handles this.
2025-04-05 10:37:05 +02:00
..
Abstractions Simplify DbContext creation with ActivatorUtilities. 2025-01-29 19:03:59 +01:00
Contracts Fix all broken summary xml docs (#6123) 2024-11-18 13:41:27 +01:00
Converters Secrets API (#5967) 2024-09-15 17:12:13 -07:00
EntityHandlers Fix infinitely waiting Alterations Workflow (#6561) 2025-04-05 10:37:05 +02:00
Extensions Fix TenantId Missing in ActivityExecutionRecords and DB Context Isolation in Multitenancy (#6549) 2025-04-04 12:39:14 +02:00
CommonPersistenceFeature.cs Refactor database setup and EFCore provider configurations. 2025-01-31 19:51:24 +01:00
Constants.cs Improved multitenancy support for HTTP workflows with per-tenant DbContext (#6032) 2024-10-15 23:16:50 +02:00
CustomDbContextOptionsExtensionInfo.cs Improved multitenancy support for HTTP workflows with per-tenant DbContext (#6032) 2024-10-15 23:16:50 +02:00
DbSchemaAwareMigrationAssembly.cs Refactor database setup and EFCore provider configurations. 2025-01-31 19:51:24 +01:00
DbUpdateExceptionContext.cs Improved multitenancy support for HTTP workflows with per-tenant DbContext (#6032) 2024-10-15 23:16:50 +02:00
Elsa.EntityFrameworkCore.Common.csproj Fix TenantId Missing in ActivityExecutionRecords and DB Context Isolation in Multitenancy (#6549) 2025-04-04 12:39:14 +02:00
Elsa.EntityFrameworkCore.Common.csproj.DotSettings Remove outdated database migration files 2024-10-23 14:32:50 +02:00
ElsaDbContextBase.cs Fix infinitely waiting Alterations Workflow (#6561) 2025-04-05 10:37:05 +02:00
ElsaDbContextOptions.cs Fix Oracle migrations 2025-02-01 00:38:38 +01:00
ElsaDbContextOptionsExtension.cs Fix TenantId Missing in ActivityExecutionRecords and DB Context Isolation in Multitenancy (#6549) 2025-04-04 12:39:14 +02:00
ElsaDbContextOptionsExtensions.cs Improved multitenancy support for HTTP workflows with per-tenant DbContext (#6032) 2024-10-15 23:16:50 +02:00
EntityStore.cs Improved multitenancy support for HTTP workflows with per-tenant DbContext (#6032) 2024-10-15 23:16:50 +02:00
FodyWeavers.xml Feature: Alterations (#4501) 2023-10-07 12:47:36 +02:00
JsonValueComparer.cs Secrets API (#5967) 2024-09-15 17:12:13 -07:00
JsonValueConverterHelper.cs Secrets API (#5967) 2024-09-15 17:12:13 -07:00
PersistenceFeatureBase.cs Fix TenantId Missing in ActivityExecutionRecords and DB Context Isolation in Multitenancy (#6549) 2025-04-04 12:39:14 +02:00
RunMigrationsHostedService.cs Enhance Multitenancy with Runtime Tenant Management and Task Handling (#6173) 2024-12-03 15:07:55 +01:00
RunMigrationsStartupTask.cs Fix Oracle migrations 2025-02-01 00:38:38 +01:00
Store.cs Fix TenantId Missing in ActivityExecutionRecords and DB Context Isolation in Multitenancy (#6549) 2025-04-04 12:39:14 +02:00
TenantAwareDbContextFactory.cs Fix TenantId Missing in ActivityExecutionRecords and DB Context Isolation in Multitenancy (#6549) 2025-04-04 12:39:14 +02:00