tRPC is a transport layer for Remote Procedure Calls (RPCs) just like used by gRPC. tRPC provides a fast, low overhead, and scalable way to transmit data between services.
Examples of use cases for tRPC are:
Microservice communication
Distributed system communication
Inter-process communication
High-performance data processing
Service-to-service authentication and authorization
Remote database access
Remote machine learning model serving
and many more.
How we would use tRPC with Dgraph?
tRPC can be utilized with Dgraph to create an automated CRUD system, similar to what we already have with GraphQL. tRPC would provide a new API option for users. The tRPC resolver generator would be based on Dgraph's Type System, generating all tRPC queries and mutations. Interoperability between GraphQL and tRPC may be possible in the future, but it may be better to keep tRPC solely for DQL and have GraphQL in its own separate space
Use case
tRPC is a transport layer for Remote Procedure Calls (RPCs) just like used by gRPC. tRPC provides a fast, low overhead, and scalable way to transmit data between services.
Examples of use cases for tRPC are:
How we would use tRPC with Dgraph?
tRPC can be utilized with Dgraph to create an automated CRUD system, similar to what we already have with GraphQL. tRPC would provide a new API option for users. The tRPC resolver generator would be based on Dgraph's Type System, generating all tRPC queries and mutations. Interoperability between GraphQL and tRPC may be possible in the future, but it may be better to keep tRPC solely for DQL and have GraphQL in its own separate space
Links to Discuss, RFC or previous Issues and PRs
No response
Links to examples and research
No response
Current state
No response
Solution proposal
Add tRPC to Dgraph stack.
Additional Information
Once we have a node-based Type System, tRPC would be trivial to implement. See https://discuss.dgraph.io/t/rfc-proposal-for-change-in-type-system/17983