在C#中解码mysqlbinlog [英] decode mysqlbinlog in C#

查看:504
本文介绍了在C#中解码mysqlbinlog的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

MySQL将所有更改保存到名为二进制日志的二进制文件中. MySQL提供了一个名为mysqlbinlog的解码器来解码这些文件.我想,如果我想直接从应用程序解析此日志文件,则需要找到一种方法,例如使用C#自己对它进行解码.

我知道我是否可以使用SHOW BINLOG事件.但是,解析文件对我来说是一个更好的解决方案.

你们中有人做过吗?有什么建议吗?

解决方案

查看 mysqlbinlog -工具代码可能会有用.此外,该工具的依赖项可以在此处

MySQL saves all changes to the database in a binary file called binary log. MySQL provides a decoder called mysqlbinlog to decode these files. I thought if I wanted to parse this log file directly from an application then I need to find a way to decode it myself using C# for instance.

I know if I had the privilege I could use SHOW BINLOG EVENTS. However, parsing the file would be a better solution for me.

Has any of you done that before? Any suggestions?

解决方案

A look into the mysqlbinlog-tool code might be useful. Additionally, the dependencies of that tool are available here

这篇关于在C#中解码mysqlbinlog的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆