Package com.atomikos.datasource.pool

Examples of com.atomikos.datasource.pool.Reapable


    sessions.clear ();
  }
 
  public static Reapable newInstance ( XAConnection c, XATransactionalResource jmsTransactionalResource , SessionHandleStateChangeListener owner , ConnectionPoolProperties props )
  {
     Reapable ret = null;
    
        AtomikosJmsConnectionProxy proxy = new AtomikosJmsConnectionProxy ( c , jmsTransactionalResource , owner , props );
        Set<Class> interfaces = PropertyUtils.getAllImplementedInterfaces ( c.getClass() );
        interfaces.add ( Reapable.class );
        //see case 24532
View Full Code Here


        Set interfaces = PropertyUtils.getAllImplementedInterfaces ( c.getClass() );
        interfaces.add ( Reapable.class );
        //see case 24532
        interfaces.add ( DynamicProxy.class );
        Class[] interfaceClasses = ( Class[] ) interfaces.toArray ( new Class[0] );
        Reapable ret = null;
       
        List classLoaders = new ArrayList();
    classLoaders.add ( Thread.currentThread().getContextClassLoader() );
    classLoaders.add ( c.getClass().getClassLoader() );
    classLoaders.add ( AtomikosJmsConnectionProxy.class.getClassLoader() );
View Full Code Here

    sessions.clear ();
  }
 
  public static Reapable newInstance ( XAConnection c, XATransactionalResource jmsTransactionalResource , SessionHandleStateChangeListener owner , ConnectionPoolProperties props )
  {
     Reapable ret = null;
    
        AtomikosJmsConnectionProxy proxy = new AtomikosJmsConnectionProxy ( c , jmsTransactionalResource , owner , props );
        Set interfaces = PropertyUtils.getAllImplementedInterfaces ( c.getClass() );
        interfaces.add ( Reapable.class );
        //see case 24532
View Full Code Here

  }

  protected Reapable doCreateConnectionProxy ( HeuristicMessage hmsg ) throws CreateConnectionException
  {
    Reapable ret = null;
    if ( canBeRecycledForCallingThread() ) {
      if ( Configuration.isDebugLoggingEnabled() ) Configuration.logDebug ( this + ": reusing existing proxy for thread..." );
      ret = getCurrentConnectionProxy();
      DynamicProxy dproxy = ( DynamicProxy ) ret;
      AtomikosThreadLocalConnection previous = (AtomikosThreadLocalConnection) dproxy.getInvocationHandler();
View Full Code Here

  }

  public boolean isAvailable() {
    boolean ret = true;

    Reapable handle = getCurrentConnectionProxy();
    if ( handle != null ) {
      DynamicProxy dproxy = ( DynamicProxy ) handle;
      AtomikosThreadLocalConnection previous = (AtomikosThreadLocalConnection) dproxy.getInvocationHandler();
      ret = previous.isNoLongerInUse();
    }
View Full Code Here

    return erroneous;
  }

  public boolean isInTransaction ( CompositeTransaction ct ) {
    boolean ret = false;
    Reapable handle = getCurrentConnectionProxy();
    if ( handle != null ) {
      DynamicProxy dproxy = ( DynamicProxy ) handle;
      AtomikosThreadLocalConnection previous = (AtomikosThreadLocalConnection) dproxy.getInvocationHandler();
      ret = previous.isInTransaction ( ct );
    }
View Full Code Here

  }
 
  public boolean canBeRecycledForCallingThread()
  {
    boolean ret = false;
    Reapable handle = getCurrentConnectionProxy();
    if ( handle != null ) {
       CompositeTransactionManager ctm = Configuration
             .getCompositeTransactionManager ();
       CompositeTransaction ct = null;
       if ( ctm != null ) ct = ctm.getCompositeTransaction ();
View Full Code Here

    return sessionHandleState.isActiveInTransaction ( ct );
  }

  public static Reapable newInstance ( Connection c , SessionHandleState sessionHandleState , HeuristicMessage hmsg )
  {
    Reapable ret = null;
        AtomikosConnectionProxy proxy = new AtomikosConnectionProxy(c, sessionHandleState , hmsg );
        Set interfaces = PropertyUtils.getAllImplementedInterfaces ( c.getClass() );
        interfaces.add ( Reapable.class );
        //see case 24532
        interfaces.add ( DynamicProxy.class );
View Full Code Here

  }

  protected Reapable doCreateConnectionProxy ( HeuristicMessage hmsg ) throws CreateConnectionException
  {
    Reapable ret = null;
    if ( canBeRecycledForCallingThread() ) {
      if ( LOGGER.isDebugEnabled() ) LOGGER.logDebug ( this + ": reusing existing proxy for thread..." );
      ret = getCurrentConnectionProxy();
      DynamicProxy dproxy = ( DynamicProxy ) ret;
      AtomikosThreadLocalConnection previous = (AtomikosThreadLocalConnection) dproxy.getInvocationHandler();
View Full Code Here

  }

  public boolean isAvailable() {
    boolean ret = true;

    Reapable handle = getCurrentConnectionProxy();
    if ( handle != null ) {
      DynamicProxy dproxy = ( DynamicProxy ) handle;
      AtomikosThreadLocalConnection previous = (AtomikosThreadLocalConnection) dproxy.getInvocationHandler();
      ret = previous.isNoLongerInUse();
    }
View Full Code Here

TOP

Related Classes of com.atomikos.datasource.pool.Reapable

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.