Package org.apache.spark.storage

Examples of org.apache.spark.storage.FileSegment.offset()


      }
      int len = (int) length;
      ctx.write((new FileHeader(len, blockId)).buffer());
      try {
        ctx.write(new DefaultFileRegion(new FileInputStream(file)
          .getChannel(), fileSegment.offset(), fileSegment.length()));
      } catch (Exception e) {
          LOG.error("Exception: ", e);
      }
    } else {
      ctx.write(new FileHeader(0, blockId).buffer());
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.