----------------------------------------------------------- This is an automatically generated e-mail. To reply, visit: https://reviews.apache.org/r/69707/#review211992 -----------------------------------------------------------
intg/src/main/java/org/apache/atlas/model/instance/ClassificationAssociateResponse.java Lines 39 (patched) <https://reviews.apache.org/r/69707/#comment297573> ClassificationAssociateResponse ==> AtlasEntityHeaders repository/src/main/java/org/apache/atlas/repository/store/graph/v2/ClassificationAssociator.java Lines 132 (patched) <https://reviews.apache.org/r/69707/#comment297590> classifications that are already associated with the entity, but not in the incoming entity should be deleted as well i.e. not just when the incoming entity has empty classification list. webapp/src/main/java/org/apache/atlas/web/rest/EntityREST.java Lines 95 (patched) <https://reviews.apache.org/r/69707/#comment297592> ClassificationAssociator is needed only in getEntityHeaders() method. Consider instantiating one in this method, instead of injecting here. webapp/src/main/java/org/apache/atlas/web/rest/EntityREST.java Line 264 (original), 277 (patched) <https://reviews.apache.org/r/69707/#comment297589> perhaps this comment was updated during code-refactoring? webapp/src/main/java/org/apache/atlas/web/rest/EntityREST.java Lines 759 (patched) <https://reviews.apache.org/r/69707/#comment297591> Consider adding AtlasEntityStore.setClassifications() method (similar to add/update/delete classification methods) and call it directly from here, instead of going through classificationAssociator. - Madhan Neethiraj On Jan. 15, 2019, 1:26 a.m., Ashutosh Mestry wrote: > > ----------------------------------------------------------- > This is an automatically generated e-mail. To reply, visit: > https://reviews.apache.org/r/69707/ > ----------------------------------------------------------- > > (Updated Jan. 15, 2019, 1:26 a.m.) > > > Review request for atlas, Madhan Neethiraj, Nikhil Bonte, Nixon Rodrigues, > and Sarath Subramanian. > > > Bugs: ATLAS-3029 > https://issues.apache.org/jira/browse/ATLAS-3029 > > > Repository: atlas > > > Description > ------- > > **Approach** > - Scan HBase 'ATLAS_ENTITY_AUDIT_EVENTS' table with approprite paramters. > - Package the output into _AtlasEntityHeader_. > - Provide _REST APIs_ to _EntityREST_. > > **CURL** > > _Fetch_ > curl -X GET -u admin:passWord -H 'Content-Type: application/json' > > 'http://localhost:21000/api/atlas/v2/entity/audit/classifications?timeRange=1546992000000:1547157600000' > \ > > _Udpate_ > curl -X POST -u admin:passWord -H 'Content-Type: application/json' > 'http://localhost:21000/api/atlas/v2/entity/audit/classifications' > -d @fetched-classifications.json > > > **Not supported** > - Cassandra based Audits. > - For testing: In-memory audits. > > > Diffs > ----- > > client/client-v2/src/main/java/org/apache/atlas/AtlasClientV2.java > 7c8caee89 > > intg/src/main/java/org/apache/atlas/model/instance/ClassificationAssociateResponse.java > PRE-CREATION > > repository/src/main/java/org/apache/atlas/repository/audit/EntityAuditRepository.java > aab2d5b6c > > repository/src/main/java/org/apache/atlas/repository/audit/HBaseBasedAuditRepository.java > 6f4415fa8 > > repository/src/main/java/org/apache/atlas/repository/audit/InMemoryEntityAuditRepository.java > dca3b853e > > repository/src/main/java/org/apache/atlas/repository/audit/NoopEntityAuditRepository.java > e3a607809 > > repository/src/main/java/org/apache/atlas/repository/store/graph/v2/ClassificationAssociator.java > PRE-CREATION > > repository/src/test/java/org/apache/atlas/repository/store/graph/v2/ClassificationAssociatorTest.java > PRE-CREATION > repository/src/test/resources/json/entity-headers.json PRE-CREATION > webapp/src/main/java/org/apache/atlas/web/rest/EntityREST.java 68c132c37 > > > Diff: https://reviews.apache.org/r/69707/diff/3/ > > > Testing > ------- > > **Unit tests** > New tests added. > > **Functional tests** > Via CURL calls. > > **Volume tests** > Loads of over 2000 entities. > > > File Attachments > ---------------- > > entity-headers.json > > https://reviews.apache.org/media/uploaded/files/2019/01/14/a23bead7-6990-4d5b-b3b8-f46f990f5d99__entity-headers.json > > > Thanks, > > Ashutosh Mestry > >