atlas-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From mad...@apache.org
Subject atlas git commit: ATLAS-2076: update type-search to support filter by RELATIONSHIP type
Date Fri, 25 Aug 2017 08:16:43 GMT
Repository: atlas
Updated Branches:
  refs/heads/master b445a1d2b -> a6c0793fe


ATLAS-2076: update type-search to support filter by RELATIONSHIP type

Signed-off-by: Madhan Neethiraj <madhan@apache.org>


Project: http://git-wip-us.apache.org/repos/asf/atlas/repo
Commit: http://git-wip-us.apache.org/repos/asf/atlas/commit/a6c0793f
Tree: http://git-wip-us.apache.org/repos/asf/atlas/tree/a6c0793f
Diff: http://git-wip-us.apache.org/repos/asf/atlas/diff/a6c0793f

Branch: refs/heads/master
Commit: a6c0793feaa6871d69fda24189f35b244e606e0e
Parents: b445a1d
Author: Richard Ding <sding@us.ibm.com>
Authored: Mon Aug 21 13:24:51 2017 -0700
Committer: Madhan Neethiraj <madhan@apache.org>
Committed: Fri Aug 25 00:58:23 2017 -0700

----------------------------------------------------------------------
 .../atlas/repository/store/graph/AtlasTypeDefGraphStore.java      | 3 +++
 .../main/java/org/apache/atlas/repository/util/FilterUtil.java    | 2 ++
 2 files changed, 5 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/atlas/blob/a6c0793f/repository/src/main/java/org/apache/atlas/repository/store/graph/AtlasTypeDefGraphStore.java
----------------------------------------------------------------------
diff --git a/repository/src/main/java/org/apache/atlas/repository/store/graph/AtlasTypeDefGraphStore.java
b/repository/src/main/java/org/apache/atlas/repository/store/graph/AtlasTypeDefGraphStore.java
index 1554baa..f5e1618 100644
--- a/repository/src/main/java/org/apache/atlas/repository/store/graph/AtlasTypeDefGraphStore.java
+++ b/repository/src/main/java/org/apache/atlas/repository/store/graph/AtlasTypeDefGraphStore.java
@@ -668,6 +668,9 @@ public abstract class AtlasTypeDefGraphStore implements AtlasTypeDefStore
{
             case ENTITY:
                 ret = ((AtlasEntityType) type).getEntityDef();
                 break;
+            case RELATIONSHIP:
+                ret = ((AtlasRelationshipType) type).getRelationshipDef();
+                break;
             case PRIMITIVE:
             case OBJECT_ID_TYPE:
             case ARRAY:

http://git-wip-us.apache.org/repos/asf/atlas/blob/a6c0793f/repository/src/main/java/org/apache/atlas/repository/util/FilterUtil.java
----------------------------------------------------------------------
diff --git a/repository/src/main/java/org/apache/atlas/repository/util/FilterUtil.java b/repository/src/main/java/org/apache/atlas/repository/util/FilterUtil.java
index 54d6b40..44d6051 100644
--- a/repository/src/main/java/org/apache/atlas/repository/util/FilterUtil.java
+++ b/repository/src/main/java/org/apache/atlas/repository/util/FilterUtil.java
@@ -115,6 +115,8 @@ public class FilterUtil {
                             return atlasType.getTypeCategory() == TypeCategory.STRUCT;
                         case "ENUM":
                             return atlasType.getTypeCategory() == TypeCategory.ENUM;
+                        case "RELATIONSHIP":
+                            return atlasType.getTypeCategory() == TypeCategory.RELATIONSHIP;
                         default:
                             // This shouldn't have happened
                             return false;


Mime
View raw message