-
Notifications
You must be signed in to change notification settings - Fork 699
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Support PITR #661
Support PITR #661
Conversation
Great job! Would you be willing to rebase your changes onto the v4 branch? We are currently working on the development of the v4 branch. You can refer to this documentation: https://tair-opensource.github.io/RedisShake/ |
ref issue: #593 |
有两问题:1.为什么在执行rdb恢复的时候没有检查文件完整性,例如rdb文件可以有crc64校验码,chensum。但我们并没有进行检查 |
cool ! |
我认为你可以不用考虑preamble格式,因为aof annotation和multi part aof都是在redis 7.0中release的,因此在7.0中,一旦开启preamble,那么只有base aof是rdb格式,incr aof依然是传统的resp格式。所以,你需要做的,就是支持multi part aof的增量文件按时间点闪回就好了(base文件如果有就全部回放)。 |
对于用户给的aof文件我们是否需要进行完整性检查,在写入前对文件的命令、格式进行check。目前代码似乎就是读取然后解析命令,然后写入,在解析途中遇到问题会报一个warnning。这是因为出于性能原因考虑吗,完整check一次文件太浪费时间? |
可以暂时不考虑,因为aof没有rdb那样的checksum,想要校验的话只能从头捋一遍。 PITR时一般木标redis都是空实例,这个时候如果PITR中途失败了shake直接打印错误日志并退出就好,用户可以选择稍后flushall目标redis再使用正确的备份集重试PITR |
2228f6b
to
5ae0821
Compare
看v4版目前没有了fliter,是打算后续采用acl 命令来做吗 |
这个:https://tair-opensource.github.io/RedisShake/zh/function/introduction.html |
@bug-superman 在PR顶部描述下你具体做了哪些改动,引入了什么功能、新增了什么配置、具体用法更新到使用文档。处理下test失败。 |
0b28809
to
f577f29
Compare
c5bac8b
to
6235dfe
Compare
@suxb201 你可以看下这个PR还有没有其他的问题。 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
7de1d76
to
cd2c4b4
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
🎉 |
@Exile-Twilight 是的,不应该限制。 |
此pr在RedisShake的sync模块中增加了aof恢复数据的功能(增加了aof_reader),提供两个功能:
1、支持将任意合法的AOF(redis 7.0之前的single AOF和redis 7.0之后的multi part AOF)回放到目标redis
2、对于redis 7.0之后产生的AOF,如果AOF中具有timestamp annotation,则在回放时支持按时间点过滤能力
ref issue: #593