atlas-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Hemanth Yamijala (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (ATLAS-476) Update type attribute with Reserved characters updated the original type as unknown
Date Tue, 16 Feb 2016 06:16:18 GMT

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

Hemanth Yamijala commented on ATLAS-476:
----------------------------------------

My findings on debugging this issue are as follows: The update type definition flow does the
following:
* Updates the in-memory type system cache ({{TransientTypeSystem.defineTypes}})
* Updates the graph index store ({{DefaultMetadataService.onTypesUpdated}})
* Updates the graph metadata store ({{GraphBackedTypeStore.store}})
* If there's any exception in the 2nd and 3rd step, it *removes* the type from the in-memory
type system cache. That explains why the subsequent calls do not find the type.

The issue is that we are committing changes across three different stores: the in-memory cache,
the index store and the metadata store. If any of these fails, the corresponding undo operation
needs to be implemented against the stores where the commit operation succeeded. The current
code (incorrectly) assumes that the undo operation is removal of the type from the in-memory
cache, where it should ideally be restoring the older version in an update scenario. Also,
nothing is done to undo the changes to the index store, which also appears to be a problem
IMO.


> Update type attribute with Reserved characters updated the original type as unknown
> -----------------------------------------------------------------------------------
>
>                 Key: ATLAS-476
>                 URL: https://issues.apache.org/jira/browse/ATLAS-476
>             Project: Atlas
>          Issue Type: Bug
>    Affects Versions: trunk
>         Environment: sandbox
>            Reporter: Chethana
>            Assignee: Hemanth Yamijala
>            Priority: Blocker
>         Attachments: 1.log
>
>
> create a type with required attribute
> try to get this type created - the type data is returned
> try update this type by adding attribute with attribute name consisting of a reserved
character eg:test$
> this throws exception.
> Now use to get call to get the previously created type
> Expected:
> The type should not be updated.
> Actual:
> "error": "Unknown datatype: className_update_vsvrbzqaqg",
> "stackTrace": "org.apache.atlas.typesystem.exception.TypeNotFoundException: Unknown datatype:
className_update_vsvrbzqaqg\n\tat 



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

Mime
View raw message