Repository: atlas Updated Branches: refs/heads/master 63a0be262 -> 4dc6284eb
ATLAS-2703: entity delete should not remove its term associations Change-Id: I23b53086b2bb2380f451e7d85b59096edc610181 Signed-off-by: Madhan Neethiraj <mad...@apache.org> Project: http://git-wip-us.apache.org/repos/asf/atlas/repo Commit: http://git-wip-us.apache.org/repos/asf/atlas/commit/4dc6284e Tree: http://git-wip-us.apache.org/repos/asf/atlas/tree/4dc6284e Diff: http://git-wip-us.apache.org/repos/asf/atlas/diff/4dc6284e Branch: refs/heads/master Commit: 4dc6284eb63eb68e3985d1d34542a5ff9818c38b Parents: 63a0be2 Author: apoorvnaik <apoorvn...@apache.org> Authored: Fri May 18 13:57:13 2018 -0700 Committer: Madhan Neethiraj <mad...@apache.org> Committed: Fri May 18 15:20:53 2018 -0700 ---------------------------------------------------------------------- .../apache/atlas/repository/store/graph/v1/DeleteHandlerV1.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/atlas/blob/4dc6284e/repository/src/main/java/org/apache/atlas/repository/store/graph/v1/DeleteHandlerV1.java ---------------------------------------------------------------------- diff --git a/repository/src/main/java/org/apache/atlas/repository/store/graph/v1/DeleteHandlerV1.java b/repository/src/main/java/org/apache/atlas/repository/store/graph/v1/DeleteHandlerV1.java index acb8431..f417b4e 100644 --- a/repository/src/main/java/org/apache/atlas/repository/store/graph/v1/DeleteHandlerV1.java +++ b/repository/src/main/java/org/apache/atlas/repository/store/graph/v1/DeleteHandlerV1.java @@ -161,7 +161,7 @@ public abstract class DeleteHandlerV1 { */ public void deleteRelationships(Collection<AtlasEdge> edges) throws AtlasBaseException { for (AtlasEdge edge : edges) { - boolean isInternal = isInternalType(edge.getInVertex()) || isInternalType(edge.getOutVertex()); + boolean isInternal = isInternalType(edge.getInVertex()) && isInternalType(edge.getOutVertex()); if (!isInternal && getState(edge) == DELETED) { if (LOG.isDebugEnabled()) { @@ -851,7 +851,7 @@ public abstract class DeleteHandlerV1 { } if (edge != null) { - deleteEdge(edge, isInternalType(inVertex) || isInternalType(outVertex)); + deleteEdge(edge, isInternalType(inVertex) && isInternalType(outVertex)); RequestContextV1 requestContext = RequestContextV1.get();