看到网上说 graphql 比 rest 好很多
并且都说,要火, 国内外很多大公司在用
可是我却没有找到证据
graphql 真的好用?
查询的性能那么大, 而且 要控制字段的权限,比 rest 更加复杂啊
求指教
1
method Sep 24, 2019 不要用。老老实实做好前后端解耦和接口规范、文档建设。用 graphql 有时候就是为了晋升。
|
2
coocier Sep 24, 2019 |
3
jhdxr Sep 24, 2019 GraphQL is used in production by hundreds of organizations of all sizes including Facebook, Credit Karma, GitHub, Intuit, PayPal, the New York Times and many more.
摘自 https://foundation.graphql.org/ p.s. 立场中立声明:以上回复不代表我个人喜欢 /讨厌 /支持 /反对 GraphQL |
5
doublleft Sep 24, 2019 说句心里话,GraphQL 真的很好用,但是真的想用的话还是上 GRPC
|
6
find456789 OP @doublleft
业务主要是 web、app, grpc 好像是客户端的哦,能用在 web 上吗 |
7
doublleft Sep 24, 2019 @find456789 #6 能,但是残,纯 web 业务没必要,微服务之间可以上,通过网关转 http
|
8
StarkWhite Sep 25, 2019
确实已经火了,不说国外,国内也有阿里等大厂在用
https://www.v2ex.com/t/589138?p=1 |
9
StarkWhite Sep 25, 2019
性能问题用 dataloader,字段权限可以 resolver 里判断,方法总比问题多嘛
|