async streaming parser for redis RDB dumps
npm install rdb-parser
var rdb = require'rdb-parser';console.logrdbtypes;var parser = ;parseron'entity'console.loge;;parseron'error'throw err;;parseron'end'console.log'done';;processstdinpipeparser;processstdinresume;
rdb-parser aims for complete coverage of rdb dumps.
It is close to complete at this point supporting all entity types, but may be missing one or two of the variety of encoding variations that redis can use. And it has had limited testing.
npm test parses a (rather small) .rdb file designed to exercise a variety of types and encodings.
If you have a dump that
rdb-parser cannot handle please report an issue and/or contribute the dump.
(The MIT License)
Copyright (c) 2011-2012 Carlos Guerreiro, perceptiveconstructs.com
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.