Set an idle timeout on registration gRPC client
This commit is contained in:
parent
9f3ffa3707
commit
b594986241
|
@ -69,7 +69,9 @@ public class RegistrationServiceClient implements Managed {
|
|||
.trustManager(certificateInputStream)
|
||||
.build();
|
||||
|
||||
this.channel = Grpc.newChannelBuilderForAddress(host, port, tlsChannelCredentials).build();
|
||||
this.channel = Grpc.newChannelBuilderForAddress(host, port, tlsChannelCredentials)
|
||||
.idleTimeout(1, TimeUnit.MINUTES)
|
||||
.build();
|
||||
}
|
||||
|
||||
this.stub = RegistrationServiceGrpc.newFutureStub(channel)
|
||||
|
|
Loading…
Reference in New Issue