GithubHelp home page GithubHelp logo

storage-engine-rust's People

Contributors

rishavbhowmik avatar

Watchers

 avatar

storage-engine-rust's Issues

Test Open storage file

  • Create sample storage files
  • Copy sample file to temp_dir
  • test write, read, delete repetitively and verify file states

No seek outside file size

Currently, if the 4 blocks have been written, the on reading 5th block (non existent block), the function read seeks read pointer outside the file bound, which is an illegal operation.

Expectation:

  • maintain index of last block in the storage
  • on request to read block index greater than max block index, return empty vector.

Open existing Storage File

So far we support creating for new storage file and initialisation of storage header and then read/write blocks. But now we need to open existing storage file, read storage header, search empty blocks and then read/write blocks.

ToDo

  • implement Storage.get_storage_header - read data set using Storage.get_storage_header
  • implement Storage.read_storage_block_headers - count total used blocks and update Storage.free_blocks for indexing empty blocks
  • implement Storage::open - opens existing StorageFile - use Storage::open_file_writer with truncate false
    // TODO: Implement

IO Cycle

  • Atomic Lock
  • Serve Reads
  • Allocate blocks for writes
  • Atomic Lock
  • Write to allocated blocks
  • Serve Delete requests
  • Atomic Lock

Delete Block

Support Delete block operation

  • set block data size to 0 and add block to empty blocks index
  • set all data bytes to 0 if hard_delete set to true

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.