docs: @Override
      public Map<BeanId, Bean> getBeanToValidate(Collection<Bean> beans) throws AbortRuntimeException {
          try {
              if (!begin()) {
                  return new HashMap<>();
              }
              Set<BeanId> ids = new HashSet<>();
              for (Bean bean : beans) {
                  ids.add(bean.getId());
              }
              Set<Bean> beansToValidate = JpaBean.getBeanToValidate(ids);
              commit();
              return uniqueIndex(beansToValidate);
          } catch (AbortRuntimeException e) {
              rollback();
              throw e;
  
          } catch (Throwable e) {
              rollback();
              throw new RuntimeException(e);
          }
      }