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

ASF GitHub Bot commented on TRAFODION-1988:
-------------------------------------------

Github user trinakrug commented on a diff in the pull request:

    https://github.com/apache/incubator-trafodion/pull/559#discussion_r69005962
  
    --- Diff: 
core/sqf/src/seatrans/tm/hbasetmlib2/src/main/java/org/trafodion/dtm/HBaseTxClient.java
 ---
    @@ -597,24 +602,25 @@ public short doCommit(long transactionId) throws 
Exception {
            return TransReturnCode.RET_OK.getShort();
        }
     
    -   public short completeRequest(long transactionId) throws Exception {
    +   public short completeRequest(long transactionId) throws IOException, 
CommitUnsuccessfulException {
          if (LOG.isDebugEnabled()) LOG.debug("Enter completeRequest, txid: " + 
transactionId);
          TransactionState ts = mapTransactionStates.get(transactionId);
     
          if(ts == null) {
               LOG.error("Returning from HBaseTxClient:completeRequest, (null 
tx) retval: " + TransReturnCode.RET_NOTX.toString() + " txid: " + 
transactionId);
               return TransReturnCode.RET_NOTX.getShort();
            }
    -
    -       try {
    -
    -       if (LOG.isTraceEnabled()) LOG.trace("TEMP completeRequest Calling 
CompleteRequest() Txid :" + transactionId);
    -
    -          ts.completeRequest();
    -       } catch(Exception e) {
    -          LOG.error("Returning from HBaseTxClient:completeRequest, 
ts.completeRequest: txid: " + transactionId + ", EXCEPTION: " + e);
    -       throw new Exception("Exception during completeRequest, unable to 
commit.  Exception: " + e);
    -       }
    +  
    +       boolean loopBack = false;
    +       do {
    +          try {
    +             if (LOG.isTraceEnabled()) LOG.trace("TEMP completeRequest 
Calling CompleteRequest() Txid :" + transactionId);
    +             ts.completeRequest();
    --- End diff --
    
    Should there be a loopBack = false after completeRequest in the case where 
an exception occurred but then the operation succeeded? 


> Better java exception handling in the java layer of Trafodion
> -------------------------------------------------------------
>
>                 Key: TRAFODION-1988
>                 URL: https://issues.apache.org/jira/browse/TRAFODION-1988
>             Project: Apache Trafodion
>          Issue Type: Improvement
>          Components: dtm, sql-exe
>    Affects Versions: 2.1-incubating
>            Reporter: Selvaganesan Govindarajan
>            Assignee: Selvaganesan Govindarajan
>
> Java exceptions are not handled in consistent manner in Trafodion. The SQL 
> interface layer in Trafodion is capable of displaying the entire java stack 
> trace to the client application when an exception is raised in java portion 
> of the Trafodion/Hbase/Hdfs stack. However, there are portions of the code in 
> Trafodion where the exceptions are not handled in a consistent manner. This 
> JIRA attempts to fix this.



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

Reply via email to