Examples of CursorRequestMessage


Examples of org.sdnplatform.sync.thrift.CursorRequestMessage

        private final int cursorId;
        Iterator<KeyedValues> currentChunk;
       
        public RemoteIterator() {
            CursorRequestMessage crm = getCRM();
            crm.setStoreName(storeName);
            SyncMessage bsm = new SyncMessage(MessageType.CURSOR_REQUEST);
            bsm.setCursorRequest(crm);
            SyncReply reply;
            try {
                reply = getReply(crm.getHeader().getTransactionId(),
                                 bsm);
            } catch (SyncException e) {
                throw new SyncRuntimeException(e);
            }
            this.cursorId = reply.getIntValue();
View Full Code Here

Examples of org.sdnplatform.sync.thrift.CursorRequestMessage

            throw new UnsupportedOperationException();
        }

        @Override
        public void close() {
            CursorRequestMessage crm = getCRM();
            crm.setCursorId(cursorId);
            crm.setClose(true);
            SyncMessage bsm = new SyncMessage(MessageType.CURSOR_REQUEST);
            bsm.setCursorRequest(crm);
            try {
                getReply(crm.getHeader().getTransactionId(),
                         bsm);
            } catch (SyncException e) {
                throw new SyncRuntimeException(e);
            }
        }
View Full Code Here

Examples of org.sdnplatform.sync.thrift.CursorRequestMessage

                throw new SyncRuntimeException(e);
            }
        }
       
        private Iterator<KeyedValues> getChunk() {
            CursorRequestMessage crm = getCRM();
            crm.setCursorId(cursorId);
            SyncMessage bsm = new SyncMessage(MessageType.CURSOR_REQUEST);
            bsm.setCursorRequest(crm);

            SyncReply reply;
            try {
                reply = getReply(crm.getHeader().getTransactionId(),
                                              bsm);
            } catch (SyncException e) {
                throw new SyncRuntimeException(e);
            }
            if (reply.getKeyedValues() == null ||
View Full Code Here

Examples of org.sdnplatform.sync.thrift.CursorRequestMessage

            return reply.getKeyedValues().iterator();
        }

        private CursorRequestMessage getCRM() {
            CursorRequestMessage crm = new CursorRequestMessage();
            AsyncMessageHeader header = new AsyncMessageHeader();
            header.setTransactionId(syncManager.getTransactionId());
            crm.setHeader(header);
            return crm;
        }
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.