* that needs to be present in the offline node when FS tries to
* change the state from OFFLINE to other states.
*/
public EntityGroupOpeningState sendEntityGroupOpen(final ServerName server,
EntityGroupInfo entityGroup, int versionOfOfflineNode) throws IOException {
AdminProtocol admin = getServerConnection(server);
if (admin == null) {
LOG.warn("Attempting to send OPEN RPC to server " + server.toString()
+ " failed because no RPC connection found to this server");
return EntityGroupOpeningState.FAILED_OPENING;
}
OpenEntityGroupRequest request = RequestConverter
.buildOpenEntityGroupRequest(entityGroup, versionOfOfflineNode);
try {
OpenEntityGroupResponse response = admin.openEntityGroup(null, request);
return ResponseConverter.getEntityGroupOpeningState(response);
} catch (ServiceException se) {
throw ProtobufUtil.getRemoteException(se);
}
}