Closed jonathan-casarrubias closed 7 years ago
If we want to support microservices oriented architecture... This might be a good implementation
@gRPCService({ host: ‘’, port: 9000, proto: '' })
class MyController {
@rpc()
sayHello(HelloRequest): HelloResponse {}
}
Discussed and Landed on PR #8
/**
* Setup gRPC MicroService
**/
class Greeter implements GreeterInterface {
@grpc()
SayHello(request: HelloRequest): HelloReply {
return {message: `hello ${request.name}`};
}
}
https://github.com/strongloop/loopback-next/issues/582
As developer, I want be able to use TypeScript decorators as an option to add proto services.
In order to follow a naming convention from the official gRPC module, I propose to use addProtoService name for this decorator, so it is easier for people coming to LB4 and that already knows gRPC to ramp up