Definition Of DoneDevelopersQuality

Creating a Definition of Done for Backend and API Teams

ScrumPoi · · 12 min read

Creating a Definition of Done for Backend and API Teams

“Done” Is a Lie for Most Backend Teams

Ask five backend engineers what “done” means, you’ll get seven answers.

Code merged?
Tests passing?
Deployed to prod?
Monitored?
Documented?

Here’s the uncomfortable truth: most backend and API teams ship half-baked work and call it “done” because their Definition of Done (DoD) is either:

  • A vague poster on a wall nobody reads, or
  • A copy-paste from a generic Scrum template that ignores how backend systems actually fail.

A 2022 survey by GitLab reported that only 25–30% of teams have a consistently applied, documented Definition of Done. The rest are winging it. And backend teams pay the price in:

  • Nighttime incidents
  • “Quick” hotfixes that spawn more bugs
  • APIs that work in staging but mysteriously fail in prod
  • Constant scope arguments: “I thought you were handling that…”

You don’t need more process theater. You need a sharp, opinionated Definition of Done tailored to backend and API work.

Let’s build that.


What a Real Definition of Done Is (and Isn’t)

DoD vs. “Looks Good to Me”

A Definition of Done is not:

  • “Code reviewed and merged”
  • “QA approved”
  • “Deployed to staging”

Those are activities, not outcomes.

A good DoD for backend/API teams defines the minimum conditions under which a change is safe, supportable, and releasable. It should answer:

“If we shipped this to production right now, would we be comfortable owning it at 2 a.m.?”

If the honest answer is “maybe,” it’s not done.

Why Backend and API Teams Need a Different DoD

Backend work has unique failure modes:

  • A tiny performance regression can bring down a critical service.
  • A “small” schema change can break five downstream consumers.
  • A non-idempotent endpoint can wreak havoc under retries.
  • A missing metric can turn debugging into archaeology.

So your DoD must cover:

  • Contract stability and compatibility
  • Data integrity and migration safety
  • Observability (logs, metrics, traces)
  • Performance and scalability under realistic load

If your DoD doesn’t mention those, it’s incomplete.


Core Components of a Backend/API Definition of Done

You don’t need a 3-page checklist. You need a short, brutal list of non-negotiables.

Below is a practical template. Adapt, don’t blindly adopt.

1. Code Quality and Tests

At minimum, “done” should mean:

  • Unit tests cover core logic and edge cases
  • API contract tests for public endpoints (e.g., using Pact or similar, if you have consumers)
  • Integration tests for critical flows (e.g., DB + external service)
  • Tests are stable (no known flakes)
  • Code coverage threshold met for changed code (e.g., 80%+ on touched files, not the whole repo)

Opinionated stance:
If your backend change has no tests, it is not done. I don’t care how “simple” it is.

2. API Contract and Backward Compatibility

For API teams, this is non-negotiable:

  • Breaking changes are explicitly called out and versioned (v1 → v2), or
  • Change is backward compatible, validated by:
    • Contract tests
    • Consumer tests in CI, or
    • A documented compatibility strategy (e.g., additive changes only)

Backward compatible usually means:

  • Only adding new fields (never removing or changing semantics)
  • Keeping existing behavior unless versioned
  • Deprecation policy is followed (e.g., 90 days notice before removal)

If you’re merging changes that break clients without a migration strategy, you don’t have a DoD problem; you have a trust problem.

3. Data and Migration Safety

Schema and data changes deserve their own bullets:

  • Migrations are backward compatible with the current code in production
  • Migrations are idempotent and safe to re-run
  • There is a rollback or remediation plan (not just “revert the PR”)
  • Large migrations are:
    • Split into phases (expand → backfill → contract)
    • Tested on staging with prod-like data volume

Concrete example:

  • Expand: Add new new_column nullable
  • Migrate: Backfill new_column from old_column
  • Switch: Update app code to use new_column
  • Contract: Remove old_column after verification

If your DoD allows a “one-shot” destructive migration in a single deploy, you’re one fat-finger away from a postmortem.

4. Observability and Operability

Backend work isn’t done if you can’t see what it’s doing.

  • Logs:
    • Structured logs for key events (requests, errors, business events)
    • No sensitive data in logs (PII, secrets)
  • Metrics:
    • At least one key metric per new feature (e.g., request counts, latency, error rate)
    • Alerts configured for critical failure modes
  • Tracing (if you have distributed tracing):
    • New endpoints participate in trace context
    • Spans added around critical operations

Ask this before merging:

“If this breaks in production, how will we know, and how will we debug it?”

If the answer is “we’ll add metrics later,” it’s not done.

5. Security and Compliance Basics

You don’t need a full security review for every small change, but you do need guardrails:

  • Authentication and authorization paths tested
  • Input validation and output encoding where appropriate
  • Secrets not hardcoded; use secret management
  • Compliance requirements (e.g., GDPR, PCI) considered for new data fields

Minimal but real: for any new endpoint, add a checklist item:

  • “Is this data sensitive? If yes, how is it protected and logged?”

6. Documentation and Consumer Readiness

If others can’t safely use your API, it isn’t done.

  • Public endpoints documented:
    • Parameters, responses, error codes
    • Rate limits or usage constraints
  • Change log updated for externally visible changes
  • Feature flags or toggles documented (how to enable, who owns them)
  • Runbook updated if this affects production operations

Documentation doesn’t have to be pretty. It has to exist.


Common Mistakes Backend Teams Make with DoD

Mistake 1: Copy-Pasting a Generic Scrum DoD

You know the one:

  • “Code reviewed”
  • “Unit tests written”
  • “QA passed”

That might be fine for a UI team. For backend and APIs, it’s dangerously incomplete.

Fix: Add backend-specific criteria: migrations, backward compatibility, observability, performance.

Mistake 2: Confusing “Definition of Ready” with “Definition of Done”

Teams often cram “requirements are clear” or “design is approved” into their DoD. That’s pre-work, not “done.”

  • Definition of Ready (DoR): “Can we start this?”
  • Definition of Done (DoD): “Can we ship this to prod and sleep at night?”

Keep them separate or your DoD becomes a dumping ground.

Mistake 3: Making the DoD Too Long to Use

A 50-item checklist will be ignored within a sprint.

Signs your DoD is bloated:

  • No one can recite the top 5 items from memory.
  • It lives in a Confluence page last edited 9 months ago.
  • People say, “We don’t have time to do all that.”

Fix:

  • Limit your DoD to 10–15 core items.
  • Use conditional add-ons (e.g., “If DB migration, then…”).

Mistake 4: Having a DoD That’s Aspirational, Not Enforced

If your DoD says “performance tested,” but your pipeline has no performance tests, that’s not a DoD—that’s wishful thinking.

Your DoD must be:

  • Automated where possible (CI pipelines, quality gates)
  • Visible in your workflow (e.g., Jira, PR templates)
  • Enforced by the team, not just the Scrum Master

Mistake 5: Same DoD for Every Type of Work

Bug fix vs. new service vs. experimental feature—they don’t all need the same rigor.

Fix: Use base DoD + modifiers:

  • Base DoD: applies to all backend work
  • Extra items for:
    • Public APIs
    • DB schema changes
    • High-risk features

How to Create a Definition of Done That Actually Works

Step 1: Start with Real Incidents and Pain

Don’t start with theory. Start with scars.

In a workshop (60–90 minutes):

  1. List your top 5 incidents or production headaches from the last 6–12 months.
  2. For each, ask:
    • What was missing that would have prevented or reduced this?
    • Was it tests? Metrics? Docs? Backward compatibility?

Examples:

  • Outage due to a bad migration → Add “backward compatible migrations” and “rollback plan.”
  • Broken client due to response change → Add “API contract tests” and “backward compatibility check.”
  • Silent failure unnoticed for days → Add “critical metrics + alerting.”

This grounds your DoD in reality, not dogma.

Step 2: Draft a Short, Opinionated DoD

Aim for:

  • 10–15 core items
  • Clear, testable statements (no “as appropriate” fluff)

Example core DoD for a backend/API team:

  • Code reviewed by at least one backend engineer
  • Unit tests and integration tests added/updated; CI green
  • API changes are backward compatible OR versioned and documented
  • DB migrations are backward compatible and have a rollback/remediation plan
  • Logs, metrics, and (if available) traces added for new critical paths
  • Security implications reviewed; secrets handled correctly
  • Public endpoints documented; changelog updated
  • Feature flags documented and owned
  • Deployed to staging and verified against realistic data/traffic
  • No critical alerts triggered in non-prod environments for this change

Then add conditional sections:

  • For DB changes:
    • Migrations tested on staging with production-like data size
  • For public APIs:
    • Consumer contracts validated (contract tests or client tests)

Step 3: Wire It into Your Tools

A DoD that lives in a wiki and nowhere else will die.

Make it unavoidable:

  • PR template:
    • Include the core DoD checklist
    • Ask explicitly: “Does this change include any DB migrations or public API changes?” → link to extra checks
  • Jira (or your tracker):
    • Add a custom field or checklist for DoD items
    • Definition of Done must be checked before moving to “Done” or “Ready for Release”
  • CI/CD pipeline:
    • Enforce minimum test coverage on changed files
    • Run contract tests and integration tests
    • Fail builds if critical quality gates are not met

Step 4: Start Strict, Then Adjust—But Don’t Water It Down

You’ll get pushback:

  • “This is too much work.”
  • “We’ll never ship anything.”
  • “We don’t have time for all these tests.”

Two responses:

  1. Good. If it feels stricter than what you do today, that’s the point.
  2. Track metrics:
    • Number of incidents per release
    • Time spent on hotfixes
    • Mean time to recovery (MTTR)

If your DoD isn’t reducing incidents or support pain after a few sprints, adjust. But don’t just remove items because they’re inconvenient; remove them if they’re not producing value.

Step 5: Review and Evolve Quarterly

Backend systems evolve, so should your DoD.

Every 3 months:

  • Review:
    • What items are never checked or always rubber-stamped?
    • What incidents slipped through despite the DoD?
  • Add, remove, or clarify 1–3 items—not a full rewrite.

This keeps the DoD lean and relevant instead of becoming legacy process.


Tactical Examples: Turning Fuzzy into Concrete

Here are some fuzzy DoD items and how to make them useful for backend/API work.

Fuzzy: “Performance Tested”

Concrete:

  • For endpoints with expected >100 RPS, run a load test:
    • Target latency: p95 < 300ms
    • Error rate < 0.1% under expected peak load
  • Compare to baseline; no regression >10% allowed without explicit sign-off

Fuzzy: “Monitored”

Concrete:

  • New endpoints expose:
    • Request count
    • Latency (p50, p95, p99)
    • Error rate by status code family
  • At least one alert configured for a critical failure mode (e.g., 5xx > 2% for 5 minutes)

Fuzzy: “Documented”

Concrete:

  • API docs updated with:
    • Endpoint path, method
    • Request/response schema
    • Auth requirements
    • Example request/response
  • Internal runbook updated if:
    • On-call needs to know how to operate/debug this feature

Using Tools to Make the DoD Easier (Not Heavier)

A good Definition of Done shouldn’t mean more meetings; it should mean more automation and clearer conversations.

  • Use CI to enforce tests, coverage, and contract checks.
  • Use PR templates and issue templates to surface the DoD where work happens.
  • Use lightweight tools for planning and retros that actually help you refine your DoD over time.

For example, teams I work with use tools like ScrumPoi for quick, no-signup planning poker and retrospectives, then use those retro insights to tweak their DoD based on real sprint pain—not theory.


Wrap-Up: “Done” Should Feel Slightly Uncomfortable

If your backend/API team’s Definition of Done feels easy, it’s probably useless.

A good DoD:

  • Prevents the incidents you’re tired of repeating
  • Forces you to think about contracts, data, and observability
  • Is short enough to remember, strict enough to matter
  • Lives in your day-to-day tools, not just on a wiki page

You don’t need the perfect DoD. You need a real, enforced, evolving one that makes “done” mean “we can ship this to production and not regret it.”

Start with your last five incidents. Turn each one into a DoD safeguard. Wire it into your PRs and pipeline. Then let your next retrospective tell you what to sharpen next.

Keep reading

More on the topics this article touches.