[
https://issues.apache.org/jira/browse/CMIS-42?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Florent Guillaume updated CMIS-42:
----------------------------------
Description:
We should use specialized exceptions (following what's defined in the spec's
domain model) to treat error cases.
First pass on the CMIS exception list:
General:
- invalidArgument -> java.lang.IllegalArgumentException
- notSupported -> java.lang.UnsupportedOperationException
- runtime -> java.lang.RuntimeException
- objectNotFound
- permissionDenied
Specific:
- constraint
- contentAlreadyExists
- filterNotValid
- folderNotValid
- storage
- streamNotSupported
- updateConflict
- versioning
At least for the general CMIS exceptions I propose to use Java unchecked
exception. Even for the specific ones I think we should minimize the number of
checked exceptions (JCR showed that having too many of those on a single method
is painful).
was:
We should use specialized exceptions (following what's defined in the spec's
domain model) to treat error cases.
First pass on the CMIS exception list:
General:
invalidArgument -> java.lang.IllegalArgumentException
notSupported -> java.lang.UnsupportedOperationException
runtime -> java.lang.RuntimeException
objectNotFound
permissionDenied
Specific:
constraint
contentAlreadyExists
filterNotValid
folderNotValid
storage
streamNotSupported
updateConflict
versioning
At least for the general CMIS exceptions I propose to use Java unchecked
exception. Even for the specific ones I think we should minimize the number of
checked exceptions (JCR showed that having too many of those on a single method
is painful).
> Use specialized CMIS-related exceptions to deal with error cases
> ----------------------------------------------------------------
>
> Key: CMIS-42
> URL: https://issues.apache.org/jira/browse/CMIS-42
> Project: Chemistry
> Issue Type: Task
> Components: api
> Reporter: Florent Guillaume
> Assignee: Florent Guillaume
>
> We should use specialized exceptions (following what's defined in the spec's
> domain model) to treat error cases.
> First pass on the CMIS exception list:
> General:
> - invalidArgument -> java.lang.IllegalArgumentException
> - notSupported -> java.lang.UnsupportedOperationException
> - runtime -> java.lang.RuntimeException
> - objectNotFound
> - permissionDenied
> Specific:
> - constraint
> - contentAlreadyExists
> - filterNotValid
> - folderNotValid
> - storage
> - streamNotSupported
> - updateConflict
> - versioning
> At least for the general CMIS exceptions I propose to use Java unchecked
> exception. Even for the specific ones I think we should minimize the number
> of checked exceptions (JCR showed that having too many of those on a single
> method is painful).
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.