'Inter-service communication between Apollo Federation subgraphs
Let's say we have S1, S2 subgraphs, and G gateway.
S1 subgraph service needs some data from the S2 service. How should it be handled through the gateway and schema level? Should we use gateway in this kind of communication?
Should we have a separated schema & Apollo server inside every subgraph that contains the internal queries and mutations? Should S1 call directly S2 "internal apollo server"?
By default, all user-facing requests need to be authorized by JWT, but internal communications should work without this.
Subgraphs are not available on the public network, but they're running on the same internal network. Technically they can see each other. They're hosted on GKE.
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|
