Package org.drools.persistence.session.SingleSessionCommandService

Examples of org.drools.persistence.session.SingleSessionCommandService.EndOperationListenerImpl


            try {
              SpringSingleSessionCommandService.this.env.set(EnvironmentName.ENTITY_MANAGER, em);
              em.persist(sessionInfo);
              // update the session id to be the same as the session info id
              ((StatefulKnowledgeSessionImpl) ksession).session.setId(sessionInfo.getId());
              ((StatefulKnowledgeSessionImpl) ksession).session.setEndOperationListener( new EndOperationListenerImpl( sessionInfo ) );
              em.flush();
              return null;
            } finally {
              SpringSingleSessionCommandService.this.env.set(EnvironmentName.ENTITY_MANAGER, null);
            }
View Full Code Here


                  .setCommandService(SpringSingleSessionCommandService.this);

              // update the session id to be the same as the
              // session info id
              ((StatefulKnowledgeSessionImpl) ksession).session.setId(sessionInfo.getId());
              ((StatefulKnowledgeSessionImpl) ksession).session.setEndOperationListener( new EndOperationListenerImpl( sessionInfo ) );
              em.flush();
              return sessionInfo;
            } finally {
              SpringSingleSessionCommandService.this.env.set(EnvironmentName.ENTITY_MANAGER, null);
            }
View Full Code Here

            env.set(EnvironmentName.ENTITY_MANAGER, em);
            try {
              SessionInfo sessionInfoMerged = em.merge(sessionInfo);
              sessionInfoMerged.setJPASessionMashallingHelper(sessionInfo.getJPASessionMashallingHelper());
              sessionInfo = sessionInfoMerged;
              ((StatefulKnowledgeSessionImpl) ksession).session.setEndOperationListener( new EndOperationListenerImpl( sessionInfo ) );
             
              T result = command.execute(kContext);
              em.flush();
              return result;
            } finally {
View Full Code Here

TOP

Related Classes of org.drools.persistence.session.SingleSessionCommandService.EndOperationListenerImpl

Copyright © 2018 www.massapicom. 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.