List of usage examples for org.apache.hadoop.ipc RPC waitForProxy
public static <T> T waitForProxy(Class<T> protocol, long clientVersion, InetSocketAddress addr, Configuration conf, long connTimeout) throws IOException
From source file:rpc.TestRPC.java
License:Apache License
@Test public void testStandaloneClient() throws IOException { try {/* ww w. j ava 2s . c o m*/ TestProtocol proxy = RPC.waitForProxy(TestProtocol.class, TestProtocol.versionID, new InetSocketAddress(ADDRESS, 20), conf, 15000L); proxy.echo(""); fail("We should not have reached here"); } catch (ConnectException ioe) { // this is what we expected } }