Examples of DeliveryState


Examples of org.apache.qpid.proton.amqp.transport.DeliveryState

                ack.setLastMessageId(md.getMessage().getMessageId());
                ack.setMessageCount(1);
                ack.setAckType((byte) ackType);
                ack.setDestination(md.getDestination());

                DeliveryState remoteState = delivery.getRemoteState();
                if (remoteState != null && remoteState instanceof TransactionalState) {
                    TransactionalState s = (TransactionalState) remoteState;
                    long txid = toLong(s.getTxnId());
                    LocalTransactionId localTxId = new LocalTransactionId(connectionId, txid);
                    ack.setTransactionId(localTxId);
View Full Code Here

Examples of org.apache.qpid.proton.amqp.transport.DeliveryState

        }

        @Override
        public void onDelivery(Delivery delivery) throws Exception {
            MessageDispatch md = (MessageDispatch) delivery.getContext();
            DeliveryState state = delivery.getRemoteState();

            if (state instanceof TransactionalState) {
                TransactionalState txState = (TransactionalState) state;
                if (txState.getOutcome() instanceof DeliveryState) {
View Full Code Here

Examples of org.apache.qpid.proton.amqp.transport.DeliveryState

    abstract AmqpLink link();

    boolean watchingRemoteStateChange;
    public void onRemoteStateChange(final Callback<DeliveryState> cb) {
        watchingRemoteStateChange = true;
        final DeliveryState original = delivery.getRemoteState();
        addWatch(new Watch() {
            @Override
            public boolean execute() {
                if (original == null) {
                    if( delivery.getRemoteState()!=null ) {
                        cb.onSuccess(delivery.getRemoteState());
                        watchingRemoteStateChange = false;
                        return true;
                    }
                } else {
                    if( !original.equals(delivery.getRemoteState()) ) {
                        cb.onSuccess(delivery.getRemoteState());
                        watchingRemoteStateChange = false;
                        return true;
                    }
                }
View Full Code Here

Examples of org.apache.qpid.proton.amqp.transport.DeliveryState

                ack.setLastMessageId(md.getMessage().getMessageId());
                ack.setMessageCount(1);
                ack.setAckType((byte) ackType);
                ack.setDestination(md.getDestination());

                DeliveryState remoteState = delivery.getRemoteState();
                if (remoteState != null && remoteState instanceof TransactionalState) {
                    TransactionalState s = (TransactionalState) remoteState;
                    long txid = toLong(s.getTxnId());
                    LocalTransactionId localTxId = new LocalTransactionId(connectionId, txid);
                    ack.setTransactionId(localTxId);
View Full Code Here

Examples of org.apache.qpid.proton.amqp.transport.DeliveryState

        }

        @Override
        public void onDelivery(Delivery delivery) throws Exception {
            MessageDispatch md = (MessageDispatch) delivery.getContext();
            DeliveryState state = delivery.getRemoteState();

            if (state instanceof TransactionalState) {
                TransactionalState txState = (TransactionalState) state;
                if (txState.getOutcome() instanceof DeliveryState) {
View Full Code Here

Examples of org.apache.qpid.proton.amqp.transport.DeliveryState

            messageId.setProducerId(producerId);
            messageId.setProducerSequenceId(messageIdGenerator.getNextSequenceId());

            LOG.trace("Inbound Message:{} from Producer:{}", message.getMessageId(), producerId + ":" + messageId.getProducerSequenceId());

            DeliveryState remoteState = delivery.getRemoteState();
            if (remoteState != null && remoteState instanceof TransactionalState) {
                TransactionalState s = (TransactionalState) remoteState;
                long txid = toLong(s.getTxnId());
                message.setTransactionId(new LocalTransactionId(connectionId, txid));
            }
View Full Code Here

Examples of org.apache.qpid.proton.amqp.transport.DeliveryState

    Status getStatus(Tracker tracker)
    {
        Delivery delivery = getDelivery(tracker);
        if (delivery != null)
        {
            DeliveryState state = delivery.getRemoteState();
            if (state != null)
            {
                return getStatus(state);
            }
            else if (delivery.remotelySettled() || delivery.isSettled())
View Full Code Here

Examples of org.apache.qpid.proton.amqp.transport.DeliveryState

      ServerMessage message = (ServerMessage) delivery.getContext();

      boolean preSettle = sender.getRemoteSenderSettleMode() == SenderSettleMode.SETTLED;


      DeliveryState remoteState = delivery.getRemoteState();

      if (remoteState != null)
      {
         if (remoteState instanceof Accepted)
         {
View Full Code Here

Examples of org.apache.qpid.proton.amqp.transport.DeliveryState

            {
                _status = _disp2status(_delivery.getRemoteState());
            }
            else if (_delivery.remotelySettled())
            {
                DeliveryState disp = _delivery.getLocalState();
                if (disp == null) {
                    _status = Status.SETTLED;
                } else {
                    _status = _disp2status(_delivery.getLocalState());
                }
View Full Code Here

Examples of org.apache.qpid.proton.amqp.transport.DeliveryState

    abstract AmqpLink link();

    boolean watchingRemoteStateChange;
    public void onRemoteStateChange(final Callback<DeliveryState> cb) {
        watchingRemoteStateChange = true;
        final DeliveryState original = delivery.getRemoteState();
        addWatch(new Watch() {
            @Override
            public boolean execute() {
                if (original == null) {
                    if( delivery.getRemoteState()!=null ) {
                        cb.onSuccess(delivery.getRemoteState());
                        watchingRemoteStateChange = false;
                        return true;
                    }
                } else {
                    if( !original.equals(delivery.getRemoteState()) ) {
                        cb.onSuccess(delivery.getRemoteState());
                        watchingRemoteStateChange = false;
                        return true;
                    }
                }
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.