List of usage examples for org.apache.hadoop.ipc ProtobufHelper getRemoteException
public static IOException getRemoteException(ServiceException se)
From source file:com.intel.hadoopRPCBenchmark.protocol.BenchmarkEngineProtocolClientSideTranslatorPB.java
License:Apache License
public void ping(byte[] payload) throws IOException { PingRequestProto.Builder builder = PingRequestProto.newBuilder().setPayload(ByteString.copyFrom(payload)); try {/*from www . ja va 2s.c o m*/ rpcProxy.ping(NULL_CONTROLLER, builder.build()); } catch (ServiceException se) { throw ProtobufHelper.getRemoteException(se); } }
From source file:org.apache.hoya.yarn.appmaster.rpc.HoyaClusterProtocolProxy.java
License:Apache License
private IOException convert(ServiceException se) { return ProtobufHelper.getRemoteException(se); }
From source file:org.apache.slider.server.appmaster.rpc.SliderClusterProtocolProxy.java
License:Apache License
private IOException convert(ServiceException se) { IOException ioe = ProtobufHelper.getRemoteException(se); if (ioe instanceof RemoteException) { RemoteException remoteException = (RemoteException) ioe; return new RemoteException(remoteException.getClassName(), address.toString() + ": " + remoteException.getMessage()); }//from w w w .j av a 2 s . c o m return ioe; }