----------------------------------------------------------- This is an automatically generated e-mail. To reply, visit: https://reviews.apache.org/r/71870/#review218928 -----------------------------------------------------------
Fix it, then Ship it! repository/src/main/java/org/apache/atlas/repository/store/graph/v2/EntityGraphMapper.java Lines 1866 (patched) <https://reviews.apache.org/r/71870/#comment306865> Consider throwing following exception here, instead of 'return': throw new AtlasBaseException(AtlasErrorCode.CLASSIFICATION_NOT_FOUND_FOR_ENTITY, classificationName, entityGuid); - Madhan Neethiraj On Dec. 4, 2019, 7:32 a.m., Sarath Subramanian wrote: > > ----------------------------------------------------------- > This is an automatically generated e-mail. To reply, visit: > https://reviews.apache.org/r/71870/ > ----------------------------------------------------------- > > (Updated Dec. 4, 2019, 7:32 a.m.) > > > Review request for atlas, Ashutosh Mestry, Aadarsh Jajodia, Sridhar K, Le Ma, > Madhan Neethiraj, Mandar Ambawane, Nikhil Bonte, Nixon Rodrigues, Sameer > Shaikh, and Sidharth Mishra. > > > Bugs: ATLAS-3545 > https://issues.apache.org/jira/browse/ATLAS-3545 > > > Repository: atlas > > > Description > ------- > > Corrupt/Null classification vertices is causing NPE during entity search and > retrieval. Null checks have been added to avoid NPE and logging added to > identify potential corrupt classification vertex. > > > Diffs > ----- > > > repository/src/main/java/org/apache/atlas/repository/store/graph/v2/EntityGraphMapper.java > a114d252e > > repository/src/main/java/org/apache/atlas/repository/store/graph/v2/EntityGraphRetriever.java > 6b111732a > > > Diff: https://reviews.apache.org/r/71870/diff/1/ > > > Testing > ------- > > Precommit: > https://builds.apache.org/view/A/view/Atlas/job/PreCommit-ATLAS-Build-Test/1575/ > > Manually verified that null/corrupt classification vertices are ignored > during search and entity retrieval. > > Approproate WARN messages are printed in the log file: > > *2019-12-03 23:26:45,243 WARN - [pool-2-thread-10 - > 305383de-19f2-4f93-89db-3b54db870c3f:] ~ Ignoring invalid classification > vertex: vertex[id=81932528] (EntityGraphRetriever:284)* > > > Thanks, > > Sarath Subramanian > >