Package org.jboss.jms.wireformat

Examples of org.jboss.jms.wireformat.ClientDelivery


         // We send the message to the client on the current thread. The message is written onto the
         // transport and then the thread returns immediately without waiting for a response.

         Client callbackClient = callbackHandler.getCallbackClient();

         ClientDelivery del = new ClientDelivery(message, id, deliveryId, ref.getDeliveryCount());

         Callback callback = new Callback(del);

         try
         {
View Full Code Here


   {
      Object parameter = callback.getParameter();

      if (parameter instanceof ClientDelivery)
      {
         ClientDelivery dr = (ClientDelivery)parameter;
         
         Message msg = dr.getMessage();
        
         MessageProxy proxy = JBossMessage.
            createThinDelegate(dr.getDeliveryId(), (JBossMessage)msg, dr.getDeliveryCount());

         MessageCallbackHandler handler =
            (MessageCallbackHandler)callbackHandlers.get(new Integer(dr.getConsumerId()));

         if (handler == null)
         {
            // This should never happen since we wait for all deliveries to arrive before closing
            // the consumer
View Full Code Here

    *
    * @param message The message
    */
   public void handleMessage(final Object message, CallbackManager cbManager) throws Exception
   {
      ClientDelivery del = (ClientDelivery)message;
     
      JBossMessage msg = (JBossMessage)del.getMessage();
     
      MessageProxy proxy = JBossMessage.
         createThinDelegate(del.getDeliveryId(), (JBossMessage)msg, del.getDeliveryCount());
     
      JBossDestination dest =(JBossDestination) proxy.getJMSDestination();
     
      // If the message received is a direct destination (MessageSucker), and this Consumer is not a MessageSucker.. then we need to replace the destination
      if (dest.isDirect() && !this.consumerDelegate.getDestination().isDirect())
View Full Code Here

   {
      Object parameter = callback.getParameter();

      if (parameter instanceof ClientDelivery)
      {
         ClientDelivery dr = (ClientDelivery)parameter;
         
         ClientConsumer handler =
            (ClientConsumer)callbackHandlers.get(dr.getConsumerId());

         if (handler == null)
         {
            // This should never happen since we wait for all deliveries to arrive before closing
            // the consumer
View Full Code Here

     if (trace) { log.trace(this + " performing delivery for " + ref); }

      // We send the message to the client on the current thread. The message is written onto the
      // transport and then the thread returns immediately without waiting for a response.

      ClientDelivery del = new ClientDelivery(ref.getMessage(), consumer.getID(), deliveryID, ref.getDeliveryCount());

      Callback callback = new Callback(del);

      try
      {
View Full Code Here

    *
    * @param message The message
    */
   public void handleMessage(final Object message) throws Exception
   {
      ClientDelivery del = (ClientDelivery)message;
     
      JBossMessage msg = (JBossMessage)del.getMessage();
     
      MessageProxy proxy = JBossMessage.
         createThinDelegate(del.getDeliveryId(), (JBossMessage)msg, del.getDeliveryCount());
     
      JBossDestination dest =(JBossDestination) proxy.getJMSDestination();
     
      // If the message received is a direct destination (MessageSucker), and this Consumer is not a MessageSucker.. then we need to replace the destination
      if (dest.isDirect() && !this.consumerDelegate.getDestination().isDirect())
View Full Code Here

     if (trace) { log.trace(this + " performing delivery for " + ref); }

      // We send the message to the client on the current thread. The message is written onto the
      // transport and then the thread returns immediately without waiting for a response.

      ClientDelivery del = new ClientDelivery(ref.getMessage(), consumer.getID(), deliveryID, ref.getDeliveryCount());

      Callback callback = new Callback(del);

      try
      {
View Full Code Here

    *
    * @param message The message
    */
   public void handleMessage(final Object message) throws Exception
   {
      ClientDelivery del = (ClientDelivery)message;
     
      Message msg = del.getMessage();
     
      MessageProxy proxy = JBossMessage.
         createThinDelegate(del.getDeliveryId(), (JBossMessage)msg, del.getDeliveryCount());

      //TODO - we temporarily need to execute on a different thread to avoid a deadlock situation in
      //       failover where a message is sent then the valve is locked, and the message send cause
      //       a message delivery back to the same client which tries to ack but can't get through
      //       the valve. This won't be necessary when we move to a non blocking transport
View Full Code Here

    *
    * @param message The message
    */
   public void handleMessage(final Object message) throws Exception
   {
      ClientDelivery del = (ClientDelivery)message;
     
      JBossMessage msg = (JBossMessage)del.getMessage();
     
      MessageProxy proxy = JBossMessage.
         createThinDelegate(del.getDeliveryId(), (JBossMessage)msg, del.getDeliveryCount());
     
      JBossDestination dest =(JBossDestination) proxy.getJMSDestination();
     
      // If the message received is a direct destination (MessageSucker), and this Consumer is not a MessageSucker.. then we need to replace the destination
      if (dest.isDirect() && !this.consumerDelegate.getDestination().isDirect())
View Full Code Here

     if (trace) { log.trace(this + " performing delivery for " + ref); }

      // We send the message to the client on the current thread. The message is written onto the
      // transport and then the thread returns immediately without waiting for a response.

      ClientDelivery del = new ClientDelivery(ref.getMessage(), consumer.getID(), deliveryID, ref.getDeliveryCount());

      Callback callback = new Callback(del);

      try
      {
View Full Code Here

TOP

Related Classes of org.jboss.jms.wireformat.ClientDelivery

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.