Package org.voltdb.utils.DBBPool

Examples of org.voltdb.utils.DBBPool.BBContainer.discard()


                        }
                        if (validate && saveFile.getCompleted()) {
                            while (saveFile.hasMoreChunks()) {
                                BBContainer cont = saveFile.getNextChunk();
                                if (cont != null) {
                                    cont.discard();
                                }
                            }
                        }
                        partitionIds.removeAll(saveFile.getCorruptedPartitionIds());
                        Snapshot s = snapshots.get(saveFile.getCreateTime());
View Full Code Here


                String msg = "Failed to serialize error for " + ts;
                throw new ServerFaultException(msg, ex);
            }
            bc.b.rewind();
            builder.setError(ByteString.copyFrom(bc.b));
            bc.discard();
        }
       
        // Push dependencies back to the remote partition that needs it
        if (status == Status.OK) {
            for (int i = 0, cnt = result.size(); i < cnt; i++) {
View Full Code Here

                    if (c.b.hasRemaining()) {
                        Thread.yield();
                    }
                }
                while(c.b.hasRemaining());
                c.discard();
                return handle;
            }
        });
    }
View Full Code Here

            m_totalAvailable -= bytesToCopy;

            if (first.b.remaining() == 0) {
                // read an entire block: move it to the empty buffers list
                m_readBuffers.poll();
                first.discard();
            }
        }

        if (bytesCopied > 0) {
            m_globalAvailable.addAndGet(0 - bytesCopied);
View Full Code Here

        int bytesReleased = 0;
        m_isShutdown = true;
        BBContainer c = null;
        while ((c = m_queuedBuffers.poll()) != null) {
            bytesReleased += c.b.remaining();
            c.discard();
        }
        updateQueued(-bytesReleased, false);
        DeferredSerialization ds = null;
        while ((ds = m_queuedWrites.poll()) != null) {
            ds.cancel();
View Full Code Here

        final FastSerializer fds = new FastSerializer();
        int size = 0;
        try {
            final BBContainer c = fds.writeObjectForMessaging(invocation);
            size = c.b.remaining();
            c.discard();
        } catch (final IOException e) {
            throw new RuntimeException(e);
        }
        return size;
    }
View Full Code Here

            LOG.trace("createPartitionedTables :" + tableName);

            VoltTable[] partitioned_tables = createPartitionedTables(tableName, table);
            if (c != null) {
                c.discard();
            }

            // LoadMultipartitionTable -- send data to all ..

            int[] dependencyIds = new int[sites_to_partitions.size()];
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.