Skip to content

Commit

Permalink
Merge branch 'master' into beta-sync-helper
Browse files Browse the repository at this point in the history
  • Loading branch information
nikhilbonte21 committed Dec 19, 2023
2 parents c2fdf44 + ba89dfb commit 0138517
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 8 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -290,12 +290,14 @@ private void deleteClassifications(String entityGuid, String typeName, List<Atla
if (CollectionUtils.isEmpty(list)) {
return;
}
String classificationNames = getClassificationNames(list);
try {
entitiesStore.deleteClassifications(entityGuid, list);
} catch (AtlasBaseException e) {
LOG.error("Failed to remove classification association between {}, entity with guid {}", classificationNames, entityGuid);
throw e;

for (AtlasClassification c : list) {
try {
entitiesStore.deleteClassification(entityGuid, c.getTypeName());
} catch (AtlasBaseException e) {
LOG.error("Failed to remove classification association between {}, entity with guid {}", c.getTypeName(), c.getEntityGuid());
throw e;
}
}
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -201,7 +201,6 @@ public class EntityGraphMapper {
private final IAtlasEntityChangeNotifier entityChangeNotifier;
private final AtlasInstanceConverter instanceConverter;
private final EntityGraphRetriever entityRetriever;
private final EntityGraphRetriever entityRetrieverNoRelation;
private final IFullTextMapper fullTextMapperV2;
private final TaskManagement taskManagement;
private final TransactionInterceptHelper transactionInterceptHelper;
Expand All @@ -220,7 +219,6 @@ public EntityGraphMapper(DeleteHandlerDelegate deleteDelegate, RestoreHandlerV1
this.entityChangeNotifier = entityChangeNotifier;
this.instanceConverter = instanceConverter;
this.entityRetriever = new EntityGraphRetriever(graph, typeRegistry);
this.entityRetrieverNoRelation = new EntityGraphRetriever(graph, typeRegistry, true);
this.fullTextMapperV2 = fullTextMapperV2;
this.taskManagement = taskManagement;
this.transactionInterceptHelper = transactionInterceptHelper;
Expand Down
3 changes: 3 additions & 0 deletions server-api/src/main/java/org/apache/atlas/RequestContext.java
Original file line number Diff line number Diff line change
Expand Up @@ -161,6 +161,9 @@ public void clearCache() {
this.relationshipMutationMap.clear();
this.currentTask = null;
this.skipAuthorizationCheck = false;
this.delayTagNotifications = false;
deletedClassificationAndVertices.clear();
addedClassificationAndVertices.clear();

if (metrics != null && !metrics.isEmpty()) {
METRICS.debug(metrics.toString());
Expand Down

0 comments on commit 0138517

Please sign in to comment.