@Before
 public void setUp() throws Exception {
   ds = setupPoolingDataSource();
   logger.debug("Data source configured with unique id {}", ds.getUniqueName());
   emf = Persistence.createEntityManagerFactory(PERSISTENCE_UNIT_NAME);
   cleanupSingletonSessionId();
 }
Example #2
0
  @Before
  public void setUp() throws Exception {

    if (setupDataSource) {
      ds = setupPoolingDataSource();
      logger.debug("Data source configured with unique id {}", ds.getUniqueName());
      emf = Persistence.createEntityManagerFactory(persistenceUnitName);
    }
    cleanupSingletonSessionId();
  }