Skip to content

Nadia-Adaptive/gRPC-auctionhouse

Repository files navigation

Basic GRPC Chat Example

Project Structure

contract - defines contract, this is where .proto file should be added sender - defines a client of the chat service that subscribes to messages and sends some test messages, this is where to add your client code receiver - chat chat that receives and broadcasts chat messages, this is where to add your service code

Building

The gradle protobuf plugin is used to generate the various stubs and services. Once you have added the .proto, to generate the code execute

./gradlew generateProto

Running

To run the chat, define your main class as SenderMain (or update the class name in build.gradle) in the receiver module. This starts a chat on localhost at port 8980.

To run the client, define your main class as SenderMain in the sender module (or update the class name in build.gradle). This conects to the chat on localhost:8980 and sends several chat messages as well as printing the responses.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages