Examples of Future


Examples of org.jboss.messaging.util.Future

         // session is closed from within the MessageListener.onMessage(), for example), so no need
         // to register another Closer (see http://jira.jboss.org/jira/browse/JBMESSAGING-542)
         return;
      }

      Future result = new Future();
     
      try
      {
         sessionExecutor.execute(new Closer(result));

         if (trace) { log.trace(this + " blocking wait for Closer execution"); }
         result.getResult();
         if (trace) { log.trace(this + " got Closer result"); }
      }
      catch (InterruptedException e)
      {
         log.warn("Thread interrupted", e);
View Full Code Here

Examples of org.jboss.messaging.util.Future

      return true;
   }
       
   public int getRefCount()
   {
      Future result = new Future();
     
      //This needs to be run on a different thread to the one used by JGroups to deliver the message
      //to avoid deadlock
      try
      {
         this.executor.execute(new GetRefCountRunnable(result));
      }
      catch (InterruptedException e)
      {
         log.warn("Thread interrupted", e);
      }

      return ((Integer)result.getResult()).intValue();
   }
View Full Code Here

Examples of org.jboss.messaging.util.Future

         // session is closed from within the MessageListener.onMessage(), for example), so no need
         // to register another Closer (see http://jira.jboss.org/jira/browse/JBMESSAGING-542)
         return;
      }

      Future result = new Future();

      sessionExecutor.execute(new Closer(result));

      if (trace) { log.trace(this + " blocking wait for Closer execution"); }
      result.getResult();
      if (trace) { log.trace(this + " got Closer result"); }
   }
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.