Package org.hibernate.transaction

Examples of org.hibernate.transaction.TransactionManagerLookup


    log.debug( "Configuring TreeCache from resource [" + resource + "]" );
    try {
      cache = new org.jboss.cache.TreeCache();
      PropertyConfigurator config = new PropertyConfigurator();
      config.configure( cache, resource );
      TransactionManagerLookup transactionManagerLookup =
          TransactionManagerLookupFactory.getTransactionManagerLookup( properties );
      if ( transactionManagerLookup == null ) {
        throw new CacheException(
            "JBossCache only supports optimisitc locking with a configured " +
            "TransactionManagerLookup (" + Environment.TRANSACTION_MANAGER_STRATEGY + ")"
View Full Code Here


  public Cache buildCache(String regionName, Properties properties) throws CacheException {
    return new TreeCache( getTreeCacheInstance(), regionName, transactionManager );
  }

  public void prepare(Properties properties) throws CacheException {
    TransactionManagerLookup transactionManagerLookup = TransactionManagerLookupFactory.getTransactionManagerLookup(properties);
    if (transactionManagerLookup!=null) {
      transactionManager = transactionManagerLookup.getTransactionManager(properties);
    }
  }
View Full Code Here

    log.debug( "Configuring TreeCache from resource [" + resource + "]" );
    try {
      cache = new org.jboss.cache.TreeCache();
      PropertyConfigurator config = new PropertyConfigurator();
      config.configure( cache, resource );
      TransactionManagerLookup transactionManagerLookup = TransactionManagerLookupFactory.getTransactionManagerLookup(properties);
      if (transactionManagerLookup!=null) {
        cache.setTransactionManagerLookup( new TransactionManagerLookupAdaptor(transactionManagerLookup, properties) );
        transactionManager = transactionManagerLookup.getTransactionManager(properties);
      }
      cache.start();
    }
    catch (Exception e) {
      throw new CacheException(e);
View Full Code Here

    if ( "org.hibernate.transaction.WebSphereExtendedJTATransactionLookup".equals( tmlImplName ) ) {
      return new WebSphereExtendedJtaPlatform();
    }

    try {
      TransactionManagerLookup lookup = (TransactionManagerLookup) registry.getService( ClassLoaderService.class )
          .classForName( tmlImplName )
          .newInstance();
      return new TransactionManagerLookupBridge( lookup, JndiHelper.extractJndiProperties( configVales ) );
    }
    catch ( Exception e ) {
View Full Code Here

     */
    public void start(Settings settings, Properties properties) throws CacheException {
        try {
            // We need our tm, so get it now and avoid doing other work
            // if there is a problem
            TransactionManagerLookup tml = settings.getTransactionManagerLookup();
            TransactionManager tm =  (tml == null ? null : tml.getTransactionManager(properties));

            // We only build caches if *none* were passed in.  Passing in
            // caches counts as a clear statement of exactly what is wanted
            boolean buildCaches = jbcEntityCache == null
                                  && jbcCollectionCache == null
View Full Code Here

     */
    public void start(Settings settings, Properties properties) throws CacheException {
        try {
            // We need our tm, so get it now and avoid doing other work
            // if there is a problem
            TransactionManagerLookup tml = settings.getTransactionManagerLookup();
            TransactionManager tm =  (tml == null ? null : tml.getTransactionManager(properties));

            // We only build caches if *none* were passed in.  Passing in
            // caches counts as a clear statement of exactly what is wanted
            boolean buildCaches = jbcEntityCache == null
                                  && jbcCollectionCache == null
View Full Code Here

      try
      {
         cache = new org.jboss.cache.TreeCache();
         PropertyConfigurator config = new PropertyConfigurator();
         config.configure(cache, resource);
         TransactionManagerLookup transactionManagerLookup = TransactionManagerLookupFactory.getTransactionManagerLookup(properties);
         if (transactionManagerLookup != null)
         {
            cache.setTransactionManagerLookup(new TransactionManagerLookupAdaptor(transactionManagerLookup, properties));
            transactionManager = transactionManagerLookup.getTransactionManager(properties);
         }
         cache.startService();

         if ("OPTIMISTIC".equals(cache.getNodeLockingScheme()))
         {
View Full Code Here

  public Cache buildCache(String regionName, Properties properties) throws CacheException {
    return new TreeCache( getTreeCacheInstance(), regionName, transactionManager );
  }

  public void prepare(Properties properties) throws CacheException {
    TransactionManagerLookup transactionManagerLookup = TransactionManagerLookupFactory.getTransactionManagerLookup(properties);
    if (transactionManagerLookup!=null) {
      transactionManager = transactionManagerLookup.getTransactionManager(properties);
    }
  }
View Full Code Here

    log.debug( "Configuring TreeCache from resource [" + resource + "]" );
    try {
      cache = new org.jboss.cache.TreeCache();
      PropertyConfigurator config = new PropertyConfigurator();
      config.configure( cache, resource );
      TransactionManagerLookup transactionManagerLookup = TransactionManagerLookupFactory.getTransactionManagerLookup(properties);
      if (transactionManagerLookup!=null) {
        cache.setTransactionManagerLookup( new TransactionManagerLookupAdaptor(transactionManagerLookup, properties) );
        transactionManager = transactionManagerLookup.getTransactionManager(properties);
      }
      cache.start();
    }
    catch (Exception e) {
      throw new CacheException(e);
View Full Code Here

    log.debug( "Configuring TreeCache from resource [" + resource + "]" );
    try {
      cache = new org.jboss.cache.TreeCache();
      PropertyConfigurator config = new PropertyConfigurator();
      config.configure( cache, resource );
      TransactionManagerLookup transactionManagerLookup =
          TransactionManagerLookupFactory.getTransactionManagerLookup( properties );
      if ( transactionManagerLookup == null ) {
        throw new CacheException(
            "JBossCache only supports optimisitc locking with a configured " +
            "TransactionManagerLookup (" + Environment.TRANSACTION_MANAGER_STRATEGY + ")"
View Full Code Here

TOP

Related Classes of org.hibernate.transaction.TransactionManagerLookup

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.