docs: EntityManagerFactory getEntityManagerFactory(J2EEName j2eeName) {
          final boolean isTraceOn = TraceComponent.isAnyTracingEnabled();
          if (isTraceOn && tc.isEntryEnabled())
              Tr.entry(tc, "getEntityManagerFactory : " + ivArchivePuId + ", " + j2eeName);
  
          // This is an internal error if it occurs, so not going to provide
          // a system log or elaborate message.
          if (ivEMFactoryException != null) // d743091
          {
              if (isTraceOn && tc.isEntryEnabled())
                  Tr.exit(tc, "getEntityManagerFactory : " + ivEMFactoryException);
              // Wrap in another RuntimeException to capture the current stack trace.
              throw new RuntimeException(ivEMFactoryException); // d743091, RTC114812
          }
  
          // This is an internal error if it occurs, so not going to provide
          // a system log or elaborate message.
          if (j2eeName == null) {
              if (isTraceOn && tc.isEntryEnabled())
                  Tr.exit(tc, "getEntityManagerFactory : IllegalArgumentException");
              throw new IllegalArgumentException("Component identifier must be provided  : " + ivArchivePuId);
          }
  
          // Assume the EMF to be returned is the one created during app start.
          EntityManagerFactory emf = ivEMFactory;
  
          // An EntityManagerFactory Map is only created if one of the datasrouces
          // has been defined in java:comp/env.  When this is true, a component
          // specific EMF needs to be obtained from the map, or created and added
          // to the map.
          if (ivEMFMap != null) {
              synchronized (ivEMFMap) {
                  emf = ivEMFMap.get(j2eeName);
  
                  if (emf == null) {
                      if (ivCreateEMFAllowed) {
                          PersistenceUnitInfo puInfo = new JPACompPUnitInfo(ivArchivePuId, this, j2eeName);
                          emf = createEMFactory(puInfo, false);
                          ivEMFMap.put(j2eeName, emf);
  
                          if (isTraceOn && tc.isDebugEnabled())
                              Tr.debug(tc, "new emf added to EMF Map for : " + j2eeName);
                      } else {
                          if (isTraceOn && tc.isDebugEnabled())
                              Tr.debug(tc, "PU closed; base emf returned for : " + j2eeName);
  
                          emf = ivEMFactory;
                      }
                  } else {
                      if (isTraceOn && tc.isDebugEnabled())
                          Tr.debug(tc, "emf obtained from EMF Map for : " + j2eeName);
                  }
              }
          }
  
          if (isTraceOn && tc.isEntryEnabled())
              Tr.exit(tc, "getEntityManagerFactory : " + emf);
  
          return emf;
      }