Details
-
Sub-task
-
Status: Resolved
-
Major
-
Resolution: Fixed
-
0.5.0
Description
Currently, the SCM node manager method getNodeStatus catches any NodeNotFoundException and returns null.
/** * Returns the node status of a specific node. * * @param datanodeDetails Datanode Details * @return NodeStatus for the node */ @Override public NodeStatus getNodeStatus(DatanodeDetails datanodeDetails) { try { return nodeStateManager.getNodeStatus(datanodeDetails); } catch (NodeNotFoundException e) { // TODO: should we throw NodeNotFoundException? return null; } }
This should probably throw the exception to ensure downstream code does not need to perform a null check each time it is called.
Attachments
Issue Links
- links to