diff --git a/repository/src/main/java/org/apache/atlas/repository/store/graph/v2/EntityGraphMapper.java b/repository/src/main/java/org/apache/atlas/repository/store/graph/v2/EntityGraphMapper.java index 5cbefed443..7d018fba51 100644 --- a/repository/src/main/java/org/apache/atlas/repository/store/graph/v2/EntityGraphMapper.java +++ b/repository/src/main/java/org/apache/atlas/repository/store/graph/v2/EntityGraphMapper.java @@ -3630,7 +3630,7 @@ public void deleteClassification(String entityGuid, String classificationName) t // Get in progress task to see if there already is a propagation for this particular vertex List inProgressTasks = taskManagement.getInProgressTasks(); for (AtlasTask task : inProgressTasks) { - if (isTaskMatchingWithVertexIdAndEntityGuid(task, classificationVertex.getIdForDisplay(), entityGuid)) { + if (IN_PROGRESS.equals(task.getStatus()) && isTaskMatchingWithVertexIdAndEntityGuid(task, classificationVertex.getIdForDisplay(), entityGuid)) { throw new AtlasBaseException(AtlasErrorCode.CLASSIFICATION_CURRENTLY_BEING_PROPAGATED, classificationName); } } @@ -3907,7 +3907,7 @@ public void deleteClassifications(String entityGuid, List c } private boolean isTaskMatchingWithVertexIdAndEntityGuid(AtlasTask task, String classificationVertexId, String entityGuid) { try { - if (CLASSIFICATION_PROPAGATION_ADD.equals(task.getType()) && IN_PROGRESS.equals(task.getStatus())) { + if (CLASSIFICATION_PROPAGATION_ADD.equals(task.getType())) { return task.getParameters().get(ClassificationTask.PARAM_CLASSIFICATION_VERTEX_ID).equals(classificationVertexId) && task.getParameters().get(ClassificationTask.PARAM_ENTITY_GUID).equals(entityGuid); }