FlashDB:An ultra-lightweight embedded database

    FlashDB is an ultra-lightweight embedded database that focuses on providing data storage solutions for embedded products. Different from traditional database based on file system, combines the features of Flash and has strong performance and reliability. And under the premise of ensuring extremely low resource occupation, the service life of Flash should be extended as much as possible.

    • Key-value database: It is a non-relational database that stores data as a collection of key-value pairs, where the key is used as a unique identifier. KVDB has simple operation and strong scalability.
    • Time Series Database: Time Series Database (TSDB), which stores data in time sequence. TSDB data has a timestamp, a large amount of data storage, and high insertion and query performance.

    Nowadays, there are more and more types of IoT products, and the types and total amount of data generated during operation are also increasing. FlashDB provides a variety of data storage solutions, not only has a small resource footprint, but also has a large storage capacity, which is very suitable for IoT products. The following are the main application scenarios:

    • Key-value database:
      • Product parameter storage
      • User configuration information storage
      • Small file management
    • Time Series Database:
      • Record operation log: store operation log of product history, record of abnormal alarm, etc.
    • Very small footprint, ram usage is almost 0;
    • Support multiple partitions, multiple instances. When the amount of data is large, the partition can be refined to reduce the retrieval time;
    • Support wear balance to extend Flash life;
    • Support Power-off protection function, high reliability;
    • Supports two KV types, string and blob, which is convenient for users to operate;
    • Support KV incremental upgrade, after product firmware upgrade, KVDB content also supports automatic upgrade;

    Insert average: 0.37 ms, query average: 0.12 ms

    The project uses the Apache-2.0 open source protocol. For details, please read the contents of the LICENSE file in the project.