github.com/matthewjhe/rdb (go): Package rdb implements a Redis RDB File parser.  The basic use case is very simple, just implements Filter interface and pass it to Parse:  NOTE: RDB file is read sequentially, when we say skips a database, we also need to parse this database's every single key, we just simply skips actions like decompress, unzip ziplist, etc. It is impossible to skips a key without reading its metadata.  Global skip strategy applies to the whole parsing lifetime, it can be overwritten by Filter's Database method, it will be restored when parsing a database completely.  Global skip strategy is set by a ParseOption when rdb.Parse is called:  Database skip strategy applies to a database lifetime, it is set by Filter's Database method, and it can be overwritten by Filter's Key or Type method. Database skip strategy is set to global skip strategy by default.  Type and key skip strategy overwrite database skip strategy. It only applies the key and value which will read next.  By default, rdb uses multiple goroutines to parse keys which would cause keys disorder. If the order of keys is important, use EnableSync ParseOption.  Sometimes we want to abort the parsing process, this can be done by return true when one of the following methods is called: Note that the abort action is taking effect immediately when the function returns.
Keywords: go|rdb|redis