A Go library and CLI tool for parsing, analyzing, and generating Redis RDB files for memory analysis and data conversion.
rdb is a Go implementation of a Redis RDB file parser designed for secondary development and in-depth memory analysis. It enables developers and administrators to inspect, convert, and analyze Redis database snapshots programmatically or via a command-line interface. The tool focuses on providing a fast, reliable, and extensible toolkit for Redis data introspection, prioritizing performance and developer flexibility.
Redis administrators and developers who need to programmatically analyze Redis memory usage, convert RDB files, or integrate RDB parsing into Go applications. It is also suitable for DevOps engineers performing Redis database forensics and optimization.
Developers choose rdb for its comprehensive feature set including memory reporting, flame graph visualization, and advanced filtering, combined with the performance benefits of a Go implementation. Its dual nature as both a CLI tool and a programmable library offers unique flexibility compared to parser-only alternatives.
Golang implemented Redis RDB parser for secondary development and memory analysis
Open-Awesome is built by the community, for the community. Submit a project, suggest an awesome list, or help improve the catalog on GitHub.
Generates detailed CSV reports per key and interactive flame graphs to visualize memory consumption by key patterns, as shown in the memory report and flame graph sections.
Converts RDB files to JSON or AOF formats with options for concurrent processing and metadata inclusion, evidenced by the json and aof conversion examples.
Supports regex, size ranges, and expiration time filters for precise key extraction, detailed in the regex, size, and expire filter sections.
Benchmarks show fast speeds, such as 133.12 MB/s for memory reports on a 1.3 GB file, highlighting efficiency for large RDB files.
Functions as both a command-line tool and a Go library for custom parsing and RDB generation, demonstrated in the customize usage and generate RDB file sections.
Only supports RDB versions up to 12 (Redis 7.2), which may exclude older deployments or future Redis updates, as admitted in the README.
Relies on CLI and web-based flame graphs, lacking a native graphical interface that could simplify analysis for non-technical users.
Using it as a library requires Go expertise and understanding of the API, which can be a barrier for developers not familiar with Go.
Memory usage is estimated from RDB encoded size, which may not perfectly match actual Redis memory consumption, potentially leading to inaccuracies in analysis.