You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@tomee.apache.org by "Jacek Laskowski (JIRA)" <ji...@apache.org> on 2009/06/12 15:26:07 UTC

[jira] Commented: (OPENEJB-980) @ApplicationException inheritance

    [ https://issues.apache.org/jira/browse/OPENEJB-980?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12718831#action_12718831 ] 

Jacek Laskowski commented on OPENEJB-980:
-----------------------------------------

@ApplicationException is inheritable via its inherited element (cf. EJB 3.1 PFD page 378). OpenEJB 3.1 supports it now, but it doesn't care of inherited setting yet (it is as if inherited were true always). It paved a way for examples/applicationexception. The issue's getting to its close...

> @ApplicationException inheritance
> ---------------------------------
>
>                 Key: OPENEJB-980
>                 URL: https://issues.apache.org/jira/browse/OPENEJB-980
>             Project: OpenEJB
>          Issue Type: New Feature
>            Reporter: Geoff Callender
>            Assignee: Jacek Laskowski
>             Fix For: 3.1.x
>
>
> When @ApplicationException(rollback = true) is annotated on an exception thrown by a session bean then all is well - the client receives the exception.
> But if the annotation is moved up to a superclass of the exception then all is not well - the client receives EJBTransactionRolledbackException.
> In the app server I am porting from the following worked OK, and I believe it is the correct behaviour:
> public interface DogServiceRemote {
>     void createDog(Dog dog) throws BusinessException;
> }
> @ApplicationException(rollback = true)
> abstract public class BusinessException extends Exception {
> ...
> }
> public class ValueRequiredException extends BusinessException {
> ...
> }
> where createDog(...) throws many different subclasses of BusinessException, none of which is annotated with @ApplicationException.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.