-
Notifications
You must be signed in to change notification settings - Fork 1.2k
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
(fix) Flush output stream before calling fd.sync, #480 #481
Conversation
@fengjiachun @zongtanghu 这个有空抓紧看下,需要发一个版本 |
需要整理下代码缩进 |
@fengjiachun 用了格式化命令了,会乱 |
Maybe, it will be better that adding some unit test case? @killme2008 |
@zongtanghu It's hard to test this case in unit test, because we can't mock system crash in java simply. I think we should verify it in chaos test. |
@killme2008 ok, it's nice! |
@fengjiachun It can be merged. |
Motivation:
#480
Modification:
Flush output stream before calling
FileDescriptor#sync
inProtoBufFile.save
method. I also checked other code that do this stuff, they looks fine.Result:
Fixes #480 .
It's a fatal issue, we should release a new version ASAP.