Computer Engineering is coming soon

We're still writing and reviewing the notes for every subject, and we'll open it when every subject is ready. Meanwhile you can practise aptitude, ask Aria about any subject, or see the branches that are ready.

Cloud computing: definition, characteristics and trade-offs

Definition of cloud computing, its essential characteristics (from first principles), and the main trade-offs engineers must consider when designing or choosing cloud solutions.

Drafted with Aria, reviewed by the AiCanCode.org team · Updated . How we write and check our notes. Spotted an error? Use Give Feedback at the bottom of the page.

Why it matters

Cloud computing is the common platform engineers use to run applications, store data and scale services for millions of users. An engineer uses these concepts when choosing between running services on-premises or on a public cloud, when writing SLAs, planning capacity and cost, and when trading off performance, security and vendor lock-in.

Key ideas

Start from first principles: computing systems are sets of hardware and software that process data and provide services to users. Cloud computing is a model to supply those services over a network with particular properties that change how organisations buy and operate IT.

  • Cloud computing — a model for enabling convenient, on-demand network access to a shared pool of configurable computing resources (for example, networks, servers, storage, applications and services) that can be rapidly provisioned and released with minimal management effort or service provider interaction. (This is the standard, high-level definition; see NIST for the formal wording.)

  • On-demand self-service — definition: users can provision computing capabilities (for example, a virtual server or storage space) automatically, without requiring human interaction with the service provider. Assumption: the provider has automated APIs or portals.

  • Broad network access — definition: services are available over the network and accessed through standard mechanisms (web browser, REST API, CLI). Assumption: the network provides routable connectivity.

  • Resource pooling — definition: the provider’s resources are pooled to serve multiple consumers using a multi-tenant model, with different physical and virtual resources dynamically assigned and reassigned according to demand. Assumption: the provider supports virtualization or multi-tenancy isolation.

  • Rapid elasticity — definition: capabilities can be elastically provisioned and released to scale rapidly outward and inward; to the consumer it appears unlimited and can be purchased in any quantity at any time. Assumption: automation for provisioning and orchestration is available.

  • Measured service — definition: cloud systems automatically control and optimize resource use by leveraging a metering capability at some level of abstraction (e.g., storage, processing, bandwidth). The metering allows pay-per-use billing and monitoring.

Precise, exam-style statements and assumptions:

  • NIST essential characteristics: the five above (on-demand self-service, broad network access, resource pooling, rapid elasticity, measured service). State them and their definitions exactly.

  • Service models (brief reference): IaaS, PaaS, SaaS (service models define the level of control and the responsibilities of provider vs consumer). Do not re-teach here; students will meet these topics later in this track.

  • Deployment models (brief reference): public cloud, private cloud, hybrid cloud, community cloud. These are ways to place the resources and affect trade-offs (cost, control, security).

Trade-offs (the central engineering part): Explain trade-offs as pairs or triples where improving one property reduces another, or increases cost.

  1. Control vs cost and operational burden

    • More control (on-premises or private cloud) => higher capital expenditure (CapEx), higher operational effort (staffing, maintenance), slower scaling.
    • Less control (public cloud) => lower CapEx, faster provisioning, but greater dependence on provider and potential vendor lock-in.
  2. Security/isolation vs agility and cost

    • Stronger isolation (dedicated hardware, private clouds) reduces multi-tenancy risks but increases cost and reduces elasticity.
  3. Performance (latency, throughput) vs global availability

    • Placing compute near users reduces latency but increases complexity and cost (more regions). Edge and multi-region deployment are later topics (edge computing, distributed cloud).
  4. Consistency vs availability vs partition tolerance (CAP trade-off)

    • CAP theorem (define): In any distributed data system, it is impossible simultaneously to provide all three guarantees — Consistency (every read receives the most recent write), Availability (every request receives a response, without guarantee it contains the most recent write), and Partition tolerance (the system continues to operate despite network partitions). Assumptions: asynchronous network, replicated data across nodes. Practical implication: designers must choose which of the three to prioritise under partitions. Cloud databases expose this trade-off (see topics: Cloud storage and data management; Google's BigTable and GFS are relevant later).
  5. Vendor lock-in vs managed convenience

    • Using provider-specific managed services (databases, serverless functions) gives speed of development but increases migration cost if you want to move later.
  6. Cost predictability vs elasticity

    • Pay-as-you-go gives variable costs that match usage (good for scaling), while reserved or on-prem gives predictable costs but risks over-provision.

When an exam needs a diagram: draw a box labelled "Cloud Provider" containing pooled resources (draw several small boxes labelled CPU, Storage, Network) and arrows from many small user icons to the provider. Draw a governance box between provider and consumer for SLAs and billing. Label the five essential characteristics on the arrows or near the provider (one per arrow).

Formulas

Availability = MTBF / (MTBF + MTTR) — MTBF = mean time between failures (seconds or hours), MTTR = mean time to repair (same unit). Applies to single-component availability estimation.

System availability for n identical parallel components = 1 - (1 - A_single)^n — A_single is availability of one component (unitless fraction). Assumes independent failures and instant failover.

Little's Law: L = λ · W — L = average number of requests in system (dimensionless), λ = average arrival rate (requests per second, s^-1), W = average time a request spends in the system (seconds). Applies to stable queues in steady state.

Total annual cost ≈ CapEx_annualised + OpEx — CapEx_annualised = CapEx / n_years (if using straight-line), OpEx = running cost per year. Units: currency/year. Use for rough cost comparisons.

Utilisation = Busy_time / Total_time — unitless fraction. Useful when planning capacity and understanding when to scale.

Notes on formulas: assumptions are listed after each formula; for availability and redundancy formulas, verify independence of failures and the presence of correct failover.

Worked examples

  1. Cost comparison (numerical): Problem: A company can either buy a server cluster now for CapEx = ₹12,00,000 with expected lifetime 4 years and yearly OpEx (power, staff) ₹1,20,000, or use cloud VMs costing ₹40,000 per month. Compare costs over 4 years using straight-line annualisation. Steps:
  • Annualise the CapEx: CapEx_annualised = ₹12,00,000 / 4 = ₹3,00,000 per year.
  • Total annual on-prem cost = CapEx_annualised + OpEx = ₹3,00,000 + ₹1,20,000 = ₹4,20,000 per year.
  • Cloud cost per year = ₹40,000 × 12 = ₹4,80,000 per year.
  • Conclusion: On-prem is cheaper by ₹60,000/year in this basic model, but this ignores risks (scaling, redundancy, staff hiring) and time value of money. Answer: On-prem ₹4,20,000/year; Cloud ₹4,80,000/year; choose on-prem if you need constant capacity and can manage operations.
  1. Availability with redundancy: Problem: A single server has MTBF = 5000 hours and MTTR = 5 hours. What is its availability? If we have two identical servers in active-passive failover, what is system availability (assume instant failover and independent failures)? Steps:
  • Single availability A = MTBF/(MTBF + MTTR) = 5000/(5000+5) = 5000/5005 ≈ 0.999001 ≈ 99.9001%.
  • Two-server parallel availability = 1 - (1 - A)^2 = 1 - (1 - 0.999001)^2 = 1 - (0.000999)^2 ≈ 1 - 9.98e-7 ≈ 0.999999002 ≈ 99.9999002%.
  • Answer: Single ≈ 99.9001%; two-server ≈ 99.9999% (about "six nines").
  1. Theory-style model answer (short essay): Define the five essential characteristics and explain one trade-off (control vs cost). Model points to write: give the five definitions exactly, then explain how private cloud increases control but raises CapEx and operational effort; provide a short example (in-house data centre needs staff, cooling, predictable cost but slow scaling) and contrast with public cloud (fast scaling, pay-per-use, provider-managed). Mention vendor lock-in as a cost of convenience.

Common mistakes

  • Forgetting units when using Little’s Law (λ in s^-1, W in s).
  • Treating CAP theorem as a hard prohibition for all times; the correct view: under network partitions you must choose between consistency and availability.
  • Assuming cloud is always cheaper without accounting for scaling patterns, data egress costs, or operational staff.

For your exam

Typical question types: definitions (define cloud computing, define each essential characteristic), short notes (compare public vs private cloud), derivations (derive availability for n redundant identical servers), numericals (cost comparison, availability calculation, Little’s law queue problems), and diagrams (draw providers and tenants, draw redundancy with load balancer). Full-marks answers include: precise definitions with bold terms, assumptions stated, step-by-step derivations with units, and a short discussion of practical implications (trade-offs). If a diagram is required, label every element and explain how it maps to the definitions (e.g., label which arrow shows measured service or resource pooling).

Quick check

  1. Name the five essential characteristics of cloud computing.
  2. Write Little’s Law and state the unit of λ.
  3. If MTBF = 10,000 h and MTTR = 2 h, what is availability (in percent) for a single node? (Give answer to 4 decimal places.)

Answers: 1) On-demand self-service; Broad network access; Resource pooling; Rapid elasticity; Measured service. 2) L = λ · W; λ unit is s^-1 (requests per second). 3) Availability = 10,000/(10,002) = 0.99980004 = 99.9800%.

Finished this topic? Mark it so your progress, study plan and readiness keep up.

Stuck on something here?