Shell features that own FastEndpoints omit IFastEndpointsShellFeature (Labels, TenantManagementEndpoints, JavaScript)
Problem
On CShells hosts, FastEndpoints discovery is not whole-assembly scanning. CShells.FastEndpoints maps endpoints only from assemblies of active features that implement IFastEndpointsShellFeature (see Elsa.Foundation.Host Program.cs comments and doc/wiki/extension-guide.md).
Several first-party modules still register endpoints the classic way (Module.AddFastEndpointsAssembly(...)) but their shell counterparts implement plain IShellFeature only. Enabling those shell features wires DI stores/services and leaves the HTTP surface unmapped.
Evidence (main)
| Module | Classic | Shell today | Endpoints present |
|---|---|---|---|
| Labels | LabelsFeature → AddFastEndpointsAssembly(GetType()) |
Elsa.Labels.ShellFeatures.LabelsFeature : IShellFeature only |
Endpoints/Labels/*, Endpoints/WorkflowDefinitionLabels/* |
| Tenant management API | TenantManagementEndpointsFeature → AddFastEndpointsAssembly |
…ShellFeatures.TenantManagementEndpointsFeature : IShellFeature; comment claims “registered via assembly scanning” |
Elsa.Tenants/Endpoints/Tenants/* |
| JavaScript expressions | JavaScriptFeature → AddFastEndpointsAssembly |
…ShellFeatures.JavaScriptFeature : IShellFeature only |
Endpoints/TypeDefinitions/Endpoint.cs |
Contrast (correct pattern): WorkflowsApiFeature, IdentityFeature, SecretsFeature, diagnostics Console/OTel/StructuredLogs, Alterations, etc. implement IFastEndpointsShellFeature (and usually depend on ElsaFastEndpointsFeature / host FastEndpoints).
ElsaFastEndpointsFeature registers the Elsa serializer configurator, authorization, and AddPermissionDescriptorsFromLoadedAssemblies() — it does not substitute for the per-feature IFastEndpointsShellFeature marker that drives endpoint assembly selection.
Why it matters
- CShells hosts that enable Labels / Tenant Management Endpoints / JavaScript get stores and filters but 404 on the matching REST routes.
- Studio / operators see the feature as installed (#7910 aside) while Labels CRUD, tenant admin API, and JS type-definition endpoints never bind.
- Accidental complexity: two registration stories (classic module bag vs shell marker) that diverged without a check.
Proposed subtractive direction
- Change the three shell features above to implement
IFastEndpointsShellFeature(emptyConfigureServicesbody is fine when DI is already registered — mirror Agents API / Webhooks). - Fix the TenantManagementEndpoints shell comment (drop the false “assembly scanning” claim).
- Prefer
DependsOnElsaFastEndpointsFeature(or hostFastEndpoints) where sibling API features already do, so auth/serializer configurator is present. - Optional ratchet: a small test or analyzer that fails when an assembly under
**/Endpoints/**has a shell feature that does not implementIFastEndpointsShellFeature.
Do not invent a third discovery path.
Not a duplicate of
- #7910 —
/features/installedreports catalog vs enabled (enablement truth); this is endpoint discovery for features that are enabled. - #8170 — Labels
Page.TotalCountMemory vs EF. - Closed #1038 (studio) — Studio Labels RemoteFeature gate.
- Closed Labels Memory tenant work (#8089/#8090/#8091).
Milestone
Unset — Elsa 3 Issue Triage / Crew Lead place. Soft suggestion: Backlog; patch-relevant for any CShells host that relies on these APIs. Do not auto-assign Engineer.
Refs
src/modules/Elsa.Labels/Features/LabelsFeature.csvsShellFeatures/LabelsFeature.cssrc/modules/Elsa.Tenants/Features/TenantManagementEndpointsFeature.csvsShellFeatures/TenantManagementEndpointsFeature.cssrc/modules/Elsa.Expressions.JavaScript/Features/JavaScriptFeature.csvsShellFeatures/JavaScriptFeature.cssrc/common/Elsa.Api.Common/ShellFeatures/ElsaFastEndpointsFeature.cssrc/common/Elsa.Api.Common/Extensions/ModuleExtensions.cs(AddFastEndpointsAssembly)doc/wiki/extension-guide.md(shell features:IFastEndpointsShellFeature)- Foundation host comment:
elsa-foundationElsa.Foundation.Host/Program.cs(CShells.FastEndpoints scans activeIFastEndpointsShellFeatureassemblies)
Source: elsa-workflows/elsa-core