Skip to content
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

Backup failed 无任何错误提示,打印go-mysql日志,确实有接收到update_row协议包,还有哪些可能导致回滚语句入库失败? #666

Open
huangpeng38869288 opened this issue Aug 3, 2024 · 1 comment

Comments

@huangpeng38869288
Copy link

相关版本
goinception-1.3.0
go-mysql-v0.0.0-20200114082439-6d0d8d3a982e

执行sql
update user_0708 set login_num=50 where id =10043;

问题描述
间歇性回滚语句获取失败,是好是坏,感觉是不是有超时什么的机制,服务器响应慢,好像生成回滚语句就无法入库,提示” Backup failed “ 无任何错误提示,空的
单独启动goinception
image
archery也试过
image

go-mysql打了日志,确实接收到了update_row的网络包
从49,修改为值50
image

@huangpeng38869288
Copy link
Author

找到了具体原因,由于我这边的mysql类似proxy形式,并不是真实mysql服务端,goinception提交sql时,autocommit设置为自动提交,会导致执行一条sql语句我这边就会关闭数据库连接,下一次的connection_id就不一样了。
image

请问出于什么样考虑,事务是分别提交而不是统一最后执行完再提交? 有没有地方能否修改这个配置,让所有sql执行完再commit?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant