docs: public XARminst getXARminst() throws XAException {
          if (tc.isEntryEnabled())
              Tr.entry(tc, "getXARminst", new Object[] { this });
  
          XAResource xaRes = null;
          XAResourceFactory xaResFactory;
          Serializable xaResInfo = null;
  
          final XARecoveryWrapper xarw = (XARecoveryWrapper) _logData;
  
          if ((xaResInfo = getXAResourceInfo()) instanceof DirectEnlistXAResourceInfo) {
              xaResFactory = null;
              xaRes = ((DirectEnlistXAResourceInfo) xaResInfo).getXAResource();
          } else {
              // We should always have a non-null non-blank factory classname as it is
              // validated by registerResourceInfo before creating an XARecoveryWrapper
              final String xaResFactoryClassName = xarw.getXAResourceFactoryClassName();
  
              /*
               * Starting in 8.5 we can have a filter registered instead of a class name
               */
              xaResFactory = XARecoveryDataHelper.lookupXAResourceFactory(xaResFactoryClassName);
              if (xaResFactory != null) {
                  // Have recovered xaResourceFactory
                  try {
                      xaRes = xaResFactory.getXAResource(xaResInfo);
                  } catch (XAResourceNotAvailableException e) {
                      // Swallow this exception we'll follow the "traditional" codepath below
                      if (tc.isDebugEnabled())
                          Tr.debug(tc, "getXARminst", e);
                  }
              }
  
              if (xaRes == null) {
                  // If this looks like a filter we'll try again later
                  if (xaResFactoryClassName.startsWith("(")) {
                      final XAException e = new XAException(XAException.XAER_RMFAIL);
                      e.initCause(new XAResourceNotAvailableException());
                      if (tc.isEntryEnabled())
                          Tr.exit(tc, "getXARminst", e);
                      throw e;
                  }
  
                  // Traditional
                  Class<?> xaResFactoryClass = null;
  
                  try {
                      if (tc.isDebugEnabled())
                          Tr.debug(tc, "calling Class.forName", xaResFactoryClassName);
                      xaResFactoryClass = Class.forName(xaResFactoryClassName);
  
                      // Trace the class and its loader - this should work as we are not in app code
                      if (tc.isDebugEnabled())
                          Tr.debug(tc, "xaResFactoryClass", new Object[] { xaResFactoryClass, xaResFactoryClass.getClassLoader() });
  
                      xaResFactory = (XAResourceFactory) xaResFactoryClass.newInstance();
                  } catch (Throwable t) {
                      //
                      // If we cannot create one of our known factories, then we are broken.
                      // Flag this and carry on.  We try to recover as much as possible for all resources.
                      //
                      FFDCFilter.processException(t, "com.ibm.tx.jta.impl.XARecoveryData.getXARminst", "419");
                      Tr.error(tc, "WTRN0004_CANT_CREATE_XARESOURCEFACTORY", new Object[] { xaResFactoryClassName, t });
                      final XAException xae = new XAException(XAException.XAER_RMERR);
                      if (tc.isEntryEnabled())
                          Tr.exit(tc, "getXARminst", xae);
                      throw xae;
                  }
  
                  try {
                      // If we can't proceed of if the factory gives us a null XAResource
                      // we want to retry
                      xaResInfo = getXAResourceInfo();
                      if (null == (xaRes = xaResFactory.getXAResource(xaResInfo))) {
                          throw new XAResourceNotAvailableException();
                      }
                  } catch (XAResourceNotAvailableException e) {
                      FFDCFilter.processException(e, "com.ibm.tx.jta.impl.XARecoveryData.getXARminst", "491", this);
                      final Throwable t = new XAException(XAException.XAER_RMFAIL).initCause(e);
                      if (tc.isEntryEnabled())
                          Tr.exit(tc, "getXARminst", t);
                      throw (XAException) t;
                  } catch (Throwable e) {
                      //
                      // Fatal error - mark it as such for when we return
                      //
                      FFDCFilter.processException(e, "com.ibm.tx.jta.impl.XARecoveryData.getXARminst", "563");
                      Tr.error(tc, "WTRN0005_CANT_RECREATE_XARESOURCE", new Object[] { xaResInfo, e });
                      final Throwable t = new XAException(XAException.XAER_RMERR).initCause(e);
                      if (tc.isEntryEnabled())
                          Tr.exit(tc, "getXARminst", t);
                      throw (XAException) t;
                  }
  
              }
          }
  
          // Trace the resource and its loader - this should work as we are not in app code
          if (tc.isDebugEnabled())
              Tr.debug(tc, "xaResource", new Object[] { xaRes, xaRes.getClass().getClassLoader() });
  
          //
          // Create XARminst, which is a Resource Manager proxy.
          // Need to add xaResFactory to XARminst during
          // recovery, so we can closeConnection after recovery.
          //
          final XARminst xarm = new XARminst(xaRes, xaResFactory);
          if (tc.isEntryEnabled())
              Tr.exit(tc, "getXARminst", xarm);
          return xarm;
      }