Platform Features (Emergency Controls)
Platform features are global kill switches that override tenant-level feature access. They allow us to quickly disable functionality across the entire platform during emergencies—such as high database load, payment provider issues, or processing backlogs.
How It Works
Platform features operate as a separate, parallel system to tenant features:
- Checked before tenant-level features in the resolution chain
- If disabled → feature is off for all tenants, regardless of their plan or custom settings
- Affects the entire platform cross-tenant
Managing Platform Features
Platform features are controlled via Laravel Vapor dashboard environment variables.
Steps to change a platform feature:
- Go to Laravel Vapor dashboard
- Navigate to the environment (production/staging)
- Edit Environment Variables
- Set the variable (see pattern below)
- Redeploy — changes only take effect after redeployment
Environment variable pattern:
FEATURE_CONTROL_[FEATURE_NAME]=false
Example: To disable storefront search:
FEATURE_CONTROL_STOREFRONT_SEARCH=false
All platform features default to true (enabled). Only set them when you need to disable.
Available Controls
Source of truth: The definitive list lives in
config/platform.phpin farfalla.
| Env Variable | Purpose |
|---|---|
FEATURE_CONTROL_STOREFRONT_SEARCH | Global search functionality |
FEATURE_CONTROL_STOREFRONT_SEARCH_TERMS | Include taxonomy terms in search |
FEATURE_CONTROL_STOREFRONT_RECOMMENDED_ISSUES | Recommendation shelf |
FEATURE_CONTROL_UNLIMITED_READABLE_ISSUES | Remove 500 readable issue limit |
FEATURE_CONTROL_PAYMENT_SYNC | Payment provider sync jobs |
FEATURE_CONTROL_CHECK_MP_PAYMENTS | MercadoPago recurring payment checks |
FEATURE_CONTROL_IPN_PROCESSING | Payment webhook (IPN) processing |
FEATURE_CONTROL_BULK_PROCESS_DEFERRED_ISSUES | PDF/audiobook processing queue |
FEATURE_CONTROL_BULK_PROCESS_DEFERRED_EPUB | EPUB processing queue |
FEATURE_CONTROL_BULK_REPROCESS_ISSUES | Retry failed issue processing |
When to Use
- High database load — Disable search or recommendations to reduce query pressure
- Payment provider issues — Disable payment sync or IPN processing during outages
- Processing queue backlogs — Pause bulk processing jobs to let queues drain
- Emergency feature disabling — Quickly turn off problematic functionality platform-wide