atlas-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Naima Djouhri (JIRA)" <j...@apache.org>
Subject [jira] [Updated] (ATLAS-356) deleteTrait throws same exception for different error conditions
Date Fri, 22 Jan 2016 20:38:39 GMT

     [ https://issues.apache.org/jira/browse/ATLAS-356?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]

Naima Djouhri updated ATLAS-356:
--------------------------------
    Attachment: Atlas-356-Atlas-398-V0.patch

> deleteTrait throws same exception for different error conditions
> ----------------------------------------------------------------
>
>                 Key: ATLAS-356
>                 URL: https://issues.apache.org/jira/browse/ATLAS-356
>             Project: Atlas
>          Issue Type: Bug
>    Affects Versions: 0.6-incubating
>            Reporter: David Kantor
>            Assignee: Naima Djouhri
>            Priority: Minor
>         Attachments: Atlas-356-Atlas-398-V0.patch
>
>
> deleteTrait is throwing EntityNotFoundException when either the trait being deleted is
not found on the entity or when the entity itself is not found.  This makes it difficult for
callers to determine the actual error, as it forces them to parse the stack trace looking
for a specific error message.  This is a brittle solution as messages can change and in the
future are likely to be translated.  A specific exception should be thrown if the trait is
not found as that is a very different condition which callers could handle as a non-error.



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

Mime
View raw message