Service Layer high complexity backend
2
Dependencies
2
Dependents
3
Entities
0
Integrations

Description

Backend service managing the enabled module set per organization tenant. Persists toggle changes, resolves inter-module dependencies, assembles the bootstrap module payload for session responses, and provides a fast lookup interface for the enforcement middleware.

Feature: Feature Toggles

module-configuration-service

Responsibilities

  • Read and write the enabled module set for a given organization in the module_configurations table
  • Resolve declared module dependencies so enabling area A automatically enables required area B
  • Assemble the full bootstrap module payload included in session and refresh token responses
  • Provide a low-latency lookup for the enforcement middleware to check module enablement per request
  • Emit audit log entries for every enable/disable change with actor, timestamp, and before/after state

Interfaces

getEnabledModules(orgId: string): Promise<string[]>
setModuleEnabled(orgId: string, areaId: string, enabled: boolean): Promise<ModuleConfigResult>
getBootstrapModuleSet(orgId: string): Promise<BootstrapModuleSet>
resolveDependencies(areaId: string): string[]
isModuleEnabled(orgId: string, areaId: string): Promise<boolean>
getAlwaysOnModules(): string[]
getModuleRegistry(): AreaModuleDefinition[]

Relationships

Dependencies (2)

Components this component depends on

Dependents (2)

Components that depend on this component

Related Data Entities (3)

Data entities managed by this component