Creates a new StartupManager instance.
Initializes the database optimizer with the Prisma client connection. The constructor sets up the foundation for all startup operations but does not perform any initialization tasks - call initialize() for that.
Initialize all performance optimizations and startup procedures.
Orchestrates the complete startup sequence including database optimization, cache warming, and maintenance task setup. This method should be called during application startup to ensure optimal performance from the beginning.
Promise that resolves when initialization is complete
Graceful shutdown cleanup for application termination.
Performs orderly cleanup of resources including cache clearing and database disconnection. This method should be called during application shutdown to ensure proper resource cleanup and prevent data corruption.
Promise that resolves when shutdown is complete
Health check for startup readiness and system status verification.
Performs comprehensive health checks including database connectivity and cache functionality tests. This method is essential for determining if the application is ready to serve requests and for monitoring system health.
Promise that resolves to true if all health checks pass, false otherwise
Main startup orchestration class for WayrApp sovereign nodes.
Manages the complete initialization lifecycle of a community-owned educational platform node, including database optimization, cache warming, health monitoring, and graceful shutdown. This class ensures optimal performance from startup and maintains system health through automated maintenance tasks.
Example
Example