docs: public static void rcvXACommit(CommsByteBuffer request,
                                    Conversation conversation,
                                    int requestNumber,
                                    boolean allocatedFromBufferPool,
                                    boolean partOfExchange)
     {
        if (TraceComponent.isAnyTracingEnabled() && tc.isEntryEnabled()) SibTr.entry(tc, "rcvXACommit",
                                             new Object[]
                                             {
                                                request,
                                                conversation,
                                                ""+requestNumber,
                                                ""+allocatedFromBufferPool,
                                                ""+partOfExchange
                                              });
  
        ConversationState convState = (ConversationState) conversation.getAttachment();
        ServerLinkLevelState linkState = (ServerLinkLevelState) conversation.getLinkLevelAttachment();
  
        boolean onePhase = false;
  
        final boolean optimizedTx = CommsUtils.requiresOptimizedTransaction(conversation);
  
        try
        {
           int clientTransactionId = request.getInt();
           if (TraceComponent.isAnyTracingEnabled() && tc.isDebugEnabled())
           {
              SibTr.debug(tc, "XAResource Object ID", clientTransactionId);
           }
  
           if (TraceComponent.isAnyTracingEnabled() && tc.isDebugEnabled()) SibTr.debug(tc, "Getting Xid");
           XidProxy xid = (XidProxy) request.getXid();
           if (TraceComponent.isAnyTracingEnabled() && tc.isDebugEnabled()) SibTr.debug(tc, "Completed:", xid);
  
           byte onePhaseByte = request.get();
           if (onePhaseByte == 1) onePhase = true;
           if (TraceComponent.isAnyTracingEnabled() && tc.isDebugEnabled()) SibTr.debug(tc, "One phase:", onePhase);
  
           boolean endRequired = false;
           int endFlags = 0;
           if (optimizedTx)
           {
              endRequired = request.get() == 0x01;
              endFlags = request.getInt();
  
              if (TraceComponent.isAnyTracingEnabled() && tc.isDebugEnabled())
              {
                 SibTr.debug(tc, "End Required:", ""+endRequired);
                 SibTr.debug(tc, "End Flags:", ""+endFlags);
              }
           }
  
           boolean requiresMSResource = false;
           if (conversation.getHandshakeProperties().getFapLevel() >= JFapChannelConstants.FAP_VERSION_5)
           {
              requiresMSResource = request.get() == 0x01;
              if (TraceComponent.isAnyTracingEnabled() && tc.isDebugEnabled()) SibTr.debug(tc, "Requires MS Resource:", ""+requiresMSResource);
           }
  
           // Get the transaction out of the table
           IdToTransactionTable transactionTable = linkState.getTransactionTable();
           if (endRequired) transactionTable.endOptimizedGlobalTransactionBranch(clientTransactionId, endFlags);
           SITransaction tran = null;
  
           // As commits (for the same XAResource) can be scheduled concurrently by the receive listener
           // dispatcher - perform all updates to the IdToTransaction table inside a synchronized block.
           boolean isInvalidTransaction = false;
           boolean isUnitOfWorkInError = false;
           Throwable rollbackException = null;
           synchronized(transactionTable)
           {
              tran = transactionTable.getResourceForGlobalTransactionBranch(clientTransactionId, xid);
              if (tran != null)
              {
                 isInvalidTransaction = tran == IdToTransactionTable.INVALID_TRANSACTION;
                 if (!isInvalidTransaction)
                 {
                    isUnitOfWorkInError =
                       transactionTable.isGlobalTransactionBranchRollbackOnly(clientTransactionId, xid);
                 }
  
                 if (isInvalidTransaction || isUnitOfWorkInError)
                 {
                    rollbackException =
                       transactionTable.getExceptionForRollbackOnlyGlobalTransactionBranch(clientTransactionId, xid);
                 }
  
                 // Leave the invalid transaction in the table.  The only way to remove it is to
                 // roll it back.
                 if (!isInvalidTransaction)
                 {
                    transactionTable.removeGlobalTransactionBranch(clientTransactionId, xid);
                 }
              }
           }
  
           SIXAResource xaResource = getResourceFromTran(tran, convState, requiresMSResource);
  
           // If the UOW was never created (because we were running with the
           // optimization that gets an XAResource and enlists it as part of the
           // first piece of transacted work and this failed) then throw
           // an exception notifying the caller that the UOW has been rolled back.
           if (isInvalidTransaction)
           {
              String errorMsg =
                 nls.getFormattedMessage("TRANSACTION_MARKED_AS_ERROR_SICO2029",
                       new Object[]{ rollbackException },
                       null);
  
              XAException xa = new XAException(errorMsg);
              xa.initCause(rollbackException);
              xa.errorCode = XAException.XA_RBOTHER;
  
              throw xa;
           }
  
           if (isUnitOfWorkInError)
           {
              // PK59276 Rollback the transaction, as after we throw a XA_RB* error the
              // transaction manager will not call us with xa_rollback.
              xaResource.rollback(xid);
  
              if (TraceComponent.isAnyTracingEnabled() && tc.isDebugEnabled()) SibTr.debug(tc, "The transaction was marked as error due to",
                                                   rollbackException);
  
              // And respond with an error
              XAException xa = new XAException(
                 nls.getFormattedMessage("TRANSACTION_MARKED_AS_ERROR_SICO2029",
                                         new Object[]{ rollbackException },
                                         null)
              );
              xa.initCause(rollbackException);
              xa.errorCode = XAException.XA_RBOTHER;
  
              throw xa;
           }
  
           // Now call the method on the XA resource
           xaResource.commit(xid, onePhase);
  
           try
           {
              conversation.send(poolManager.allocate(),
                                JFapChannelConstants.SEG_XACOMMIT_R,
                                requestNumber,
                                JFapChannelConstants.PRIORITY_MEDIUM,
                                true,
                                ThrottlingPolicy.BLOCK_THREAD,
                                null);
           }
           catch (SIException e)
           {
              FFDCFilter.processException(e,
                                          CLASS_NAME + ".rcvXACommit",
                                          CommsConstants.STATICCATXATRANSACTION_XACOMMIT_01);
  
              SibTr.error(tc, "COMMUNICATION_ERROR_SICO2027", e);
           }
        }
        catch (XAException e)
        {
           FFDCFilter.processException(e,
                                       CLASS_NAME + ".rcvXACommit",
                                       CommsConstants.STATICCATXATRANSACTION_XACOMMIT_02);
  
           if (TraceComponent.isAnyTracingEnabled() && tc.isDebugEnabled()) SibTr.debug(tc, "XAException - RC: " + e.errorCode, e);
  
           StaticCATHelper.sendExceptionToClient(e,
                                                 CommsConstants.STATICCATXATRANSACTION_XACOMMIT_02,     // d186970
                                                 conversation, requestNumber);
        }
  
        request.release(allocatedFromBufferPool);
  
        if (TraceComponent.isAnyTracingEnabled() && tc.isEntryEnabled()) SibTr.exit(tc, "rcvXACommit");
     }