Performance: Environment-based profiles
MEDIUM IMPACT
This concept affects application startup time and resource loading by selecting configuration sets based on environment.
Spring Boot application activates only one profile at startup (e.g., -Dspring.profiles.active=prod) to load relevant configs
Spring Boot application loads all configurations for dev, test, and prod environments regardless of active profile
| Pattern | Config Loading | Startup Delay | Resource Usage | Verdict |
|---|---|---|---|---|
| Load all profiles configs | Loads all config files | High (200-500ms extra) | High (unused beans/resources) | [X] Bad |
| Activate single profile | Loads only active profile config | Low (minimal delay) | Low (only needed beans) | [OK] Good |