You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@atlas.apache.org by "David Kantor (JIRA)" <ji...@apache.org> on 2016/08/01 18:25:20 UTC

[jira] [Commented] (ATLAS-991) Lower bound checking not always disabled for Entities being deleted

    [ https://issues.apache.org/jira/browse/ATLAS-991?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15402571#comment-15402571 ] 

David Kantor commented on ATLAS-991:
------------------------------------

[~shwethags]  [~suma.shivaprasad]  Can someone please review and commit or provide comments?  It has been in the Patch Available state since July 12.  Thanks...

> Lower bound checking not always disabled for Entities being deleted
> -------------------------------------------------------------------
>
>                 Key: ATLAS-991
>                 URL: https://issues.apache.org/jira/browse/ATLAS-991
>             Project: Atlas
>          Issue Type: Bug
>            Reporter: Jeffrey Hagelberg
>            Assignee: David Kantor
>         Attachments: rb49869.patch
>
>
> It is often the case multiple entities get deleted at the same time.  The current delete logic does not compute the delete closure up front, so it is possible for the processing of a particular Entity to trigger a lower bound violation in an entity that will be deleted but has not been processed yet.
> This issue is specific to hard delete.  It does not happen when soft delete is being used.
> Here's a simple test that can be added to GraphBackedMetadataRepositoryDeleteTestBase to reproduce the issue:
> {noformat}
>     @Test
>     public void testLowerBoundsIgnoredOnDeletedEntities() throws Exception {
>         
>         String hrDeptGuid = createHrDeptGraph();
>         ITypedReferenceableInstance hrDept = repositoryService.getEntityDefinition(hrDeptGuid);
>         Map<String, String> nameGuidMap = getEmployeeNameGuidMap(hrDept);
>         ITypedReferenceableInstance john = repositoryService.getEntityDefinition(nameGuidMap.get("John"));
>         String johnGuid = john.getId()._getId();
>         ITypedReferenceableInstance max = repositoryService.getEntityDefinition(nameGuidMap.get("Max"));
>         String maxGuid = max.getId()._getId();
>         
>         ITypedReferenceableInstance jane = repositoryService.getEntityDefinition(nameGuidMap.get("Jane"));
>         String janeGuid = jane.getId()._getId();
>         
>         //the lower bound constraint on jane.subordinates should not be enforced since jane is being deleted
>         deleteEntities(johnGuid, maxGuid, janeGuid);
>         
>     }
> {noformat}



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)