Wiz upgraded its Aurora PostgreSQL database from version 14 to 16, achieving a significant reduction in downtime from approximately one hour to just 30 seconds. The upgrade was facilitated by an automated process called DB Upgrade Pilot, which utilized Amazon Aurora's Blue/Green Deployments. This process involved several steps: taking a cluster snapshot, provisioning a synchronized replica of the production database, executing a VACUUM ANALYZE for performance optimization, monitoring replication lag, and performing a switchover to the new environment. The upgrade included performance enhancements such as improved parallel query execution and faster aggregations, along with enhanced security features. The solution also incorporated safety measures like automatic rollback capability and robust validation steps to ensure a stable upgrade process.