multiple async clients in callback in cpp

48 views
Skip to first unread message

karthik karra

unread,
May 3, 2023, 8:17:47 PM5/3/23
to grpc.io
I have been trying to get the multiple async client (2 clients) in callback to make it work but server receives only 1 message each from the client and the clients will keep on sending messages.

if one any was successful, can you please post an example or if there is an open bug please point to it

thanks,
karthik

karthik karra

unread,
May 5, 2023, 1:22:38 PM5/5/23
to grpc.io
hi all, below is code which i am trying to make it work. after untar copy the files under route_guide folder of examples/cpp in grpc repo.

it has cmake file and it will generate client and server binaries
To run
1st terimal - ./server
2nd terminal - ./client <client_id> <num of streams> eg: ./client 1 1 or ./client 1 2

with one client and 1 stream it works good but with one client 2 streams or 2 clients 1 stream each it sends and receives one message thats it. nothing happens after that.

please provide some pointers on this.

the reason for structuring the code this way is my main project also has similar design and apologies for throwing bunch of files.

thanks for any help
karthik

karthik karra

unread,
May 5, 2023, 1:25:27 PM5/5/23
to grpc.io
sorry one correction is, when i mean nothing happens it means client keeps on sending messages but server doesn't receive it and as a result there will be no reply to client
Reply all
Reply to author
Forward
0 new messages