Examples of DynamicProxy


Examples of com.atomikos.util.DynamicProxy

    CompositeTransaction current = tm.getCompositeTransaction();
    if ( ( current != null ) && ( current.getProperty ( TransactionManagerImp.JTA_PROPERTY_NAME) != null )) {
      synchronized (sessions) {
        for (int i=0; i<sessions.size() ;i++) {
          Session session = (Session) sessions.get(i);
          DynamicProxy dproxy = ( DynamicProxy ) session;
          AbstractJmsSessionProxy proxy = (AbstractJmsSessionProxy) dproxy.getInvocationHandler();
         
          //recycle if either inactive in this tx, OR if active (since a new session will be created anyway, and
          //concurrent sessions are allowed on the same underlying connection!
          if ( proxy.isInactiveTransaction(current) || proxy.isInTransaction( current ) ) {
            Configuration.logInfo ( this + ": recycling session " + proxy );
View Full Code Here

Examples of com.atomikos.util.DynamicProxy

    boolean ret = closed;
    synchronized (sessions) {
      Iterator it = sessions.iterator();
      while ( it.hasNext() && ret ) {
        Object handle = it.next();
        DynamicProxy dproxy = ( DynamicProxy ) handle;
        AbstractJmsSessionProxy  session = (AbstractJmsSessionProxy) dproxy.getInvocationHandler();
        if ( !session.isAvailable() ) {
          ret = false;
        }
      }
    }
View Full Code Here

Examples of com.atomikos.util.DynamicProxy

    boolean ret = erroneous;
    synchronized (sessions) {
      Iterator it = sessions.iterator();
      while ( it.hasNext() && !ret ) {
        Object handle = it.next();
        DynamicProxy dproxy = ( DynamicProxy ) handle;
        AbstractJmsSessionProxy  session = (AbstractJmsSessionProxy) dproxy.getInvocationHandler();
        if ( session.isErroneous() ) ret = true;
      }
    }
    return ret;
  }
View Full Code Here

Examples of com.atomikos.util.DynamicProxy

    boolean ret = false;
    synchronized (sessions) {
      Iterator it = sessions.iterator();
      while ( it.hasNext() && !ret ) {
        Object handle = it.next();
        DynamicProxy dproxy = ( DynamicProxy ) handle;
        AbstractJmsSessionProxy  session = (AbstractJmsSessionProxy) dproxy.getInvocationHandler();
        if ( session.isInTransaction ( ct ) ) ret = true;
      }
    }
    return ret;
  }
View Full Code Here

Examples of com.atomikos.util.DynamicProxy

    boolean ret = false;
    synchronized (sessions) {
      Iterator it = sessions.iterator();
      while ( it.hasNext() && !ret ) {
        Object handle = it.next();
        DynamicProxy dproxy = ( DynamicProxy ) handle;
        AbstractJmsSessionProxy  session = (AbstractJmsSessionProxy) dproxy.getInvocationHandler();
        if ( session.isInactiveTransaction ( ct ) ) ret = true;
      }
    }
    return ret;
  }
View Full Code Here

Examples of com.atomikos.util.DynamicProxy

    //a session has terminated -> remove it from the list of sessions to enable GC
    synchronized (sessions) {
      Iterator it = sessions.iterator();
      while ( it.hasNext() ) {
        Object handle = it.next();
        DynamicProxy dproxy = ( DynamicProxy ) handle;
        AbstractJmsSessionProxy  session = (AbstractJmsSessionProxy) dproxy.getInvocationHandler();
        if ( session.isAvailable() ) it.remove();
      }
    }
  }
View Full Code Here

Examples of com.atomikos.util.DynamicProxy

    CompositeTransaction current = tm.getCompositeTransaction();
    if ( ( current != null ) && ( current.getProperty ( TransactionManagerImp.JTA_PROPERTY_NAME) != null )) {
      synchronized (sessions) {
        for (int i=0; i<sessions.size() ;i++) {
          Session session = (Session) sessions.get(i);
          DynamicProxy dproxy = ( DynamicProxy ) session;
          AbstractJmsSessionProxy proxy = (AbstractJmsSessionProxy) dproxy.getInvocationHandler();
         
          //recycle if either inactive in this tx, OR if active (since a new session will be created anyway, and
          //concurrent sessions are allowed on the same underlying connection!
          if ( proxy.isInactiveTransaction(current) || proxy.isInTransaction( current ) ) {
            if ( LOGGER.isInfoEnabled() ) LOGGER.logInfo ( this + ": recycling session " + proxy );
View Full Code Here

Examples of com.atomikos.util.DynamicProxy

    boolean ret = closed;
    synchronized (sessions) {
      Iterator it = sessions.iterator();
      while ( it.hasNext() && ret ) {
        Object handle = it.next();
        DynamicProxy dproxy = ( DynamicProxy ) handle;
        AbstractJmsSessionProxy  session = (AbstractJmsSessionProxy) dproxy.getInvocationHandler();
        if ( !session.isAvailable() ) {
          ret = false;
        }
      }
    }
View Full Code Here

Examples of com.atomikos.util.DynamicProxy

    boolean ret = erroneous;
    synchronized (sessions) {
      Iterator it = sessions.iterator();
      while ( it.hasNext() && !ret ) {
        Object handle = it.next();
        DynamicProxy dproxy = ( DynamicProxy ) handle;
        AbstractJmsSessionProxy  session = (AbstractJmsSessionProxy) dproxy.getInvocationHandler();
        if ( session.isErroneous() ) ret = true;
      }
    }
    return ret;
  }
View Full Code Here

Examples of com.atomikos.util.DynamicProxy

    boolean ret = false;
    synchronized (sessions) {
      Iterator it = sessions.iterator();
      while ( it.hasNext() && !ret ) {
        Object handle = it.next();
        DynamicProxy dproxy = ( DynamicProxy ) handle;
        AbstractJmsSessionProxy  session = (AbstractJmsSessionProxy) dproxy.getInvocationHandler();
        if ( session.isInTransaction ( ct ) ) ret = true;
      }
    }
    return ret;
  }
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.