CACS402 Cloud Computing

Cloud ComputingUnit 129 min read

Cloud in Business & Consumer Apps: Models, Cases & Impact

Unit 12 of Cloud Computing explores how cloud technologies transform industries—from e-commerce (Daraz) to banking (Ncell eSewa)—through real-world deployments, cost-benefit analyses, and scalability strategies. Covers SaaS/PaaS/IaaS in business, consumer apps (WhatsApp, YouTube), and challenges like latency or complia

TAKEAWAYS

  • Cloud computing in business reduces CapEx by replacing hardware with pay-as-you-go services (e.g., Google Cloud for startups).
  • Consumer apps (WhatsApp, YouTube) use cloud for scalability (handling millions of users) and global CDNs (low-latency content delivery).
  • Hybrid clouds (e.g., Ncell’s private cloud + AWS) balance security (private) and flexibility (public).
  • MapReduce (used by Google for indexing) splits big data tasks into parallel jobs on clusters.
  • Challenges: Data sovereignty (Nepal’s NTC must store citizen data locally), vendor lock-in (e.g., migrating from AWS to Azure), and compliance (PCI-DSS for banks).
  • Exam focus: Compare business vs. consumer use cases, explain cost models (OPEX vs. CapEx), and link cloud models (SaaS/PaaS/IaaS) to real services.

1. Cloud Computing in Business: Transforming Operations

Cloud adoption in businesses spans cost savings, agility, and innovation. The three service models (SaaS/PaaS/IaaS) serve distinct needs:

1.1 Service Models in Business

Model Business Use Case Example (Nepal) Cloud Provider
SaaS Ready-to-use software (no IT management) eSewa (bill payments), Khalti (wallet) Google Workspace, Salesforce
PaaS Develop/test apps without infrastructure Ncell’s mobile app backend Heroku, Google App Engine
IaaS Rent virtual servers/storage for custom apps Daraz’s order processing servers AWS EC2, Azure VMs

Why it matters:

  • eSewa (SaaS) lets users pay bills without building its own servers.
  • Ncell (PaaS) uses Google Cloud to deploy APIs for its app without managing hardware.
  • Daraz (IaaS) scales servers during sales (e.g., Dashain) using AWS auto-scaling.

1.2 Cost Models: CapEx vs. OPEX

Businesses shift from Capital Expenditure (CapEx)—buying servers—to Operational Expenditure (OPEX)—paying for cloud services. Example: A Kathmandu café replacing a $5,000 server with $50/month on Google Cloud for its POS system.

Metric Traditional (On-Prem) Cloud (OPEX)
Upfront Cost $10,000 (servers, cooling) $0 (pay per use)
Scalability Manual (add servers) Automatic (scale up/down)
Maintenance IT team required Provider handles updates

Worked Example: A Nepalese bank (e.g., NMB) uses AWS IaaS for loan processing:

  • Before: 10 physical servers costing $50,000/year.
  • After: 10 virtual servers costing $15,000/year + auto-scaling during peak hours (e.g., loan application surges).

2. Cloud in Consumer Applications: How Apps Use the Cloud

Consumers interact with cloud daily—often without realizing it. Here’s how:

2.1 Global Scale: YouTube and WhatsApp

App Cloud Role Provider Key Tech
YouTube Stores videos, delivers via CDN Google Cloud Global edge caching
WhatsApp Handles 2B+ messages/day AWS Kubernetes clusters
Pathao Matches drivers/riders in real-time Azure Geo-distributed databases

How it works:

  1. YouTube:

    • Videos are stored in Google’s global data centers.
    • When you watch, the nearest edge server (e.g., in Kathmandu) streams the video.
    • Cost saved: No need for YouTube to build servers in every country.
  2. WhatsApp:

    • Uses AWS’s distributed databases to sync messages across devices.
    • Challenge: Ensuring <1s latency for 2B users (solved via multi-region replication).

2.2 Local Examples: eSewa and Daraz

  • eSewa (SaaS):

    • Problem: Millions of transactions daily during festivals (Dashain, Tihar).
    • Solution: Uses AWS Lambda (serverless) to handle spikes without over-provisioning.
    • Security: PCI-DSS compliant (mandatory for payment processing).
  • Daraz (IaaS):

    • Order Processing:
      1. User places order → request hits AWS EC2 (virtual server).
      2. Auto-scaling adds servers if traffic exceeds 10,000 orders/hour.
      3. Database: Amazon RDS (PostgreSQL) stores orders, user data.
    • Delivery Tracking: Uses AWS IoT to update real-time location via GPS.

Mermaid Diagram: Daraz Order Flow

sequenceDiagram
    User->>Daraz: Places order (HTTP)
    Daraz->>EC2: Route request (Load Balancer)
    EC2->>RDS: Store order (SQL)
    RDS-->>EC2: Confirmation
    EC2->>User: Show order ID
    Daraz->>IoT: Update delivery status
    IoT->>User: Push notification

3. Challenges in Business and Consumer Cloud Adoption

Despite benefits, clouds face hurdles:

3.1 Technical Challenges

Challenge Impact Solution
Latency Slow response in Kathmandu (vs. Singapore) Use edge computing (e.g., Cloudflare)
Data Sovereignty Nepal’s law requires citizen data in Nepal Private cloud (e.g., NTC’s local servers)
Vendor Lock-in Migrating from AWS to Azure is costly Use multi-cloud tools (e.g., Terraform)
Downtime AWS outage in 2021 affected Slack, Zoom Multi-region deployment

Example:

  • NTC’s Challenge: Cannot store customer data in AWS (US servers). Solution: Built a private cloud in Nepal with VMware.

3.2 Security and Compliance

  • Banks (NMB, Global IME): Must comply with PCI-DSS (credit card security).
    • Solution: Encrypt data at rest (AES-256) and in transit (TLS).
  • e-Governance (eSewa): Must protect citizen Aadhaar data.
    • Solution: Zero-trust architecture (verify every access request).

4. Distributed Computing: Behind the Scenes

Many cloud apps use distributed computing to handle massive workloads. Two key models:

4.1 MapReduce: Google’s Secret Sauce

Used by Google Search, Facebook, and Netflix to process petabytes of data.

How it works:

  1. Map Phase: Split data into chunks (e.g., index all Nepali news articles).
  2. Shuffle: Sort chunks by keyword (e.g., "cloud computing").
  3. Reduce Phase: Combine results (e.g., count occurrences).

Example: Google Indexing

  • Problem: Index 50B web pages.
  • Solution: MapReduce divides the task across 10,000 servers, each processing a subset.

Mermaid Diagram: MapReduce Flow

flowchart TD
    A["Input Data\n(e.g., 50B web pages)"] --> B["Split into chunks\n(Map Task 1-10,000)"]
    B --> C["Process each chunk\n(e.g., extract keywords)"]
    C --> D["Shuffle & Sort\n(by keyword)"]
    D --> E["Combine results\n(Reduce Task)"]
    E --> F["Output\n(Indexed search database)"]

4.2 Challenges of Distributed Systems

Issue Example Fix
Data Consistency Two servers show different inventory Consensus algorithms (e.g., Paxos)
Fault Tolerance Server fails during Daraz sale Replication (copy data to 3 servers)
Network Latency Slow sync between Kathmandu & Singapore Geo-partitioning (split data by region)

5. Cloud for e-Governance: Nepal’s Digital Transformation

Nepal’s e-Governance relies on cloud for:

  • eSewa: Bill payments (SaaS).
  • Citizen Service Portals: Single window for permits (PaaS).
  • NTC’s Private Cloud: Stores telecom data locally (IaaS).

Case Study: NTC’s Cloud Strategy

  • Problem: Store 10M+ subscriber data securely.
  • Solution:
    • Private cloud (on-premise servers) for compliance.
    • Hybrid cloud: Uses AWS for analytics (e.g., predicting network congestion).
  • Result: Reduced costs by 40% vs. traditional data centers.

6. Exam Tip: How to Score Full Marks

  1. Compare Models:

    • Always use a table (like above) for SaaS/PaaS/IaaS or public/private clouds.
    • Example Answer:

      "Public clouds (e.g., AWS) offer scalability but lack control; private clouds (e.g., NTC) ensure security but require high CapEx. Hybrid clouds (e.g., Ncell) combine both."

  2. Link to Real Examples:

    • eSewa: "Uses SaaS for bill payments, reducing NTC’s IT overhead."
    • YouTube: "Relies on CDNs for low-latency delivery in Kathmandu."
  3. Explain Trade-offs:

    • Latency vs. Cost: "Edge computing reduces latency but increases costs."
    • Security vs. Convenience: "PCI-DSS compliance adds steps but prevents breaches."
  4. Diagrams = Marks:

    • Draw sequence diagrams for app flows (e.g., Daraz order processing).
    • Use layered models for cloud services (SaaS on top of IaaS).
  5. Common Pitfalls:

    • ❌ "Cloud is only for big companies." → ✅ "Even small businesses (e.g., local cafés) use SaaS like Google Workspace."
    • ❌ "All clouds are secure." → ✅ "Private clouds (e.g., NTC) are more secure than public ones (e.g., AWS) for sensitive data."

Final Note: Cloud computing is not just technology—it’s a business strategy. Whether it’s eSewa’s SaaS, Daraz’s IaaS, or Ncell’s hybrid cloud, the key is matching the model to the need. For exams, always tie theory to real examples—examiners love this!

Based on the TU BCA syllabus for Cloud Computing (CACS402), unit 12.

Discussion

Loading…