Class LocalFileStore

  • All Implemented Interfaces:

    public final class LocalFileStore
    extends LocalBlockStore
    Stores blocks in local files.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      Block createBlock​(java.lang.String blockId)
      Creates a new block.
      boolean deleteBlock​(java.lang.String blockId)
      Removes the file that the target block is stored.
      void writeBlock​(Block block)
      Writes a committed block to this store.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Method Detail

      • createBlock

        public Block createBlock​(java.lang.String blockId)
        Description copied from interface: BlockStore
        Creates a new block. A stale data created by previous failed task should be handled during the creation of new block.
        blockId - the ID of the block to create.
        the created block.
      • writeBlock

        public void writeBlock​(Block block)
        Writes a committed block to this store.
        block - the block to write.
        BlockWriteException - if fail to write.
      • deleteBlock

        public boolean deleteBlock​(java.lang.String blockId)
        Removes the file that the target block is stored.
        blockId - of the block.
        whether the block exists or not.