docs: public synchronized int getSITransactionId(int connectionObjectId,
                                                 ServerLinkLevelState linkState,
                                                 boolean txOptimized) {
          if (tc.isEntryEnabled())
              SibTr.entry(tc, "getSITransactionId",
                                             new Object[] { "" + connectionObjectId, linkState, "" + txOptimized });
  
          final int transactionId;
          int transactionFlags = -1;
  
          if (txOptimized) {
              // Read the flags BIT32 from the data.
              transactionFlags = getInt();
  
              // Check transacted bit to verify whether this flow is transacted or not.
              if ((transactionFlags & CommsConstants.OPTIMIZED_TX_FLAGS_TRANSACTED_BIT) == 0) {
                  transactionId = CommsConstants.NO_TRANSACTION;
              } else {
                  int owningConvId = getInt();
                  // Read the transaction identifier BIT32.
                  transactionId = getInt();
  
                  if (tc.isDebugEnabled()) {
                      SibTr.debug(this, tc, "Transaction Flags", "" + transactionFlags);
                      SibTr.debug(this, tc, "Owning Conversation Id", "" + owningConvId);
                      SibTr.debug(this, tc, "Transaction Id", "" + transactionId);
                  }
  
                  // Check the flags to determine if we need to create a new transaction or not.
                  if ((transactionFlags & CommsConstants.OPTIMIZED_TX_FLAGS_CREATE_BIT) != 0) {
                      // Check the flags to determine if we are creating a local or global
                      // transaction.
                      if ((transactionFlags & CommsConstants.OPTIMIZED_TX_FLAGS_LOCAL_BIT) != 0) {
                          // local tran - determine if subordinates are allowed
                          final boolean allowSubordinates =
                                          (transactionFlags & CommsConstants.OPTIMIZED_TX_FLAGS_SUBORDINATES_ALLOWED) != 0;
                          try {
                              SIUncoordinatedTransaction uctran =
                                              linkState.getSICoreConnectionTable().get(owningConvId).createUncoordinatedTransaction(allowSubordinates);
                              linkState.getTransactionTable().addLocalTran(transactionId, owningConvId, uctran);
                          } catch (SIException e) {
                              // No FFDC Code Needed
                              if (tc.isEventEnabled())
                                  SibTr.exception(tc, e);
                              linkState.getTransactionTable().addLocalTran(transactionId, owningConvId, IdToTransactionTable.INVALID_TRANSACTION);
                              linkState.getTransactionTable().markAsRollbackOnly(transactionId, e);
                          }
                      } else {
                          // global tran
                          SIXAResource xaRes = null;
                          XidProxy xidProxy = null;
                          try {
                              // Check the flags to determine if the XAResource needs end invoking on
                              // it before a new transaction can be started.
                              if ((transactionFlags & CommsConstants.OPTIMIZED_TX_END_PREVIOUS_BIT) != 0) {
                                  int endFlags = getInt();
                                  linkState.getTransactionTable().endOptimizedGlobalTransactionBranch(transactionId, endFlags);
                                  xaRes = (SIXAResource) linkState.getTransactionTable().get(transactionId);
                              } else {
                                  xaRes =
                                                  linkState.getSICoreConnectionTable().get(owningConvId).getSIXAResource();
  
                              }
  
                              xidProxy = (XidProxy) getXid();
  
                              if (tc.isDebugEnabled())
                                  SibTr.debug(tc, "xidProxy", xidProxy);
  
                              xaRes.start(xidProxy, SIXAResource.TMNOFLAGS);
                              linkState.getTransactionTable().addGlobalTransactionBranch(transactionId, owningConvId, xaRes, xidProxy, true);
                          } catch (SIException e) {
                              // No FFDC Code Needed
                              if (tc.isEventEnabled())
                                  SibTr.exception(tc, e);
                              linkState.getTransactionTable().addGlobalTransactionBranch(transactionId, owningConvId, IdToTransactionTable.INVALID_TRANSACTION, xidProxy, true);
                              linkState.getTransactionTable().markAsRollbackOnly(transactionId, e);
                          } catch (XAException e) {
                              // No FFDC Code Needed
                              if (tc.isEventEnabled())
                                  SibTr.exception(tc, e);
                              linkState.getTransactionTable().addGlobalTransactionBranch(transactionId, owningConvId, IdToTransactionTable.INVALID_TRANSACTION, xidProxy, true);
                              linkState.getTransactionTable().markAsRollbackOnly(transactionId, e);
                          }
                      }
                  }
              }
          } else {
              // Not an optimized transaction.  Simply find its id.
              transactionId = getInt();
              if (tc.isDebugEnabled())
                  SibTr.debug(tc, "transactionId", "" + transactionId);
          }
  
          if (TraceComponent.isAnyTracingEnabled()) {
              Object commsTx = null;
              if (transactionId != CommsConstants.NO_TRANSACTION)
                  commsTx = linkState.getTransactionTable().get(transactionId, true);
              CommsLightTrace.traceTransaction(tc, "GetTxnTrace", commsTx, transactionId, transactionFlags);
          }
  
          if (tc.isEntryEnabled())
              SibTr.exit(tc, "getSITransactionId", "" + transactionId);
          return transactionId;
      }