List of usage examples for org.apache.hadoop.yarn.ipc YarnRPC create
public static YarnRPC create(Configuration conf)
From source file:org.springframework.yarn.rpc.YarnRpcAccessor.java
License:Apache License
/** * Creates the proxy. If {@link #getUser()} returns * a non null {@link UserGroupInformation user}, that * will be used to request the proxy with * a {@link PrivilegedAction}.//from ww w . ja v a 2 s .c o m * * @return the proxy * @throws IOException */ @SuppressWarnings("unchecked") protected P createProxy() throws IOException { return getUser().doAs(new PrivilegedAction<P>() { @Override public P run() { return (P) YarnRPC.create(configuration).getProxy(protocolClazz, address, configuration); } }); }