CSC364 Software Engineering

Software EngineeringUnit 1113 min read

Risk Management in Software Projects: Types, Analysis, Mitigation & COCOMO

Unit 11 of Software Engineering explores risk identification, analysis (qualitative/quantitative), mitigation strategies, and cost estimation using COCOMO models (Organic/Embedded/Semi-Detached). It covers real-world risk scenarios in Nepalese projects (e.g., eSewa failures, Daraz delivery delays) and ethical dilemmas

TAKEAWAYS:

  • Risks in software projects are uncertain events that can impact cost, schedule, or quality—classify them into technical, project, business, or external types using a risk breakdown structure (RBS).
  • Risk analysis uses qualitative methods (probability/impact matrices) and quantitative methods (COCOMO, Monte Carlo simulations) to prioritize risks—e.g., a 320 KLOC project in Embedded mode requires 1,220 person-months (vs. 480 in Organic mode).
  • Mitigation strategies include avoidance (e.g., prototyping before full development), transfer (outsourcing high-risk modules), reduction (agile sprints for uncertainty), and acceptance (documenting known risks like NTC’s unreliable internet for Pathao drivers).
  • COCOMO models (Organic/Embedded/Semi-Detached) estimate effort and schedule by scaling KLOC—Embedded mode adds 3.6× effort for complexity (e.g., NEPSE’s trading system).
  • Ethical risks (e.g., cutting testing corners for deadlines) must balance stakeholder needs (e.g., Khalti’s fraud detection vs. user convenience) using frameworks like IEEE’s Software Engineering Code of Ethics.
  • Risk management is iterative: monitor risks via risk audits (e.g., Daraz’s post-launch traffic analysis) and update plans—80% of project risks are preventable with proactive tracking.

1. What is Risk in Software Projects?

Risk is any uncertain event or condition that, if it occurs, can have a positive or negative effect on a project’s objectives (cost, schedule, quality, or performance). Unlike issues (known problems), risks are potential—they may or may not happen.

Types of Software Project Risks

Risks are categorized into four broad groups. Use this risk breakdown structure (RBS) to organize them:

mindmap
  root((Software Project Risks))
    Technical
      Unclear Requirements
      Technology Obsolescence
      Performance Bottlenecks
    Project
      Schedule Overruns
      Budget Shortfalls
      Resource Shortages
    Business
      Market Changes
      Competitor Actions
      Regulatory Compliance
    External
      Natural Disasters
      Political Instability
      Vendor Failures

Example in Nepal:

  • eSewa’s 2021 outage: A technical risk (database failure) and external risk (power outage) caused NPR 1.2 billion in losses. The root cause? No redundancy plan for backup power.
  • Daraz’s delayed deliveries: A project risk (underestimated logistics) and business risk (rising fuel costs) led to customer churn.

2. Risk Management Process: A Step-by-Step Workflow

Risk management is not a one-time activity—it’s a continuous cycle with five key phases:

flowchart TD
  A["Risk Identification"] --> B["Risk Analysis"]
  B --> C["Risk Prioritization"]
  C --> D["Risk Mitigation Planning"]
  D --> E["Risk Monitoring & Control"]
  E --> A

Step 1: Risk Identification

Goal: List all potential risks before they impact the project. Methods:

  • Brainstorming: Gather the team to list risks (e.g., "Ncell’s network may fail during app launch").
  • Checklists: Use industry-specific risks (e.g., for banking software: fraud, compliance changes).
  • SWOT Analysis: Identify Strengths, Weaknesses, Opportunities, Threats (e.g., Pathao’s strength = driver network; threat = government regulations).
  • Historical Data: Learn from past projects (e.g., NTC’s fiber rollout delays due to terrain).

Example: For a Khalti-like digital wallet, risks might include:

Risk Category Example
Fraudulent transactions Technical Hackers exploiting API vulnerabilities
Low user adoption Business Competitors like IME Pay dominate
GDPR compliance issues External Nepal’s data laws change mid-project

Step 2: Risk Analysis (Qualitative vs. Quantitative)

Qualitative Analysis: Assesses risks based on probability and impact using a risk matrix.

Probability \ Impact Low Medium High
Low (10-30%) Accept Monitor Mitigate
Medium (30-60%) Monitor Mitigate Escalate
High (60-100%) Mitigate Escalate Avoid
Risk Probability Impact Score (P×I)
------------------------------- ----------------- ------------ -----------------
PCI-DSS compliance failure 4 5 20
Developer turnover 3 4 12
Power outage in server room 5 3 15
Strategy When to Use Example
--------------- ------------------------------------------ ----------------------------------------------
Avoid Risk is too severe to manage. Cancel a feature if it’s too complex (e.g., Daraz’s AI chatbot delayed).
Transfer Shift risk to a third party. Outsource cybersecurity to Nepal Telecom’s SOC.
Reduce Lower probability or impact. Use agile sprints to test UI early (e.g., eSewa’s MVP).
Accept Risk is low-impact or unavoidable. Document known risks (e.g., NTC’s internet speed fluctuations).
Aspect Waterfall Agile
-------------------------- ---------------------------------------- --------------------------------------------
Risk Identification Done upfront (high uncertainty later) Continuous (risks emerge in sprints)
Mitigation Hard to change scope Adaptive (pivot if a risk materializes)
Example NEPSE’s trading system (fixed scope) Khalti’s fraud detection (iterative)

Effort (PM) = 2.4 × (KLOC)^1.05 Time (months) = 2.5 × (Effort)^0.38

For **Embedded Mode** (complex, real-time systems):

Effort (PM) = 3.6 × (KLOC)^1.20 Time (months) = 2.5 × (Effort)^0.32

Worked Example: NEPSE Trading System

Assumptions:

  • Project Size: 320 KLOC (a medium-sized trading platform).
  • Mode: Embedded (real-time, high reliability).

Step 1: Calculate Effort

Effort = 3.6 × (320)^1.20
       ≈ 3.6 × 460.6
       ≈ 1,658 person-months

Step 2: Calculate Time

Time = 2.5 × (1,658)^0.32
     ≈ 2.5 × 6.1
     ≈ 15.3 months (~1 year 3 months)

Comparison with Organic Mode:

Mode Effort (PM) Time (months) Why?
Organic 480 10 Simple, co-located team
Embedded 1,658 15 Real-time constraints, strict testing

Real-World Tie-In:

  • NEPSE’s actual development took 18 months due to:
    • Underestimated KLOC (initial estimate: 250 KLOC).
    • Regulatory risks (SEB’s changing rules).
    • External risk: 2015 earthquake delayed testing.

5. Ethical Risks in Software Projects

Ethical risks arise when short-term gains conflict with long-term trust. Use IEEE’s Software Engineering Code of Ethics to guide decisions.

Common Ethical Dilemmas

Scenario Ethical Risk Solution
Cutting testing to meet deadlines Users suffer bugs (e.g., Khalti’s 2020 glitch). Use risk-based testing (prioritize critical paths).
Outsourcing to low-cost vendors Data privacy risks (e.g., Ncell’s offshore support). Sign NDAs and audit vendors.
Overpromising features Scope creep → project failure (e.g., Daraz’s delayed AI). Use agile commitments (deliver MVPs).

Example:

  • eSewa’s 2021 data leak: The team accepted the risk of weak encryption to launch faster. Result: NPR 50M fine + loss of user trust.
  • Solution: Always mitigate ethical risks via:
    1. Transparency (disclose risks to stakeholders).
    2. Compliance (follow Nepal’s IT Act 2018).
    3. User advocacy (prioritize security over speed).

6. Risk Monitoring and Control

Risks evolve—monitor them via:

  1. Risk Audits: Quarterly reviews (e.g., Daraz’s post-launch traffic analysis).
  2. Dashboards: Track risks in tools like Jira or MS Project.
  3. Contingency Plans: Predefined responses (e.g., NTC’s backup generators).

Example Workflow:

sequenceDiagram
    participant Dev as Developer
    participant PM as Project Manager
    participant Stakeholder as Stakeholder

    Dev->>PM: "Ncell’s API latency is increasing (Risk: High)."
    PM->>Stakeholder: "Escalate: Need backup API."
    Stakeholder->>PM: "Approve contingency: Use NTC’s CDN."
    PM->>Dev: "Implement CDN integration."
    Dev->>PM: "Risk mitigated."

In the Real World

  1. eSewa’s Risk Management Failures

    • Risk: Single point of failure (centralized database).
    • Impact: 2021 outage cost NPR 1.2B.
    • Lesson: Always mitigate technical risks with redundancy (e.g., Khalti’s distributed servers).
  2. Pathao’s Dynamic Pricing

    • Risk: Driver shortages during peak hours.
    • Mitigation: Surge pricing (economic risk transfer to users).
    • Result: 20% higher bookings in busy zones.
  3. NEPSE’s Trading System Delays

    • Risk: Regulatory changes mid-development.
    • Mitigation: Agile sprints to adapt to SEB rules.
    • Outcome: 6-month delay but compliant system.

Exam Tip

  1. COCOMO Questions:

    • Always show calculations step-by-step.
    • Memorize the exponents (1.05 for Organic, 1.20 for Embedded).
    • Example: For 100 KLOC in Semi-Detached mode (Effort = 3.0 × KLOC^1.12), calculate effort and time.
  2. Risk Matrix:

    • Plot risks on a 3×3 grid (Low/Medium/High for both axes).
    • Label quadrants (e.g., "Mitigate" for High/High).
  3. Ethical Risks:

    • Link to IEEE Code (e.g., "This violates Principle 1.03: Honesty").
    • Use Nepalese examples (e.g., Khalti’s fraud vs. user convenience).
  4. Agile vs. Waterfall:

    • Waterfall: Risks are known early but hard to change.
    • Agile: Risks are managed iteratively (e.g., eSewa’s beta testing).
  5. Past Exam Patterns:

    • Short Answer: Define risk breakdown structure (RBS) or COCOMO modes.
    • Long Answer: Explain risk mitigation for a given scenario (e.g., "How would you handle a 50% developer dropout in a 6-month project?").
      • Structure:
        1. Identify risk (e.g., knowledge loss).
        2. Analyze impact (e.g., 3-month delay).
        3. Mitigate (e.g., pair programming + documentation).
        4. Monitor (e.g., weekly knowledge transfer sessions).

Key Formulas to Memorize

Model Effort Formula Time Formula
Organic 2.4 × (KLOC)^1.05 2.5 × (Effort)^0.38
Embedded 3.6 × (KLOC)^1.20 2.5 × (Effort)^0.32
Semi-Detached 3.0 × (KLOC)^1.12 2.5 × (Effort)^0.35

Final Checklist for Risk Management

Before submitting your answer, ensure you’ve covered: ✅ Risk types (technical, project, business, external). ✅ Risk analysis (qualitative matrix + COCOMO). ✅ Mitigation strategies (avoid, transfer, reduce, accept). ✅ Real-world example (eSewa, Pathao, NEPSE). ✅ Ethical considerations (IEEE Code + Nepalese context). ✅ Exam tips (COCOMO steps, risk matrix plotting).

Based on the TU BSc CSIT syllabus for Software Engineering (CSC364), unit 11.

Discussion

Loading…