Architecting the workload to handle eviction
Eviction is the process whereby Azure takes back your Spot VM when Azure’s excess capacity disappears. Workloads running on Spot VMs must accept the possibility of eviction and should have the following characteristics:
- Low importance in the organizations and no up-time constraints
- Run processes that are idempotent, stateless, and short
- Run processes that can stop/restart without losing any data
Examples of interruptible workloads are batch processing applications, data analytics, and workloads that create a continuous integration/continuous deployment agent for a non-production environment.
Let’s look at a real-world scenario to understand the architecture better. The image resizer application is a stateless batch processing job that runs when an image in a storage account is uploaded in the source container by the frontend application. It uses the open source FFmpeg utility to resize the image and...