ASP.NET Core Interview Question #222

What is a rolling deployment?

Testing, Deployment & Hosting Senior Advanced

Quick Interview Answer

A rolling deployment replaces application instances gradually rather than stopping every old instance and starting every new instance at once.

Detailed Explanation

A rolling deployment replaces application instances gradually rather than stopping every old instance and starting every new instance at once.

Traffic continues to be served while instances are updated in batches. This can reduce downtime and deployment risk, but old and new application versions may run simultaneously for a period.

APIs, shared caches, message formats, and database schema changes should therefore be compatible across the overlapping versions.

Code Example

// Application design consideration:
// Version N and Version N+1 may both access the
// database during the deployment window.
// Prefer backward-compatible schema transitions.