You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@geronimo.apache.org by Lin Sun <li...@gmail.com> on 2009/09/17 22:13:21 UTC

[discuss] update Transaction.commit method signature in jta spec jar

Hi,

Recently, I opened GERONIMO-4683 in G about the Transaction.commit
signature is missing the IllegalStateException.  The reason why I
raised this JIRA is because in OSGi RFC 98 (Transaction in OSGi)
compliance test, we use Geronimo's JTA spec jar as the baseline.
During OSGi RFC 98 compliance test run with an implementation of RFC
98, OSGi signature test currently checks strictly on exceptions throw
by each of the method to see if it is the same as the baseline's
signature, which is the Geronimo JTA spec jar.   If it is not the same
the test fail.   For example, below is what is specified by the JTA
java doc and G JTA spec.


G JTA spec jar - Transaction.java
public void commit()
            throws HeuristicMixedException,
                   HeuristicRollbackException,
                   RollbackException,
                   SecurityException,
                   SystemException;


JTA 1.1 Java doc - Transaction.java
public void commit()
            throws RollbackException,
                   HeuristicMixedException,
                   HeuristicRollbackException,
                   SecurityException,
                   IllegalStateException,
                   SystemException

What do you think of adding the missing unchecked exception
"IllegalStateException" back to our JTA spec and release a newer
version of the JTA spec jar just to be the same as what is in the Java
doc?  I think it is good for us to be consistent with what is in the
JTA spec and we should be consistent in declaring the unchecked
exceptions (we currently declares the SecurityException but not the
IllegalStateException).

p.s. if you are interested and have access to, the related discussion
is OSGi alliance can be found here -
https://www.osgi.org/members/bugzilla/show_bug.cgi?id=1447

Thanks

Lin

Re: [discuss] update Transaction.commit method signature in jta spec jar

Posted by Kevan Miller <ke...@gmail.com>.
On Sep 17, 2009, at 4:13 PM, Lin Sun wrote:

>
> What do you think of adding the missing unchecked exception
> "IllegalStateException" back to our JTA spec and release a newer
> version of the JTA spec jar just to be the same as what is in the Java
> doc?  I think it is good for us to be consistent with what is in the
> JTA spec and we should be consistent in declaring the unchecked
> exceptions (we currently declares the SecurityException but not the
> IllegalStateException).

Been trying to find some motivation one way or another...

We can debate whether or not declaration of unchecked exceptions serve  
a useful purpose in this case. However, not sure if that really  
matters. In this instance, best to be accurate, IMO. So would support  
the update to our JTA spec.

--kevan

Re: [discuss] update Transaction.commit method signature in jta spec jar

Posted by Lin Sun <li...@gmail.com>.
Thanks.  If there is no objection by end of Sunday, I'll start this
work earlier next week.

Lin

On Fri, Sep 18, 2009 at 12:42 AM, Jack Cai <gr...@gmail.com> wrote:
> Agreed, since it won't hurt.
>
> -Jack
>
> On Fri, Sep 18, 2009 at 4:13 AM, Lin Sun <li...@gmail.com> wrote:
>>
>> Hi,
>>
>> Recently, I opened GERONIMO-4683 in G about the Transaction.commit
>> signature is missing the IllegalStateException.  The reason why I
>> raised this JIRA is because in OSGi RFC 98 (Transaction in OSGi)
>> compliance test, we use Geronimo's JTA spec jar as the baseline.
>> During OSGi RFC 98 compliance test run with an implementation of RFC
>> 98, OSGi signature test currently checks strictly on exceptions throw
>> by each of the method to see if it is the same as the baseline's
>> signature, which is the Geronimo JTA spec jar.   If it is not the same
>> the test fail.   For example, below is what is specified by the JTA
>> java doc and G JTA spec.
>>
>>
>> G JTA spec jar - Transaction.java
>> public void commit()
>>            throws HeuristicMixedException,
>>                   HeuristicRollbackException,
>>                   RollbackException,
>>                   SecurityException,
>>                   SystemException;
>>
>>
>> JTA 1.1 Java doc - Transaction.java
>> public void commit()
>>            throws RollbackException,
>>                   HeuristicMixedException,
>>                   HeuristicRollbackException,
>>                   SecurityException,
>>                   IllegalStateException,
>>                   SystemException
>>
>> What do you think of adding the missing unchecked exception
>> "IllegalStateException" back to our JTA spec and release a newer
>> version of the JTA spec jar just to be the same as what is in the Java
>> doc?  I think it is good for us to be consistent with what is in the
>> JTA spec and we should be consistent in declaring the unchecked
>> exceptions (we currently declares the SecurityException but not the
>> IllegalStateException).
>>
>> p.s. if you are interested and have access to, the related discussion
>> is OSGi alliance can be found here -
>> https://www.osgi.org/members/bugzilla/show_bug.cgi?id=1447
>>
>> Thanks
>>
>> Lin
>
>

Re: [discuss] update Transaction.commit method signature in jta spec jar

Posted by Jack Cai <gr...@gmail.com>.
Agreed, since it won't hurt.

-Jack

On Fri, Sep 18, 2009 at 4:13 AM, Lin Sun <li...@gmail.com> wrote:

> Hi,
>
> Recently, I opened GERONIMO-4683 in G about the Transaction.commit
> signature is missing the IllegalStateException.  The reason why I
> raised this JIRA is because in OSGi RFC 98 (Transaction in OSGi)
> compliance test, we use Geronimo's JTA spec jar as the baseline.
> During OSGi RFC 98 compliance test run with an implementation of RFC
> 98, OSGi signature test currently checks strictly on exceptions throw
> by each of the method to see if it is the same as the baseline's
> signature, which is the Geronimo JTA spec jar.   If it is not the same
> the test fail.   For example, below is what is specified by the JTA
> java doc and G JTA spec.
>
>
> G JTA spec jar - Transaction.java
> public void commit()
>            throws HeuristicMixedException,
>                   HeuristicRollbackException,
>                   RollbackException,
>                   SecurityException,
>                   SystemException;
>
>
> JTA 1.1 Java doc - Transaction.java
> public void commit()
>            throws RollbackException,
>                   HeuristicMixedException,
>                   HeuristicRollbackException,
>                   SecurityException,
>                   IllegalStateException,
>                   SystemException
>
> What do you think of adding the missing unchecked exception
> "IllegalStateException" back to our JTA spec and release a newer
> version of the JTA spec jar just to be the same as what is in the Java
> doc?  I think it is good for us to be consistent with what is in the
> JTA spec and we should be consistent in declaring the unchecked
> exceptions (we currently declares the SecurityException but not the
> IllegalStateException).
>
> p.s. if you are interested and have access to, the related discussion
> is OSGi alliance can be found here -
> https://www.osgi.org/members/bugzilla/show_bug.cgi?id=1447
>
> Thanks
>
> Lin
>