iilyak commented on code in PR #5558:
URL: https://github.com/apache/couchdb/pull/5558#discussion_r2157121580


##########
src/couch_mrview/src/couch_mrview_index.erl:
##########
@@ -210,7 +215,17 @@ finish_update(State) ->
 
 commit(State) ->
     Header = {State#mrst.sig, couch_mrview_util:make_header(State)},
-    couch_file:write_header(State#mrst.fd, Header).
+    ok = couch_file:sync(State#mrst.fd),

Review Comment:
   >I'd prefer not to have the file:sync the .mrview files at all but it seems 
the simplest way to be as sure as we realistically can be that the index 
updates are durable
   
   Adding `couch_file:commit_header/2` seems easy and it wouldn't bypass `ioq`.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to