Commit 4dc6284e by apoorvnaik Committed by Madhan Neethiraj

ATLAS-2703: entity delete should not remove its term associations

Change-Id: I23b53086b2bb2380f451e7d85b59096edc610181 Signed-off-by: 's avatarMadhan Neethiraj <madhan@apache.org>
parent 63a0be26
...@@ -161,7 +161,7 @@ public abstract class DeleteHandlerV1 { ...@@ -161,7 +161,7 @@ public abstract class DeleteHandlerV1 {
*/ */
public void deleteRelationships(Collection<AtlasEdge> edges) throws AtlasBaseException { public void deleteRelationships(Collection<AtlasEdge> edges) throws AtlasBaseException {
for (AtlasEdge edge : edges) { 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 (!isInternal && getState(edge) == DELETED) {
if (LOG.isDebugEnabled()) { if (LOG.isDebugEnabled()) {
...@@ -851,7 +851,7 @@ public abstract class DeleteHandlerV1 { ...@@ -851,7 +851,7 @@ public abstract class DeleteHandlerV1 {
} }
if (edge != null) { if (edge != null) {
deleteEdge(edge, isInternalType(inVertex) || isInternalType(outVertex)); deleteEdge(edge, isInternalType(inVertex) && isInternalType(outVertex));
RequestContextV1 requestContext = RequestContextV1.get(); RequestContextV1 requestContext = RequestContextV1.get();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment