I am configuring gRPC according to the
answer, which says: "Using gRPC with GAE Java 8 doesn't need anything special.".
A gRPC server is started and deployed on a GAE Standard environment for Java 8:
-----------------------------------------------------------------------------------------------------------------------------------------
MyGrpcService service = ...
NettyServerBuilder.forPort(50051).addService(service).build();
-----------------------------------------------------------------------------------------------------------------------------------------
A client uses a service with the ManagedChannel:
-----------------------------------------------------------------------------------------------------------------------------------------
.usePlaintext(true)
.build();
MyGrpcService.newBlockingStub(channel);
-----------------------------------------------------------------------------------------------------------------------------------------
What am I doing wrong? The call to the service has the following result:
-----------------------------------------------------------------------------------------------------------------------------------------
Exception in thread "main" io.grpc.StatusRuntimeException: UNAVAILABLE
at io.grpc.stub.ClientCalls.toStatusRuntimeException(ClientCalls.java:210)
at io.grpc.stub.ClientCalls.getUnchecked(ClientCalls.java:191)
at io.grpc.stub.ClientCalls.blockingUnaryCall(ClientCalls.java:124)
at io.spine.client.grpc.QueryServiceGrpc$QueryServiceBlockingStub.read(QueryServiceGrpc.java:159)
at io.spine.examples.todolist.client.CommandLineTodoClient.getMyListView(CommandLineTodoClient.java:189)
at io.spine.examples.todolist.view.MyTasksListView.render(MyTasksListView.java:68)
at io.spine.cli.AbstractScreen.renderView(AbstractScreen.java:63)
at io.spine.cli.action.TransitionAction.execute(TransitionAction.java:51)
at io.spine.cli.view.AbstractView.executeAction(AbstractView.java:108)
at io.spine.cli.view.AbstractView.render(AbstractView.java:92)
at io.spine.cli.AbstractScreen.renderView(AbstractScreen.java:63)
at io.spine.cli.action.TransitionAction.execute(TransitionAction.java:51)
at io.spine.cli.view.AbstractView.executeAction(AbstractView.java:108)
at io.spine.cli.view.AbstractView.render(AbstractView.java:92)
at io.spine.cli.AbstractScreen.renderView(AbstractScreen.java:63)
at io.spine.examples.todolist.ClientApplication.run(ClientApplication.java:52)
at io.spine.examples.todolist.GaeClient.main(GaeClient.java:39)
at sun.nio.ch.SocketChannelImpl.checkConnect(Native Method)
at sun.nio.ch.SocketChannelImpl.finishConnect(SocketChannelImpl.java:717)
at io.netty.channel.socket.nio.NioSocketChannel.doFinishConnect(NioSocketChannel.java:352)
at io.netty.channel.nio.AbstractNioChannel$AbstractNioUnsafe.finishConnect(AbstractNioChannel.java:340)
at io.netty.channel.nio.NioEventLoop.processSelectedKey(NioEventLoop.java:633)
at io.netty.channel.nio.NioEventLoop.processSelectedKeysOptimized(NioEventLoop.java:580)
at io.netty.channel.nio.NioEventLoop.processSelectedKeys(NioEventLoop.java:497)
at io.netty.channel.nio.NioEventLoop.run(NioEventLoop.java:459)
at io.netty.util.concurrent.SingleThreadEventExecutor$5.run(SingleThreadEventExecutor.java:858)
at io.netty.util.concurrent.DefaultThreadFactory$DefaultRunnableDecorator.run(DefaultThreadFactory.java:138)
at java.lang.Thread.run(Thread.java:745)
Caused by: java.net.ConnectException: Connection timed out: no further information
... 11 more
-----------------------------------------------------------------------------------------------------------------------------------------