}
} catch (IOException e) {
throwInternalError(e, uri.toString());
} catch (ResourceManagerException e) {
if (e.getStatus() == ResourceManagerException.ERR_NO_SUCH_RESOURCE) {
throw new RevisionNotFoundException(uri.toString(), revisionDescriptor.getRevisionNumber());
} else {
throwInternalError(e, uri.toString());
}
} finally {
try {