[
https://issues.apache.org/jira/browse/TRAFODION-2150?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15829058#comment-15829058
]
ASF GitHub Bot commented on TRAFODION-2150:
-------------------------------------------
Github user sbroeder commented on a diff in the pull request:
https://github.com/apache/incubator-trafodion/pull/917#discussion_r96768810
--- Diff:
core/sqf/src/seatrans/tm/hbasetmlib2/src/main/java/org/trafodion/dtm/HBaseTxClient.java
---
@@ -1108,9 +1108,28 @@ public void run() {
}
if (LOG.isDebugEnabled()) LOG.debug("TRAF RCOV
THREAD: in-doubt transaction size " + transactionStates.size());
for (Map.Entry<Long, TransactionState> tsEntry
: transactionStates.entrySet()) {
+ int isTransactionStillAlive = 0;
TransactionState ts = tsEntry.getValue();
Long txID = ts.getTransactionId();
// TransactionState ts = new
TransactionState(txID);
+
+ //It is possible for long prepare
situations that involve multiple DDL
+ //operations, multiple prompts from RS is
received. Hence check to see if there
+ //is a TS object in main TS list and
transaction is still active.
+ //Note that tsEntry is local TS object.
+ if (hbtx.mapTransactionStates.get(txID) !=
null) {
+ if
(hbtx.mapTransactionStates.get(txID).getStatus().toString().contains("ACTIVE"))
{
+ isTransactionStillAlive = 1;
+ }
+ if (LOG.isInfoEnabled())
+ LOG.info("TRAF RCOV THREAD: TID " + txID
+ + " still has ts object in TM
memory with state "
+ +
hbtx.mapTransactionStates.get(txID).getStatus().toString()
--- End diff --
How do you feel about printing the entire TS object instead of just the
state? Some other useful information could be printed
for example:
LOG.info("TRAF RCOV THREAD: TID " + txID + " still has ts object in TM
memory " + hbtx.mapTransactionStates.get(txID).toString()
> Long commit prepare causes auto transaction abort.
> --------------------------------------------------
>
> Key: TRAFODION-2150
> URL: https://issues.apache.org/jira/browse/TRAFODION-2150
> Project: Apache Trafodion
> Issue Type: Bug
> Components: dtm
> Affects Versions: 2.0-incubating
> Reporter: Prashanth Vasudev
> Assignee: Prashanth Vasudev
>
> Drop schema cascade scenario, there is a possibility of several table drops
> which might take time. This causes transaction to be active for long time.
> Under this scenario, transaction is automatically aborted.
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)