public static void terminateRpcService(RpcService rpcService, Time timeout) throws InterruptedException, ExecutionException, TimeoutException {
		rpcService.stopService().get(timeout.toMilliseconds(), TimeUnit.MILLISECONDS);
	}
public static void terminateRpcService ( RpcService rpcService , Time timeout ) throws InterruptedException , ExecutionException , TimeoutException { rpcService . stopService ( ) . get ( timeout . toMilliseconds ( ) , TimeUnit . MILLISECONDS ) ; }
Shuts the given rpc service down and waits for its termination.

@param rpcService to shut down
@param timeout for this operation
@throws InterruptedException if the operation has been interrupted
@throws ExecutionException if a problem occurred
@throws TimeoutException if a timeout occurred