Git Product home page Git Product logo

filebasedcollection's Introduction

FileBasedCollection

The FileBasedCollection is a Java Colelction backed by a file. The file is a binary, compressed file, generated with the Snappy library. The version used here is snappy-java-1.1.2.1.jar.

The FileBasedCollection is a modifiable collection that extends the AbstractCollection and implements Closeable. The FileBasedCollection has an internal store and a chunk size. If the internal store contains more elements then the chunk size, the internal store is swapped to disk. The iterator implements Closeable and runs through the file backing the collection, loading the next n elements. The iterator is auto-closeable. Great care has been taken to clean up data after the iterator, including shut-down hooks, but if the process crashes, the backing file will be left over. This collection is meant for very large collections that can't possibly fit in memory. It has been tested with billions of items and several gigabytes of data. While using the FileBasedCollection during testing, on several occasions the disk was full and needed cleaning. During production the FileBasedCollection proved stable, even under stressful conditions. The FileBasedColelction has been used with external sorting where many instances where created and merged. The performance and memory consumption was very acceptable. The FileBasedCollection can only grow by adding elements to the head. This limits its use to applications where an iterator is sufficient.

filebasedcollection's People

Contributors

reinoutkorbee avatar

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.