Revision: 15621
Author: [email protected]
Date: Fri Dec  3 09:17:56 2010
Log: Update Issue 1875

more fixes while testing integration in MSS
http://code.google.com/p/mobicents/source/detail?r=15621

Modified:
/trunk/servers/jain-sip-ha/core/src/main/java/org/mobicents/ha/javax/sip/ClusteredSipStackImpl.java

=======================================
--- /trunk/servers/jain-sip-ha/core/src/main/java/org/mobicents/ha/javax/sip/ClusteredSipStackImpl.java Fri Dec 3 01:56:53 2010 +++ /trunk/servers/jain-sip-ha/core/src/main/java/org/mobicents/ha/javax/sip/ClusteredSipStackImpl.java Fri Dec 3 09:17:56 2010
@@ -452,7 +452,10 @@
                                                
if(getStackLogger().isLoggingEnabled(StackLogger.TRACE_DEBUG)) {
getStackLogger().logDebug("sipStack " + this + " transaction " + transactionId + " server = " + isServer + " is present in the distributed cache");
                                                }
- sipTransaction = serverTransactionTable.putIfAbsent(sipTransaction.getTransactionId(), (SIPServerTransaction) sipTransaction); + SIPServerTransaction retval = serverTransactionTable.putIfAbsent(sipTransaction.getTransactionId(), (SIPServerTransaction) sipTransaction);
+                                               if(retval != null) {
+                                                       sipTransaction = retval;
+                                               }
                                        } else {
                                                
if(getStackLogger().isLoggingEnabled(StackLogger.TRACE_DEBUG)) {
getStackLogger().logDebug("sipStack " + this + " transaction " + transactionId + " server = " + isServer + " is not present in the distributed cache");
@@ -469,7 +472,10 @@
                                                
if(getStackLogger().isLoggingEnabled(StackLogger.TRACE_DEBUG)) {
getStackLogger().logDebug("sipStack " + this + " transaction " + transactionId + " server = " + isServer + " is present in the distributed cache");
                                                }
- sipTransaction = clientTransactionTable.putIfAbsent(sipTransaction.getTransactionId(), (SIPClientTransaction) sipTransaction); + SIPClientTransaction retval = clientTransactionTable.putIfAbsent(sipTransaction.getTransactionId(), (SIPClientTransaction) sipTransaction);
+                                               if(retval != null) {
+                                                       sipTransaction = retval;
+                                               }
                                        } else {
                                                
if(getStackLogger().isLoggingEnabled(StackLogger.TRACE_DEBUG)) {
getStackLogger().logDebug("sipStack " + this + " transaction " + transactionId + " server = " + isServer + " is not present in the distributed cache");

Reply via email to