Kamran Ayub is a technologist, speaker, and Pluralsight author and specializes in building full-stack solutions with a focus on modern web technology and cloud native architecture.
Yeah, this is how we approach it at work (i.e. "an enterprise"). We have something called the "UI facade" which is just a GraphQL layer that talks to our Java REST services that are owned by other teams AND our microservices (session service, auth service, etc.) that we own. Then any client, our UI or another team or another service, can use our GraphQL layer to fetch only what they need without worrying about where it comes from, versioning, auth tokens, etc. It's amazing.
If you are only writing GQL over one REST API and you own both layers, I would just do GQL since its de-facto more flexible and will scale over time super well.
For further actions, you may consider blocking this person and/or reporting abuse
We're a place where coders share, stay up-to-date and grow their careers.
Yeah, this is how we approach it at work (i.e. "an enterprise"). We have something called the "UI facade" which is just a GraphQL layer that talks to our Java REST services that are owned by other teams AND our microservices (session service, auth service, etc.) that we own. Then any client, our UI or another team or another service, can use our GraphQL layer to fetch only what they need without worrying about where it comes from, versioning, auth tokens, etc. It's amazing.
If you are only writing GQL over one REST API and you own both layers, I would just do GQL since its de-facto more flexible and will scale over time super well.