Run a grpc application not working
According to link http://www.grpc.io/docs/quickstart/java.html#run-a-grpc-application , I must follow the below steps to execute a hello world sample client and server.
From the examples directory:
$ ./gradlew installDist
$ ./build/install/examples/bin/hello-world-server
$ ./build/install/examples/bin/hello-world-client
I am using Windows machine , so gradlew installDist command works for me. But after that, there is no build/install/examples/bin folder structure to execute hello-world-server.
There is a hello-world-server in examples\build\tmp folder, but that too gives following error
Error: Could not find or load main class io.grpc.examples.helloworld.HelloWorldServer
Please help
What directory did you run it from?
I am running from examplesdirectory
Are you running from master?
There is no folder called master
What I mean to say is, what version of gRPC are you using?
I am in (v1.0.0) branch
@carl-mastrangelo , any help pls
I am not sure what is wrong. I am on linux, so the commands seem to work on my machine. As a sanity check could you verify the following things:
- Windows uses
\instead of/, could you replace the command with that, and remove the./at the beginning of the command? - Could you run
dirwhile in the the examples directory? - Can you also include the full output of
./gradlew clean installDist?
I found the solution!!!!!!I had to run hello-world-client and hello-world-server from build/install/examples/bin/ folder and not hello-world-client.bat and hello-world-server.bat