When Not to Federate

What Federation Buys, and What It Doesn't

Earlier sections made the benefits concrete. The honest ledger is narrower than the pitch:

Problem you haveDoes federation fix it?Cheaper fix if it's your only problem
One API team gates every schema change (the "monolith in the middle")Yes. This is the problem it was built for.None at comparable scale. Moving code ownership into a GraphQL monolith (CODEOWNERS per type) helps for a while.
Device BFFs duplicate orchestration N timesPartly. Orchestration moves into the planner, but device policy has to go somewhere (see Where the BFF's jobs go).One GraphQL BFF that all devices query, keeping the device knobs as field arguments.
Member 42 fetched five times per renderOnly within one fetch node (see The query planner); hidden service-to-service calls are untouched unless those dependencies move into the schema.EVCache (Netflix's actual answer), or a per-request DataLoader in a single GraphQL service.
Page latencyNo. It adds a hop and ~ms of (de)serialization (see Operating the gateway), and sequential plan depth is unchanged.Fix the critical path: parallelism, caching, @defer.
Over-fetching on constrained devicesGraphQL fixes this. Federation adds nothing extra.A single GraphQL server, or Falcor-style paths.
Inconsistent authorization across UIsYes as a side effect: authz moves into subgraph resolvers (Netflix Studio, Part 2).A shared authz library or sidecar.

The Member-42 Test, From the Other Side

The Netflix Architecture guide row that started this guide says the dedupe "must live where the plan lives" and that "no individual service could do this". The first half is correct. The second half overlooks the cheapest thing that has the whole plan: a single GraphQL service. In a monolithic GraphQL server, all five branches that need member 42 resolve in one process, inside one request context, and they share one per-request DataLoader (see What GraphQL changes). Entitlements, maturity level, language, avatar and plan all become load(42) calls, which collapse to one batched fetch no matter how deep or how far apart the fields are in the tree. The federated planner merges them only when they end up in the same fetch node at the same plan level (see The query planner). Otherwise the dedupe happens again, one level down, in the member subgraph's own DataLoader, once per _entities call. So if deduplication is your main reason to leave BFFs, a GraphQL monolith does it better and has no planner. You federate for a different reason: too many teams need to edit that monolith.

Federation distributes ownership; it doesn't concentrate work. Every benefit that comes from seeing the whole request (dedupe, batching, a single response shape) is at least as strong in one GraphQL process. What federation adds is the ability for 200 teams to change that shape without editing each other's code, and it pays for that with a planner and a network hop.

The Costs, Itemized

Netflix is unusually open about this. At QCon Plus 2020 Spalding and Shin listed the bill. A team "devoted to building and operating a brand new platform": they "dedicated three engineers to building out the core components like the gateway and the registry", a whole separate team to DGS developer experience and tooling, and more people for distributed-tracing instrumentation. They also "merged two teams that used to be part of two totally separate organizations". And there is a cost that doesn't show up in headcount: "you'll be distributing the concerns of the API layer instead of shielding your engineering teams from them … potentially a radical and costly shift, especially if most engineers in your organization are not generally concerned with matters like defensive programming or security." The Part 2 post says federation "may not be the best fit for every team or organization". In Tejas Shikhare's QCon SF 2022 talk (InfoQ write-up) the lesson was "Federation is not free": Netflix had to build GraphHub for schema collaboration, GraphDoctor for linting, Graphlabs sandboxes, and usage stats to drive deprecation.

PlatformGateway + registry + composition CI + tracing; a team that owns them
Every domain teamGraphQL, entity resolvers, DataLoader, nullability design, on-call for a public contract
Runtime+1 hop; ~10 ms worst case at Netflix (2020); plan-cache cold starts
GovernanceSchema working group, linting, deprecation workflow (see Schema governance)
MigrationStudio: gateway built from Jul 2019, self-serve Apr 2020, monolith slated for removal end of 2020
LicensingSeveral router features (operation limits, demand control) are GraphOS-plan features; check before designing around them

The Alternatives, Taken Seriously

1. Keep the BFFs, and make each one GraphQL

Phil Calçado, who helped popularize BFFs at SoundCloud, argued in "Some thoughts on GraphQL vs. BFF" (2019) that the two are orthogonal: "You can build your GraphQL APIs as many BFFs or as an OSFA API." He also reported Marc-André Giroux's advice that an organization invested in REST BFFs should "keep their separate APIs and migrate them to GraphQL, instead of trying to jump to an OSFA GraphQL API." The device team keeps full autonomy over its own API. The duplicated orchestration stays, but DataLoader removes much of the duplicated fetching inside each BFF.

2. One GraphQL monolith

This is one schema served from one deployable, with ownership enforced through code review instead of a network boundary. It has the strongest dedupe (above), no planner, no composition and a single deploy, and it's the shape of large single-schema public APIs like GitHub's GraphQL API, where Giroux worked (he later joined Netflix's GraphQL platform team). It stops working when the monolith's deploy queue or its owning team becomes the bottleneck. That is exactly what happened to Netflix Studio: Kavitha Srinivasan describes, on the InfoQ podcast, a gateway that stitched team schemas together and then "added on more and more business logic to the gateway, which is a huge anti-pattern" until "we just didn't have enough folks who could keep up."

3. A thin BFF in front of the graph

Federate the entities, and keep a small screen-owned layer for what belongs to neither side (see Where the BFF's jobs go): TV gets 40 rows × 75 titles, the phone gets fewer, feature gates depend on device capability. This is the honest end state for many consumer apps. It isn't a failure to finish the migration. The trap is letting that layer grow back into orchestration.

4. REST/gRPC with explicit aggregation

For a small number of first-party clients with stable screens, a hand-written aggregator that fetches member 42 once and passes it down is simpler than any of the above. The cost is the coupling the Netflix guide names: the member shape ends up in five contracts. With 10 services that's fine. With 700 it isn't.

A decision ladder: the first "no" is where to stop
A decision ladder: the first "no" is where to stop

The Decision Table

SituationShapeWhy not federate (yet)Signal to revisit
1–3 backend teams, a handful of first-party clients Single GraphQL service, DataLoader everywhere No coordination problem to solve; the planner and the extra hop are pure cost. Schema PRs routinely wait on another team's review.
Many device teams, stable backend, device teams want autonomy Per-device GraphQL BFFs (Calçado / Giroux) The bottleneck is on the client side, not the entity side. Federation centralizes the schema that device teams want to own. The same entity-fetching code is copied into every BFF and drifts.
Many domain teams, one API team gating changes Federate, starting with the legacy API as a subgraph (see The migration playbook) This is the case federation was built for. n/a. Plan for the platform team and the governance cost.
Consumer app with heavy device policy Federated entities + thin screen/BFF layer (see Where the BFF's jobs go) Row counts, artwork sizes and feature gates belong to neither entity nor planner. The thin layer starts orchestrating fetches again.
Latency-critical path, few calls, fixed shape (e.g. playback start) Direct RPC; keep it off the graph A planner and JSON merge add cost with no flexibility benefit. Several clients start needing different projections of it.
Domain model contested; entities have no clear owner Don't federate; fix ownership @key encodes ownership. Federating a confused model hard-codes the confusion into composition rules. Each core entity has a named owning team.

The playback-start row is reasoning from the mechanism, not a published Netflix design. It follows from the Operating the gateway part's cost model: the gateway's per-request overhead is worth paying where query flexibility is valuable, and a fixed-shape, latency-critical call gets none of that value.

Team-Size Thresholds: Nobody Publishes One

There isn't a credible published number for "federate above N teams", and you should be wary of any article that gives one. Netflix's own guidance is conditional, not numeric. Spalding at QCon: "Are you committed to doing microservices already? If a monolithic architecture is working for your company, then don't let us be the ones to convince you otherwise." And Part 2: "For ecosystems like ours with a large swath of microservices that need to be aggregated together, the development velocity and improved operability has made the transition worth it." The signals worth measuring are how long a schema change waits in the API team's queue, how many teams are in that queue, and what share of incidents trace back to the aggregation tier. Studio federated when "hundreds of engineers" were contributing to the API and the graph had grown from about 800 nodes to almost 7,000 in a year (QCon 2020). At that point the case is strong. With five teams and one TV app, it's hard to make.

The Invariants

  • Guarantees: Federation lets many teams own and ship separate parts of one client-facing schema without touching each other's code, and gives clients a single graph and a single request shape across all of them.
  • Does not guarantee: Lower latency, less fan-out, or better dedupe than a single GraphQL service (a per-request DataLoader in one process sees more than the planner does); that device-specific policy disappears; that the gateway stays free of business logic; or that the organization is big enough for the platform, governance and training costs to pay off. Netflix, the reference case, calls it "not free" and "not the best fit for every team."