A company runs a batch analytics workload on Compute Engine that runs for 3 hours every night. The workload is fault-tolerant and can be disrupted. Which pricing model should the engineer use to minimize cost?
Trap 1: Committed use discounts
Committed use discounts (CUDs) require purchasing a 1-year or 3-year commitment for consistent vCPU/memory usage. A nightly 3-hour batch job uses the VM for roughly 90 hours per month, well below the 730-hour monthly baseline that makes a CUD worthwhile. You would pay for idle committed resources the rest of the day, negating any discount, so CUDs are not cost-effective for this short, intermittent workload.
Trap 2: On-demand VMs
On-demand VMs use standard pay-as-you-go pricing and do not provide the significant discount of Spot VMs, so they are not the most cost-effective choice for fault-tolerant batch workloads.
Trap 3: Sustained use discounts
Sustained use discounts (SUDs) automatically apply to VMs that run for more than 25% of a month (approximately 730 hours). This workload runs only 3 hours per night, totaling about 90 hours per month, which is far below the threshold, so no SUD would apply. Additionally, SUDs are not a purchasing decision; they just adjust billing after the fact, so they cannot be intentionally chosen to reduce cost for short nightly jobs.
- A
Committed use discounts
Why wrong: Committed use discounts (CUDs) require purchasing a 1-year or 3-year commitment for consistent vCPU/memory usage. A nightly 3-hour batch job uses the VM for roughly 90 hours per month, well below the 730-hour monthly baseline that makes a CUD worthwhile. You would pay for idle committed resources the rest of the day, negating any discount, so CUDs are not cost-effective for this short, intermittent workload.
- B
Spot VMs
Spot VMs offer lower prices than on-demand and have no 24-hour maximum runtime, making them viable for many batch jobs. However, for a fault-tolerant job that completes in only 3 hours, preemptible VMs provide a better price because they have a fixed, larger discount without the dynamic pricing of Spot VMs. The lack of a maximum runtime is irrelevant here since the job fits well within preemptible VM limits, so Spot VMs are a valid but not the most cost-effective choice.
- C
On-demand VMs
Why wrong: On-demand VMs use standard pay-as-you-go pricing and do not provide the significant discount of Spot VMs, so they are not the most cost-effective choice for fault-tolerant batch workloads.
- D
Sustained use discounts
Why wrong: Sustained use discounts (SUDs) automatically apply to VMs that run for more than 25% of a month (approximately 730 hours). This workload runs only 3 hours per night, totaling about 90 hours per month, which is far below the threshold, so no SUD would apply. Additionally, SUDs are not a purchasing decision; they just adjust billing after the fact, so they cannot be intentionally chosen to reduce cost for short nightly jobs.