Developer Productivity Metrics | DORA Guide
Measure developer productivity with DORA metrics, cycle time, and throughput. GitScrum provides meaningful team metrics without creating perverse incentives.
6 min read
Measuring developer productivity is essential but fraught with danger. Bad metrics create gaming, destroy morale, and miss what matters. Good metrics provide insight, drive improvement, and respect the complexity of software development.
Metrics Philosophy
| Avoid | Embrace |
|---|---|
| Lines of code | Value delivered |
| Commits per day | Cycle time |
| Hours worked | Throughput |
| Individual ranking | Team performance |
| Activity metrics | Outcome metrics |
Useful Metrics
DORA Metrics
DORA METRICS FRAMEWORK
ββββββββββββββββββββββ
DEPLOYMENT FREQUENCY
βββ How often code is deployed to production
βββ Elite: Multiple times per day
βββ High: Weekly to monthly
βββ Medium: Monthly to yearly
βββ Low: Less than yearly
LEAD TIME FOR CHANGES
βββ Time from commit to production
βββ Elite: Less than one hour
βββ High: One day to one week
βββ Medium: One week to one month
βββ Low: More than one month
CHANGE FAILURE RATE
βββ Percentage of deployments causing issues
βββ Elite: 0-15%
βββ High: 16-30%
βββ Medium: 31-45%
βββ Low: 46-100%
MEAN TIME TO RECOVER (MTTR)
βββ Time to restore service after incident
βββ Elite: Less than one hour
βββ High: Less than one day
βββ Medium: One day to one week
βββ Low: More than one week
Flow Metrics
FLOW METRICS
ββββββββββββ
CYCLE TIME
βββ Time from work started to work completed
βββ Measures: Development efficiency
βββ Good for: Identifying bottlenecks
βββ Target: Consistent, trending down
Typical Breakdown:
βββ Development: 40%
βββ Code review: 30%
βββ QA/Testing: 20%
βββ Deploy: 10%
LEAD TIME
βββ Time from request to delivery
βββ Measures: Total responsiveness
βββ Good for: Customer perspective
βββ Includes: Queue time before starting
THROUGHPUT
βββ Items completed per time period
βββ Measures: Delivery capacity
βββ Good for: Planning, predictability
βββ Compare: Week over week
WORK IN PROGRESS (WIP)
βββ Items currently in progress
βββ Measures: Focus vs. context switching
βββ Good for: Overload detection
βββ Target: Low and stable
Quality Metrics
QUALITY METRICS
βββββββββββββββ
BUG DENSITY
βββ Bugs per feature or per release
βββ Trend: Should decrease over time
βββ Action: Invest in testing if high
βββ Context: Some features naturally riskier
TEST COVERAGE
βββ Percentage of code covered by tests
βββ Target: 70-80% (not 100%)
βββ Action: Cover critical paths
βββ Warning: Coverage β quality
CODE REVIEW METRICS
βββ Time to first review
βββ Review cycles per PR
βββ Trend: Should be stable
βββ Action: Improve if increasing
TECHNICAL DEBT
βββ Known debt items tracked
βββ Debt addressed per sprint
βββ Trend: Should not grow unchecked
βββ Action: Allocate capacity
Measuring the Right Way
Team Not Individual
WHY TEAM METRICS
ββββββββββββββββ
INDIVIDUAL METRICS PROBLEMS:
βββ Encourages gaming
βββ Ignores collaboration value
βββ Punishes helping others
βββ Creates competition
βββ Misses pair/mob programming
βββ Demotivating
TEAM METRICS BENEFITS:
βββ Encourages collaboration
βββ Shared ownership
βββ Focuses on outcomes
βββ Reduces gaming incentive
βββ Celebrates team success
βββ More accurate
EXAMPLE:
Instead of:
"Sarah committed 47 times this week"
Use:
"Team delivered 5 features this sprint
with 0 production incidents"
Avoid Vanity Metrics
VANITY VS ACTIONABLE METRICS
ββββββββββββββββββββββββββββ
VANITY METRICS:
β Lines of code written
β Commits per day
β Hours logged
β Stories completed count
β Velocity points (easily inflated)
WHY THEY'RE BAD:
βββ Easily gamed
βββ Reward wrong behavior
βββ Miss quality
βββ Create perverse incentives
βββ Don't correlate with value
ACTIONABLE METRICS:
β Cycle time (can improve process)
β Deployment frequency (measures flow)
β Change failure rate (measures quality)
β Customer issues (measures impact)
β Developer experience (measures sustainability)
WHY THEY'RE GOOD:
βββ Hard to game
βββ Tied to outcomes
βββ Drive improvement
βββ Balanced view
βββ Actionable
Dashboards and Visibility
Productivity Dashboard
TEAM PRODUCTIVITY DASHBOARD
βββββββββββββββββββββββββββ
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
β Engineering Productivity - March 2024 β
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ€
β β
β DORA METRICS β
β βββββββββββββββ¬ββββββββββββββ¬ββββββββββββββ β
β β Deploy Freq β Lead Time β Fail Rate β β
β β 3.2/day β 2.1 days β 4.2% β β
β β β from 2.8 β β from 2.8 β β from 6% β β
β β π’ Elite β π’ High β π’ Elite β β
β βββββββββββββββ΄ββββββββββββββ΄ββββββββββββββ β
β β
β FLOW METRICS β
β Cycle Time: 4.2 days avg (β 0.5 from last month) β
β Throughput: 23 items/week (stable) β
β WIP Average: 2.1 per developer (healthy) β
β β
β QUALITY β
β Bug Density: 0.3 bugs/feature (β good) β
β Test Coverage: 78% (stable) β
β Review Time: 4.2 hours avg (acceptable) β
β β
β TRENDS (6 months) β
β Cycle Time: βββββ Improving β
β Throughput: βββββ Stable/growing β
β Quality: βββββ Stable/improving β
β β
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
Developer Experience
DEVELOPER EXPERIENCE SURVEY
βββββββββββββββββββββββββββ
QUARTERLY SURVEY QUESTIONS:
(Scale 1-5, with comments)
FLOW & FOCUS:
βββ I can focus on coding without interruptions
βββ I have the tools I need to be productive
βββ Our processes help rather than hinder
QUALITY & SUSTAINABILITY:
βββ I'm proud of the code we ship
βββ Technical debt is manageable
βββ Our workload is sustainable
COLLABORATION:
βββ Code reviews are helpful and timely
βββ I can get help when I need it
βββ Team communication works well
GROWTH:
βββ I'm learning and growing
βββ I understand our architecture
βββ I can influence technical decisions
AGGREGATE SCORE:
βββ Team DX Score: 4.1/5 (β from 3.8)
βββ Track over time
βββ Act on feedback
Best Practices
For Productivity Metrics
Anti-Patterns
METRICS MISTAKES:
β Individual productivity rankings
β Lines of code as measure
β Punishing based on metrics
β Single metric focus
β Metrics without action
β Gaming-prone measures
β Ignoring developer experience
β Comparing teams directly