Does GRPC Middleware library support grpc-node? I'm interested in logging grpc proto requests, and it seems like I might have to learn golang in order to have a logging feature?
Definitely you don't need to learn Golang for that. You just need to check how to use gRPC interceptors with node. In the interceptor code you will implement any of those features available in the gRPC middleware for Golang.
It would be something like that
const interceptors = require('grpc-interceptors');
const server = interceptors.serverProxy(new grpc.Server());
server.addService(proto.MyPackage.MyService.service, { Method1, Method2 });
const myMiddlewareFunc = function (ctx, next) {
// do stuff before call
console.log('Making gRPC call...');
await next()
// do stuff after call
console.log(ctx.status.code);
}
server.use(myMiddlewareFunc);