Questions tagged [grpc-node]

grpc-node is a high-performance, open-source universal RPC framework for Node.js platform.

gRPC is an open source remote procedure call (RPC) system initially developed at Google. It uses HTTP/2 for transport, Protocol Buffers as the interface description language, and provides features such as authentication, bidirectional streaming and flow control, blocking or nonblocking bindings, and cancellation and timeouts.

grpc-node repository

gRPC Node Quick Start

222 questions
11
votes
3 answers

Unable to install grpc-tools via npm or yarn on mac m1 chip?

Commands Used to install: npm install -g grpc-tools yarn add global grpc-tools While trying to install grpc-tools on mac m1 BigSur. I ran into errors pasted below: npm ERR! code 1 npm ERR! path…
Abdulmoiz Ahmer
  • 1,953
  • 17
  • 39
10
votes
2 answers

Firestore / gRPC behind a corporate firewall / proxy

Our company has built an electron application using Firestore and now we are trying to deploy the application behind a corporate proxy and firewall (customer environment). After setting the proxy authentication settings using electrons…
jmeinke
  • 530
  • 6
  • 27
9
votes
1 answer

Why is gRPC so much slower than an HTTP API sending an array

I'm doing load tests between services implemented in Node.JS, both services on the same machine connected through localhost. There are REST and gRPC client & server files. The main goal is to prove that gRPC is faster than an HTTP call because the…
J.F.
  • 13,927
  • 9
  • 27
  • 65
7
votes
1 answer

How to distinguish not provided and empty array in grpc service?

See https://github.com/grpc/grpc-node/issues/1202. Usually in CRUD operations, the value not provided means do not change that field, and the empty array [] means to clear all items inside that field. But if you tries to implement CRUD operations…
Jeff Tian
  • 5,210
  • 3
  • 51
  • 71
7
votes
2 answers

Cannot import google's proto with @grpc/proto-loader

I have the following proto: syntax = "proto3"; import "google/rpc/status.proto"; message Response { google.rpc.Status status = 1; } message Request { Type name = 1; } service Service { rpc SomeMethod (Request) returns…
Olga
  • 309
  • 4
  • 16
6
votes
0 answers

How to convert object to protobuf data in nodejs

If I have a proto3 message defined as below message Log { string object = 1; string key_result = 2; string review = 3; repeated string tag = 4; string begin_at = 5; string end_at = 6; string created_at = 7; string id = 8; } the…
H.C.Liu
  • 156
  • 1
  • 4
6
votes
3 answers

Run protoc command into docker container

I'm trying to run protoc command into a docker container. I've tried using the gRPC image but protoc command is not found: /bin/sh: 1: protoc: not found So I assume I have to install manually using RUN instructions, but is there a better solution?…
J.F.
  • 13,927
  • 9
  • 27
  • 65
6
votes
2 answers

Why grpc-go can run grpc server and http server at the same address and port, but grpc-node cannot

I had read this answer: https://stackoverflow.com/a/56943771/6463558, it says that there is no way to run gRPC server and HTTP server at same address and port using grpc-node package. But I can create gRPC server and HTTP server at same address and…
Lin Du
  • 88,126
  • 95
  • 281
  • 483
6
votes
1 answer

How can two internal Cloud Run node.js microservices successfully communicate via gRPC?

New to Google Cloud Run and trying to have two node.js microservices communicate internally via gRPC. The client interface: constructor(address: string, credentials: grpc.ChannelCredentials, options?: object); The client code: const client:…
5
votes
0 answers

Sveltekit - 500 process is not defined or exports is not defined

I'm trying to call a GRPC service (a dGraph api) from a Sveltekit (SvelteKit v1.0.0-next.114) application. I am using a writable store from svelte/store, and am able to log to the console the response from calling the GRPC service. However, we I…
Magick
  • 4,603
  • 22
  • 66
  • 103
5
votes
1 answer

GRPC client Error: 14 UNAVAILABLE: failed to connect to all addresses

Im trying to test my grpc client connection using below code. I have .net core grpc server and using node js grpc client to connect. But getting "failed to connect to all addresses" error. BUt able to connect .net grpc server to .net grpc client.…
harish511
  • 187
  • 2
  • 2
  • 6
5
votes
1 answer

grpc Trying to connect an http1.x server

I have Node.js grpc server and Node.js grpc client. My grpc server is insecure server, and I already tested my grpc server using my client in local. But I deployed to kube using nginx ingress controller and network load balancer then I got error. { …
ㄴㅇㅇ
  • 67
  • 2
  • 4
  • 8
5
votes
3 answers

How to add message type as object in ProtoBuf (gRPC) - Proto3 Syntax?

How to send message type as object in ProtoBuf - Proto3 Syntax? I want to transfer object instead of string or number. Example { name: 'One', date: 'date', some: 'some', ... ... } syntax = "proto3"; package db; service Proxy { rpc…
Aravin
  • 6,605
  • 5
  • 42
  • 58
5
votes
2 answers

Can grpc and express server run by same nodejs server, or grpc has to be different server

I am trying to create a REST server which will be based on Node/Express. How to add a GRPC server in the same REST server, or it has to be completely different NodeJS server which will host only the GRPC server.
Asutosh
  • 1,775
  • 2
  • 15
  • 22
4
votes
0 answers

How to run package binary installed with Yarn 2

I'm giving Yarn 2/Berry a shot and I'm having trouble figuring out how to run a binary installed by a package. I'm specifically trying to run GRPC typescript compilation. I have the following command in a bash script which works with Yarn 1: yarn…
Paymahn Moghadasian
  • 9,301
  • 13
  • 56
  • 94
1
2 3
14 15