Feature flags
Entitlements and staged rollouts for portal capabilities.
Overview
Feature delivery combines:
- Tenant entitlements — JSON on
Tenant.entitlements(module toggles). - Application flags — environment variables or remote config consumed by Next.js.
- Emergency killswitches — ops toggles (database or feature flag service) for incident response.
Entitlements JSON
null entitlements means “all modules on” for backward compatibility. When present, keys such as documents, maintenance, emergencyFallback, soundMarketplace, and orgAnnouncements gate UI routes.
Implementation tips
- Evaluate flags server-side when the decision affects security.
- Mirror flag state in analytics events to debug partial rollouts.
- Document ownership per flag in
docs/when changing defaults.
Testing
Maintain a staging tenant with constrained entitlements to validate degraded experiences before customer-facing launches.