----------------------------------------------------------- This is an automatically generated e-mail. To reply, visit: https://reviews.apache.org/r/68312/#review207159 -----------------------------------------------------------
intg/src/main/java/org/apache/atlas/model/typedef/AtlasStructDef.java Lines 259 (patched) <https://reviews.apache.org/r/68312/#comment290450> "softRef" => "softReference" intg/src/main/java/org/apache/atlas/model/typedef/AtlasStructDef.java Lines 277 (patched) <https://reviews.apache.org/r/68312/#comment290451> include 'options' in hashCode() and equals() methods. intg/src/main/java/org/apache/atlas/model/typedef/AtlasStructDef.java Lines 419 (patched) <https://reviews.apache.org/r/68312/#comment290452> isSoftRefSet() => isSoftReferenced() repository/src/main/java/org/apache/atlas/repository/store/graph/v1/EntityGraphMapper.java Lines 349 (patched) <https://reviews.apache.org/r/68312/#comment290453> ctx.getValue() can also be a Map, check and map the value back to object ID. Could you check if normalized value is mapped back to ObjectID repository/src/main/java/org/apache/atlas/repository/store/graph/v1/EntityGraphMapper.java Lines 353 (patched) <https://reviews.apache.org/r/68312/#comment290454> consider refactoring like below instead of adding a new method. ctx.setValue(softRefValue); mapPrimitiveValue(ctx); repository/src/main/java/org/apache/atlas/repository/store/graph/v1/EntityGraphRetriever.java Lines 532 (patched) <https://reviews.apache.org/r/68312/#comment290455> constructor of AtlasObjectId(guid, typeName) I think the Index name is swapped, it should be SOFT_REFERENCE_FORMAT_INDEX_TYPE_NAME = 0 SOFT_INDEX_REFERENCE_GUID = 1 return new AtlasObjectId( objectIdParts[SOFT_INDEX_REFERENCE_GUID], objectIdParts[SOFT_REFERENCE_FORMAT_INDEX_TYPE_NAME]); - Sarath Subramanian On Aug. 13, 2018, 10:31 a.m., Ashutosh Mestry wrote: > > ----------------------------------------------------------- > This is an automatically generated e-mail. To reply, visit: > https://reviews.apache.org/r/68312/ > ----------------------------------------------------------- > > (Updated Aug. 13, 2018, 10:31 a.m.) > > > Review request for atlas, Apoorv Naik, Madhan Neethiraj, Nixon Rodrigues, and > Sarath Subramanian. > > > Bugs: ATLAS-2813 > https://issues.apache.org/jira/browse/ATLAS-2813 > > > Repository: atlas > > > Description > ------- > > **Approach** > - Add _options_ field to _AtlasAttributeDef_. > - Implement support in _AtlasStructDefStore_. > - Update _EntityGraphMapper_ > - Update _EntityGraphRetriever_ > - Supports array of objects and objects. > > **Usage** > See attached JSON. > > > Diffs > ----- > > intg/src/main/java/org/apache/atlas/model/typedef/AtlasStructDef.java > c3c85d354f02f6ffb9565a5fc15699c4d06e1ae2 > > repository/src/main/java/org/apache/atlas/repository/store/graph/v1/AtlasStructDefStoreV1.java > 137fb30746730cc4d1842891987c342a1bc17af7 > > repository/src/main/java/org/apache/atlas/repository/store/graph/v1/EntityGraphMapper.java > 9e7a119a3abfb50401f9747dad1ffa55facc51ed > > repository/src/main/java/org/apache/atlas/repository/store/graph/v1/EntityGraphRetriever.java > a243fd79cab685174f3a90c5093e84e9f9fa782a > > repository/src/test/java/org/apache/atlas/repository/store/graph/v1/SoftReferenceTest.java > PRE-CREATION > repository/src/test/resources/json/rdbms-db.json PRE-CREATION > repository/src/test/resources/json/typesDef-soft-ref.json PRE-CREATION > > > Diff: https://reviews.apache.org/r/68312/diff/2/ > > > Testing > ------- > > **Unit tests** > Tests verify object, array<object>, map<string,object> cases. > > > File Attachments > ---------------- > > rdbms-db.json > > https://reviews.apache.org/media/uploaded/files/2018/08/13/ded0e80a-bc59-4dc4-ba74-d971c7af8aef__rdbms-db.json > typesDef-soft-ref.json > > https://reviews.apache.org/media/uploaded/files/2018/08/13/e7c79e63-d08b-41ff-97ef-85389a6d63e3__typesDef-soft-ref.json > > > Thanks, > > Ashutosh Mestry > >
