Examples of basicCancel()


Examples of com.rabbitmq.client.Channel.basicCancel()

        try {
            String classname = subscriber.getClass().getName();
            String queueName = UUID.nameUUIDFromBytes(classname.getBytes()).toString();
            Ternary<String, Channel, EventSubscriber> queueDetails = s_subscribers.get(queueName);
            Channel channel = queueDetails.second();
            channel.basicCancel(queueName);
            s_subscribers.remove(queueName, queueDetails);
        } catch (Exception e) {
            throw new EventBusException("Failed to unsubscribe from event bus due to " + e.getMessage());
        }
    }
View Full Code Here

Examples of com.rabbitmq.client.Channel.basicCancel()

        boolean succeeded = false;
        final String consumer = (String) parameters[0];
        final Channel channel = AmqpOperationFactory.this.amqpDriver.getChannel (consumer);
        if (channel != null) {
          try {
            channel.basicCancel (consumer);
            succeeded = true;
          } catch (final IOException e) {
            AmqpOperationFactory.this.exceptions.traceIgnoredException (e);
          }
        }
View Full Code Here

Examples of com.rabbitmq.client.Channel.basicCancel()

    assertSame(con, same);
    channel.close();

    when(mockConnection1.isOpen()).thenReturn(false);
    when(mockChannel.isOpen()).thenReturn(false); // force a connection refresh
    channel.basicCancel("foo");
    channel.close();

    Connection notSame = connectionFactory.createConnection();
    assertNotSame(con, notSame);
    assertSame(con, closed.get());
View Full Code Here

Examples of eu.mosaic_cloud.drivers.queue.amqp.AmqpDriver.basicCancel()

        token = clop.getToken ();
        consumer = clop.getConsumer ();
        AmqpStub.logger.trace ("AmqpStub - Received request for CANCEL"); // $NON-NLS-1$
        // NOTE: execute operation
        final DriverOperationFinishedHandler cancelHandler = new DriverOperationFinishedHandler (token, session);
        resultBool = driver.basicCancel (consumer, cancelHandler);
        cancelHandler.setDetails (AmqpOperations.CANCEL, resultBool);
        break;
      case ACK :
        final AmqpPayloads.Ack aop = (Ack) message.payload;
        token = aop.getToken ();
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.