There are several strategies for delivering code to a server, commonly referred to as deployments. In this guide, I’ll focus on one of the oldest and most straightforward approaches: Recreate Deployment. You will learn how it works and, more importantly, what it means for QA engineers and Test Automation.
────────────────────────────────
𝐖𝐡𝐚𝐭 𝐈𝐬 𝐑𝐞𝐜𝐫𝐞𝐚𝐭𝐞 𝐃𝐞𝐩𝐥𝐨𝐲𝐦𝐞𝐧𝐭?
➤ The old version (lets call it V1) is taken completely offline
➤ The new version (V2) is deployed and started
➤ Application is completely unavailable during this switch, its called downtime
➤ This type of deployment is commonly used in dev/test environments or apps that can handle brief outages
────────────────────────────────
𝐇𝐨𝐰 𝐈𝐭 𝐀𝐟𝐟𝐞𝐜𝐭𝐬 𝐓𝐞𝐬𝐭 𝐀𝐮𝐭𝐨𝐦𝐚𝐭𝐢𝐨𝐧
✦ Problem #1: Tests Fail During Deployment
Automated tests will fail if they run during deployment because the application is down. You'll see connection errors, timeouts 502 HTTP code, or "service unavailable" messages.
Solution: Schedule your test runs AFTER deployments complete. Coordinate with DevOps on deployment windows.
✦ Problem #2: Timing Issues in CI/CD Pipelines
If a CI/CD pipeline triggers tests immediately after deployment, they might start before the new version is fully ready.
Solution: Add a health check or wait period in your pipeline.
➤ Wait 30-60 seconds after deployment
➤ Ping a health endpoint until it responds
➤ Only then start your test suite
𝐏.𝐒. 🚩 𝐈𝐟 𝐲𝐨𝐮 𝐡𝐚𝐯𝐞𝐧’𝐭 𝐰𝐚𝐭𝐜𝐡𝐞𝐝 𝐢𝐭 𝐲𝐞𝐭, 𝐲𝐨𝐮𝐫 𝐧𝐞𝐱𝐭 𝐬𝐭𝐞𝐩 𝐢𝐬 𝐭𝐡𝐞 𝐅𝐑𝐄𝐄 𝟑-𝐩𝐚𝐫𝐭 “𝐌𝐚𝐧𝐮𝐚𝐥 𝐐𝐀 → 𝐒𝐃𝐄𝐓” 𝐰𝐨𝐫𝐤𝐬𝐡𝐨𝐩, 𝐚 𝐬𝐡𝐨𝐫𝐭 𝐦𝐢𝐧𝐢-𝐜𝐨𝐮𝐫𝐬𝐞 𝐭𝐡𝐚𝐭 𝐠𝐢𝐯𝐞𝐬 𝐲𝐨𝐮 𝐭𝐡𝐞 𝐟𝐮𝐥𝐥 𝐫𝐨𝐚𝐝𝐦𝐚𝐩 𝐭𝐨 𝐛𝐞𝐜𝐨𝐦𝐢𝐧𝐠 𝐚 𝐦𝐢𝐝-𝐥𝐞𝐯𝐞𝐥 𝐒𝐃𝐄𝐓 𝐚𝐧𝐝 𝐩𝐚𝐬𝐬𝐢𝐧𝐠 𝐢𝐧𝐭𝐞𝐫𝐯𝐢𝐞𝐰𝐬.