Examples of readFromStream()


Examples of org.apache.drill.exec.cache.VectorAccessibleSerializable.readFromStream()

    BatchMetaInfo aggBatchMetaInfo = new BatchMetaInfo();

    while (input.available() > 0) {
      VectorAccessibleSerializable vcSerializable = new VectorAccessibleSerializable(DumpCat.allocator);
      vcSerializable.readFromStream(input);
       VectorContainer vectorContainer = (VectorContainer) vcSerializable.get();

       aggBatchMetaInfo.add(getBatchMetaInfo(vcSerializable));

       if (vectorContainer.getRecordCount() == 0) {
View Full Code Here

Examples of org.apache.drill.exec.cache.VectorAccessibleSerializable.readFromStream()

    VectorAccessibleSerializable vcSerializable = null;

    while (input.available() > 0 && batchNum ++ < targetBatchNum) {
      vcSerializable = new VectorAccessibleSerializable(DumpCat.allocator);
      vcSerializable.readFromStream(input);

      if (batchNum != targetBatchNum) {
        VectorContainer vectorContainer = (VectorContainer) vcSerializable.get();
        vectorContainer.zeroVectors();
      }
View Full Code Here

Examples of org.apache.drill.exec.cache.VectorAccessibleSerializable.readFromStream()

      Path path = new Path(filename);
      assertTrue("Trace file does not exist", fs.exists(path));
      FSDataInputStream in = fs.open(path);

      VectorAccessibleSerializable wrap = new VectorAccessibleSerializable(context.getAllocator());
      wrap.readFromStream(in);
      VectorAccessible container = wrap.get();

        /* Assert there are no selection vectors */
      assertTrue(wrap.getSv2() == null);

View Full Code Here

Examples of org.apache.drill.exec.cache.VectorAccessibleSerializable.readFromStream()

    BatchMetaInfo aggBatchMetaInfo = new BatchMetaInfo();

    while (input.available() > 0) {
      VectorAccessibleSerializable vcSerializable = new VectorAccessibleSerializable(DumpCat.allocator);
      vcSerializable.readFromStream(input);
      VectorContainer vectorContainer = (VectorContainer) vcSerializable.get();

      aggBatchMetaInfo.add(getBatchMetaInfo(vcSerializable));

      if (vectorContainer.getRecordCount() == 0) {
View Full Code Here

Examples of org.apache.drill.exec.cache.VectorAccessibleSerializable.readFromStream()

    VectorAccessibleSerializable vcSerializable = null;

    while (input.available() > 0 && batchNum ++ < targetBatchNum) {
      vcSerializable = new VectorAccessibleSerializable(DumpCat.allocator);
      vcSerializable.readFromStream(input);

      if (batchNum != targetBatchNum) {
        VectorContainer vectorContainer = (VectorContainer) vcSerializable.get();
        vectorContainer.zeroVectors();
      }
View Full Code Here

Examples of org.apache.drill.exec.cache.VectorAccessibleSerializable.readFromStream()

      inputStream = fs.open(path);
    }
    VectorAccessibleSerializable vas = new VectorAccessibleSerializable(allocator);
    Stopwatch watch = new Stopwatch();
    watch.start();
    vas.readFromStream(inputStream);
    VectorContainer c =  vas.get();
//    logger.debug("Took {} us to read {} records", watch.elapsed(TimeUnit.MICROSECONDS), c.getRecordCount());
    spilledBatches--;
    currentContainer.zeroVectors();
    Iterator<VectorWrapper<?>> wrapperIterator = c.iterator();
View Full Code Here

Examples of org.apache.drill.exec.cache.VectorAccessibleSerializable.readFromStream()

      inputStream = fs.open(path);
    }
    VectorAccessibleSerializable vas = new VectorAccessibleSerializable(allocator);
    Stopwatch watch = new Stopwatch();
    watch.start();
    vas.readFromStream(inputStream);
    VectorContainer c =  vas.get();
//    logger.debug("Took {} us to read {} records", watch.elapsed(TimeUnit.MICROSECONDS), c.getRecordCount());
    spilledBatches--;
    currentContainer.zeroVectors();
    Iterator<VectorWrapper<?>> wrapperIterator = c.iterator();
View Full Code Here

Examples of org.codehaus.activemq.util.BitArray.readFromStream()

     */
    public void buildPacket(Packet p, DataInput dataIn) throws IOException {
        AbstractPacket packet = (AbstractPacket)p;
        packet.setId(readUTF(dataIn));
        BitArray ba = packet.getBitArray();
        ba.readFromStream(dataIn);
        packet.setReceiptRequired(ba.get(AbstractPacket.RECEIPT_REQUIRED_INDEX));
        if (ba.get(AbstractPacket.BROKERS_VISITED_INDEX)){
            int visitedLen = dataIn.readShort();
            for (int i =0; i < visitedLen; i++){
                packet.addBrokerVisited(dataIn.readUTF());
View Full Code Here

Examples of org.codehaus.activemq.util.BitArray.readFromStream()

        ack.setConsumerId(dataIn.readUTF());
        ack.setMessageID(dataIn.readUTF());
        ack.setTransactionId(dataIn.readUTF());
       
        BitArray ba = new BitArray();
        ba.readFromStream(dataIn);
        ack.setMessageRead(ba.get(MessageAck.MESSAGE_READ_INDEX));
        ack.setXaTransacted(ba.get(MessageAck.XA_TRANSACTED_INDEX));
        ack.setPersistent(ba.get(MessageAck.PERSISTENT_INDEX));
        ack.setDestination(ActiveMQDestination.readFromStream(dataIn));
    }
View Full Code Here

Examples of org.codehaus.activemq.util.BitArray.readFromStream()

     */
    public void buildPacket(Packet p, DataInput dataIn) throws IOException {
        AbstractPacket packet = (AbstractPacket) p;
        packet.setId(dataIn.readShort());
        BitArray ba = packet.getBitArray();
        ba.readFromStream(dataIn);
        packet.setReceiptRequired(ba.get(AbstractPacket.RECEIPT_REQUIRED_INDEX));
        if (ba.get(AbstractPacket.BROKERS_VISITED_INDEX)) {
            int visitedLen = dataIn.readShort();
            for (int i = 0;i < visitedLen;i++) {
                packet.addBrokerVisited(dataIn.readUTF());
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.