[jira] [Commented] (ATLAS-1978) gas omas : add outbound publishing/kafka

2017-08-07 Thread David Radley (JIRA)

[ 
https://issues.apache.org/jira/browse/ATLAS-1978?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16116556#comment-16116556
 ] 

David Radley commented on ATLAS-1978:
-

[~jonesn] I thought we were now calling this Governance Access OMAS and losing 
the Framework from the acronym. 

> gas omas : add outbound publishing/kafka
> 
>
> Key: ATLAS-1978
> URL: https://issues.apache.org/jira/browse/ATLAS-1978
> Project: Atlas
>  Issue Type: Sub-task
>Reporter: Nigel Jones
>
> GAF omas must publish changes on topics for consumers.
> This subtask will be used to add that support after the initial rest api has 
> been created



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)


Re: Review Request 61247: [ATLAS-1984]: Use AtlasRelatedObjectId to refer to relationship attributes during entity create/update

2017-08-07 Thread David Radley

---
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/61247/#review182278
---




intg/src/main/java/org/apache/atlas/type/AtlasStructType.java
Lines 334 (patched)


Call null be a valid value for a required attribute.

I think there is a differene between not specifying an attribute (i.e.e the 
key is not there ) and specifying it with null as a value.



intg/src/main/java/org/apache/atlas/type/AtlasTypeUtil.java
Lines 319 (patched)


I would have thought that  map.get("relationshipAttributes") would either 
be null or a Map. 

If relationshipAttributes is not a map - we should issue an error.



repository/src/main/java/org/apache/atlas/repository/store/graph/v1/EntityGraphMapper.java
Line 380 (original), 395 (patched)


I am not sure what this is doing - it looks like you are adding 
relationship attribute for legacy relationships and duplicating them in the 
inverse edge. Do we need to support relaitonship attributes for legacy 
relationships? It would be  good incentive fror peopel to move to the non 
legacy relationships.



repository/src/main/java/org/apache/atlas/repository/store/graph/v1/EntityGraphMapper.java
Lines 1437 (patched)


I suggest this be static and junitted.

This method seems to be removing entity attributes when there was a 
relationship attributes. This appears to be part of the legacy support; if so 
shouldn't we be only doing this checking for legacy cases abnd issuing errors 
otherwise.


- David Radley


On July 31, 2017, 3:36 a.m., Sarath Subramanian wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/61247/
> ---
> 
> (Updated July 31, 2017, 3:36 a.m.)
> 
> 
> Review request for atlas, David Radley and Madhan Neethiraj.
> 
> 
> Bugs: ATLAS-1984
> https://issues.apache.org/jira/browse/ATLAS-1984
> 
> 
> Repository: atlas
> 
> 
> Description
> ---
> 
> AtlasObjectId is used to refer to entity attributes referring to another 
> entity.
> hive_table.columns => List
> hive_table.db => AtlasObjectId
> Change this to use AtlasRelatedObjectId with the following structure:
> class AtlasRelatedObjectId
> { String relationshipGuid; String displayText; AtlasStruct 
> relationshipAttributes; }
> 
> 
> Diffs
> -
> 
>   intg/src/main/java/org/apache/atlas/model/instance/AtlasRelationship.java 
> 41883713 
>   intg/src/main/java/org/apache/atlas/model/instance/AtlasStruct.java 
> 80f3a664 
>   intg/src/main/java/org/apache/atlas/type/AtlasStructType.java 277d0fa2 
>   intg/src/main/java/org/apache/atlas/type/AtlasTypeUtil.java 3f395419 
>   
> repository/src/main/java/org/apache/atlas/repository/store/graph/v1/AtlasEntityGraphDiscoveryV1.java
>  0210a118 
>   
> repository/src/main/java/org/apache/atlas/repository/store/graph/v1/EntityGraphMapper.java
>  b8fd70e5 
> 
> 
> Diff: https://reviews.apache.org/r/61247/diff/2/
> 
> 
> Testing
> ---
> 
> Tested using POSTMAN REST client
> 
> mvn clean package - In Progress
> 
> 
> Thanks,
> 
> Sarath Subramanian
> 
>



Re: Review Request 61191: [ATLAS-1999]: Use AtlasRelatedObjectId to display relationshipAttribute values during entity retrieval

2017-08-07 Thread Madhan Neethiraj

---
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/61191/#review181861
---


Fix it, then Ship it!





intg/src/main/java/org/apache/atlas/model/instance/AtlasRelatedObjectId.java
Lines 55 (patched)


Constructors at line #55 and #69 shouldn't be needed. Consider removing 
them.



intg/src/main/java/org/apache/atlas/type/AtlasEntityType.java
Line 269 (original), 270 (patched)


I think it will be intutive to replace:
  return isValidAttributeValue(obj)

with the following:
  return super.isValidValue(obj) && validateRelationshipAttributes(obj)



intg/src/main/java/org/apache/atlas/type/AtlasEntityType.java
Lines 496 (patched)


Consider renaming this method as "validateRelationshipAttributes()"



repository/src/main/java/org/apache/atlas/repository/store/graph/v1/EntityGraphRetriever.java
Lines 718 (patched)


Consider using AtlasRelatedObjectId constructor which takes relationship 
guid and attributes as well.


- Madhan Neethiraj


On July 27, 2017, 7:49 p.m., Sarath Subramanian wrote:
> 
> ---
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/61191/
> ---
> 
> (Updated July 27, 2017, 7:49 p.m.)
> 
> 
> Review request for atlas, David Radley and Madhan Neethiraj.
> 
> 
> Bugs: ATLAS-1999
> https://issues.apache.org/jira/browse/ATLAS-1999
> 
> 
> Repository: atlas
> 
> 
> Description
> ---
> 
> * Currently relationship attributes uses AtlasObjectId format during entity 
> retrieval. Change this to use AtlasRelatedObjectId to contain additional 
> information for use in search and UI
> * validate and normalize relationship attribute values supplied during entity 
> creation
> 
> 
> Diffs
> -
> 
>   
> intg/src/main/java/org/apache/atlas/model/instance/AtlasRelatedObjectId.java 
> PRE-CREATION 
>   intg/src/main/java/org/apache/atlas/type/AtlasEntityType.java f89c5568 
>   repository/src/main/java/org/apache/atlas/repository/graph/GraphHelper.java 
> c47a89e6 
>   
> repository/src/main/java/org/apache/atlas/repository/store/graph/v1/AtlasRelationshipStoreV1.java
>  49e08a07 
>   
> repository/src/main/java/org/apache/atlas/repository/store/graph/v1/EntityGraphRetriever.java
>  31fc8377 
>   
> repository/src/test/java/org/apache/atlas/repository/store/graph/v1/AtlasRelationshipStoreV1Test.java
>  263ad5be 
> 
> 
> Diff: https://reviews.apache.org/r/61191/diff/4/
> 
> 
> Testing
> ---
> 
> * tested using POSTMAN rest client - valid relationship attribute values in 
> AtlasRelatedObjectId format is retrieved
> * mvn clean package - succeeded
> 
> 
> Thanks,
> 
> Sarath Subramanian
> 
>



Re: Review Request 61191: [ATLAS-1999]: Use AtlasRelatedObjectId to display relationshipAttribute values during entity retrieval

2017-08-07 Thread Sarath Subramanian

---
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/61191/
---

(Updated Aug. 7, 2017, 11:15 p.m.)


Review request for atlas, David Radley and Madhan Neethiraj.


Bugs: ATLAS-1999
https://issues.apache.org/jira/browse/ATLAS-1999


Repository: atlas


Description
---

* Currently relationship attributes uses AtlasObjectId format during entity 
retrieval. Change this to use AtlasRelatedObjectId to contain additional 
information for use in search and UI
* validate and normalize relationship attribute values supplied during entity 
creation


Diffs (updated)
-

  intg/src/main/java/org/apache/atlas/model/instance/AtlasRelatedObjectId.java 
PRE-CREATION 
  intg/src/main/java/org/apache/atlas/type/AtlasEntityType.java f89c5568 
  repository/src/main/java/org/apache/atlas/repository/graph/GraphHelper.java 
c47a89e6 
  
repository/src/main/java/org/apache/atlas/repository/store/graph/v1/AtlasRelationshipStoreV1.java
 49e08a07 
  
repository/src/main/java/org/apache/atlas/repository/store/graph/v1/EntityGraphRetriever.java
 31fc8377 
  
repository/src/test/java/org/apache/atlas/repository/store/graph/v1/AtlasRelationshipStoreV1Test.java
 77a591a9 


Diff: https://reviews.apache.org/r/61191/diff/5/

Changes: https://reviews.apache.org/r/61191/diff/4-5/


Testing
---

* tested using POSTMAN rest client - valid relationship attribute values in 
AtlasRelatedObjectId format is retrieved
* mvn clean package - succeeded


Thanks,

Sarath Subramanian