diff --git hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/RMAdminProtocol.java hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/RMAdminProtocol.java index 46a8d1b..9a2d04c 100644 --- hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/RMAdminProtocol.java +++ hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/api/RMAdminProtocol.java @@ -18,6 +18,8 @@ package org.apache.hadoop.yarn.api; +import java.io.IOException; + import org.apache.hadoop.tools.GetUserMappingsProtocol; import org.apache.hadoop.yarn.exceptions.YarnRemoteException; import org.apache.hadoop.yarn.api.protocolrecords.RefreshAdminAclsRequest; @@ -35,25 +37,25 @@ public interface RMAdminProtocol extends GetUserMappingsProtocol { public RefreshQueuesResponse refreshQueues(RefreshQueuesRequest request) - throws YarnRemoteException; + throws YarnRemoteException, IOException; public RefreshNodesResponse refreshNodes(RefreshNodesRequest request) - throws YarnRemoteException; + throws YarnRemoteException, IOException; public RefreshSuperUserGroupsConfigurationResponse refreshSuperUserGroupsConfiguration( RefreshSuperUserGroupsConfigurationRequest request) - throws YarnRemoteException; + throws YarnRemoteException, IOException; public RefreshUserToGroupsMappingsResponse refreshUserToGroupsMappings( RefreshUserToGroupsMappingsRequest request) - throws YarnRemoteException; + throws YarnRemoteException, IOException; public RefreshAdminAclsResponse refreshAdminAcls( RefreshAdminAclsRequest request) - throws YarnRemoteException; + throws YarnRemoteException, IOException; public RefreshServiceAclsResponse refreshServiceAcls( RefreshServiceAclsRequest request) - throws YarnRemoteException; + throws YarnRemoteException, IOException; } diff --git hadoop-yarn-project/hadoop-yarn/hadoop-yarn-common/src/main/java/org/apache/hadoop/yarn/api/impl/pb/service/RMAdminProtocolPBServiceImpl.java hadoop-yarn-project/hadoop-yarn/hadoop-yarn-common/src/main/java/org/apache/hadoop/yarn/api/impl/pb/service/RMAdminProtocolPBServiceImpl.java index 2124e8d..385d909 100644 --- hadoop-yarn-project/hadoop-yarn/hadoop-yarn-common/src/main/java/org/apache/hadoop/yarn/api/impl/pb/service/RMAdminProtocolPBServiceImpl.java +++ hadoop-yarn-project/hadoop-yarn/hadoop-yarn-common/src/main/java/org/apache/hadoop/yarn/api/impl/pb/service/RMAdminProtocolPBServiceImpl.java @@ -63,6 +63,8 @@ public RefreshQueuesResponseProto refreshQueues(RpcController controller, return ((RefreshQueuesResponsePBImpl)response).getProto(); } catch (YarnRemoteException e) { throw new ServiceException(e); + } catch (IOException e) { + throw new ServiceException(e); } } @@ -77,6 +79,8 @@ public RefreshAdminAclsResponseProto refreshAdminAcls( return ((RefreshAdminAclsResponsePBImpl)response).getProto(); } catch (YarnRemoteException e) { throw new ServiceException(e); + } catch (IOException e) { + throw new ServiceException(e); } } @@ -89,6 +93,8 @@ public RefreshNodesResponseProto refreshNodes(RpcController controller, return ((RefreshNodesResponsePBImpl)response).getProto(); } catch (YarnRemoteException e) { throw new ServiceException(e); + } catch (IOException e) { + throw new ServiceException(e); } } @@ -106,6 +112,8 @@ public RefreshNodesResponseProto refreshNodes(RpcController controller, return ((RefreshSuperUserGroupsConfigurationResponsePBImpl)response).getProto(); } catch (YarnRemoteException e) { throw new ServiceException(e); + } catch (IOException e) { + throw new ServiceException(e); } } @@ -121,6 +129,8 @@ public RefreshUserToGroupsMappingsResponseProto refreshUserToGroupsMappings( return ((RefreshUserToGroupsMappingsResponsePBImpl)response).getProto(); } catch (YarnRemoteException e) { throw new ServiceException(e); + } catch (IOException e) { + throw new ServiceException(e); } } @@ -136,6 +146,8 @@ public RefreshServiceAclsResponseProto refreshServiceAcls( return ((RefreshServiceAclsResponsePBImpl)response).getProto(); } catch (YarnRemoteException e) { throw new ServiceException(e); + } catch (IOException e) { + throw new ServiceException(e); } }