Examples of startTransaction()


Examples of org.apache.isis.core.runtime.system.transaction.IsisTransactionManager.startTransaction()

            ErrorCollator error = new ErrorCollator();
            final PersistenceSession checkSession = IsisContext.getPersistenceSession();
            final IsisTransactionManager transactionManager = checkSession.getTransactionManager();
            if (transactionManager.getTransaction() != null && transactionManager.getTransaction().getState().canAbort()) {
                transactionManager.abortTransaction();
                transactionManager.startTransaction();
            }

            final Throwable ex = e instanceof TagProcessingException ? e.getCause() : e;
            if (ex instanceof ForbiddenException) {
                LOG.error("invalid access to " + servletPath, e);
View Full Code Here

Examples of org.apache.isis.runtimes.dflt.runtime.system.transaction.IsisTransactionManager.startTransaction()

            final PersistenceSession checkSession = IsisContext.getPersistenceSession();
            final IsisTransactionManager transactionManager = checkSession.getTransactionManager();
            if (transactionManager.getTransaction() != null && transactionManager.getTransaction().getState().canAbort()) {
                transactionManager.abortTransaction();
                transactionManager.startTransaction();
            }

            final Throwable ex = e instanceof TagProcessingException ? e.getCause() : e;
            if (ex instanceof ForbiddenException) {
                context.addVariable("_security-context", ((TagProcessingException) e).getContext(), Scope.ERROR);
View Full Code Here

Examples of org.catais.veriso.interlis.IliReader.startTransaction()

            }

            // do the import
            {
                IliReader iliReader = new IliReader(params);
                iliReader.startTransaction();
                iliReader.read();
                iliReader.commitTransaction();

                PostProcessing postProcessing = new PostProcessing(params);
                postProcessing.run();
View Full Code Here

Examples of org.evolizer.core.hibernate.session.api.IEvolizerSession.startTransaction()

    rev5.addNicknameToAuthor("mwuersch");
    rev5.setCommitMessage("mimimi");
   
    try {
      IEvolizerSession s = fSessionHandler.getCurrentSession(fDBUrl);
      s.startTransaction();
      s.saveObject(rev1);
      s.saveObject(rev2);
      s.saveObject(rev3);
      s.saveObject(rev4);
      s.saveObject(rev5);
View Full Code Here

Examples of org.evolizer.core.hibernate.session.api.IEvolizerSession.startTransaction()

  }

  private <T>T saveAndReloadUniqueFromDB(Object object, String reloadQuery, Class<T> resultType) {
    try {
      IEvolizerSession s = fSessionHandler.getCurrentSession(fDBUrl);
      s.startTransaction();
      s.saveObject(object);
      s.endTransaction();

      s.close();
View Full Code Here

Examples of org.evolizer.core.hibernate.session.api.IEvolizerSession.startTransaction()

        boolean wasSuccessful = false;
       
        IEvolizerSession lSession = null;
        try {
            lSession = EvolizerSessionHandler.getHandler().getCurrentSession(fDBUrl);
            lSession.startTransaction();
           
            lSession.delete(fModel);
            wasSuccessful = true;
        } catch (EvolizerRuntimeException e) {
            e.printStackTrace();
View Full Code Here

Examples of org.evolizer.core.hibernate.session.api.IEvolizerSession.startTransaction()

        try {
            sLogger.debug("Storing all Famix-Entities");
            progress.setTaskName("Storing FAMIX entities");

            lSession = EvolizerSessionHandler.getHandler().getCurrentSession(fDBUrl);
            lSession.startTransaction();
            for (AbstractFamixEntity element : keys) {
                sLogger.debug("Adding to database " + element.getClass().getName() + ":\n" + element.getUniqueName());
                lSession.saveObject(element);
            }
            lSession.flush();
View Full Code Here

Examples of org.evolizer.core.hibernate.session.api.IEvolizerSession.startTransaction()

     
   
      DummyBusinessEntity entity = new DummyBusinessEntity();
      entity.setAString("This is a test");
   
      s.startTransaction();
      s.saveObject(entity);
      s.endTransaction();
   
      s.close();
   
View Full Code Here

Examples of org.evolizer.core.hibernate.session.api.IEvolizerSession.startTransaction()

      IEvolizerSession s = fSessionHandler.getCurrentSession(fDBUrl);
   
      DummyBusinessEntity entity = new DummyBusinessEntity();
      entity.setAString("This is also a test");
   
      s.startTransaction();
      s.saveObject(entity);
      s.endTransaction();
   

      List<DummyBusinessEntity> lgList = (List<DummyBusinessEntity>) s.query("from " + DummyBusinessEntity.class.getName(), DummyBusinessEntity.class);
View Full Code Here

Examples of org.evolizer.core.hibernate.session.api.IEvolizerSession.startTransaction()

  }
 
  private void save(Object... objects) {
    try {
      IEvolizerSession s = fSessionHandler.getCurrentSession(fDBUrl);
      s.startTransaction();
      for(Object o : objects) {
        s.saveObject(o);
      }
      s.endTransaction();
      s.close();
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.