// Note: erasure makes this safe in combination with the typecheck below
InstanceIdentifier<Node> path = (InstanceIdentifier<Node>) ref.getValue();
- FluentFuture<Optional<Node>> nf = transaction.read(
- LogicalDatastoreType.OPERATIONAL, path);
+ FluentFuture<Optional<Node>> nf = transaction.read(LogicalDatastoreType.OPERATIONAL, path);
transaction.close();
Optional<Node> optional = nf.get();
if (optional != null && optional.isPresent()) {
}
} catch (InterruptedException | ExecutionException e) {
LOG.warn("Read Operational/DS for Node failed! {}", connectionIid, e);
- throw new RuntimeException(e);
+ throw new IllegalStateException(e);
}
return node;
}
}
} catch (InterruptedException | ExecutionException e) {
LOG.warn("Read Operational/DS for Node failed! {}", connectionIid, e);
- throw new RuntimeException(e);
+ throw new IllegalStateException(e);
}
return node;
}