Package org.jboss.ejb

Examples of org.jboss.ejb.InstancePool.free()


            ctx.unlock();
           
            // Still free? Not free if create() was called successfully
            if (ctx.getId() == null)
            {
               pool.free(ctx);
            }
         }
      }
   }
  
View Full Code Here


                  // if removed, remove from cache
                  if (ctx.getId() == null)
                  {
                     // Remove from cache
                     cache.remove(methodID);
                     pool.free(ctx);
                  }
               }
               finally
               {
                  lock.releaseSync();
View Full Code Here

      finally
      {
         mi.setEnterpriseContext(null);
         // If an instance was created, return it to the pool
         if( ctx != null )
            pool.free(ctx);
      }

   }

   public Object invoke(final Invocation mi) throws Exception
View Full Code Here

         EnterpriseBeanPolicyContextHandler.setEnterpriseBean(null);
        
         // Return context
         if (mi.getEnterpriseContext() != null)
         {
            pool.free(((EnterpriseContext) mi.getEnterpriseContext()));
         }
         else
         {
            pool.discard(ctx);
         }
View Full Code Here

         EnterpriseBeanPolicyContextHandler.setEnterpriseBean(null);
        
         // Return context
         if (mi.getEnterpriseContext() != null)
         {
            pool.free((EnterpriseContext) mi.getEnterpriseContext());
         }
         else
         {
            pool.discard(ctx);
         }
View Full Code Here

      else
      {
         // if we get to here with an Exception, we have an application exception.
         // EJB 2.1 section 18.3.1 says we can keep the instance. We need to return
         // our instance to the instance pool so we dont get a memory leak. 
         pool.free(ctx);        
      }
     
      throw exception;
   }
View Full Code Here

            ctx.unlock();
           
            // Still free? Not free if create() was called successfully
            if (ctx.getId() == null)
            {
               pool.free(ctx);
            }
         }
      }
   }
  
View Full Code Here

                  // if removed, remove from cache
                  if (ctx.getId() == null)
                  {
                     // Remove from cache
                     cache.remove(methodID);
                     pool.free(ctx);
                  }
               }
               finally
               {
                  lock.releaseSync();
View Full Code Here

/*     */
/* 156 */         ctx.unlock();
/*     */
/* 159 */         if (ctx.getId() == null)
/*     */         {
/* 161 */           pool.free(ctx);
/*     */         }
/*     */       }
/*     */     }
/*     */   }
/*     */
View Full Code Here

/* 135 */       AllowedOperationsAssociation.popInMethodFlag();
/* 136 */       EnterpriseBeanPolicyContextHandler.setEnterpriseBean(null);
/*     */
/* 139 */       if (mi.getEnterpriseContext() != null)
/*     */       {
/* 141 */         pool.free((EnterpriseContext)mi.getEnterpriseContext());
/*     */       }
/*     */       else
/*     */       {
/* 145 */         pool.discard(ctx);
/*     */       }
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.