gkoszyk opened a new issue, #4135:
URL: https://github.com/apache/iggy/issues/4135

   ### Test to fix
   
   
`given_a_failed_writeback_when_a_fresh_handle_syncs_then_it_should_not_report_success`
 — `core/simulator/src/storage/tests.rs:2610`, ignored in #4132.
   
   It asserts that after a device drops an inode's dirty pages, a descriptor 
opened **afterwards** must not report a successful `fsync` over the lost bytes.
   
   ### Why it fails
   
   `checkpoint_files` (`core/journal/src/partition_journal.rs:356-361`) opens 
its own descriptor for each dirty path and syncs through that, rather than 
through the writer that produced the bytes. `synced_files` 
(`core/partitions/src/persistence.rs:795-800`) covers consumer-offset paths 
only.
   
   Under `durability = replicated` + `consumer_offset_durability = persisted`, 
`IggyIndexWriter` is constructed with `fsync = 
runtime.durability.is_persisted()` = `false` 
(`core/server/src/partition_helpers.rs:391`, `:461`), so that fresh-descriptor 
`fsync` is the **only** index barrier in that configuration.
   
   Linux samples errseq at open. A writeback error recorded before that open is 
reported to nobody, the `fsync` returns success, and the WAL then reclaims 
history the index never received.
   
   The simulator could not express this before #4132 — it had no per-inode 
error state and no per-handle errseq sampling. `SimStorage::fail_writeback` 
adds both.
   
   ### Done when
   
   `synced_files` covers segment and index paths synced through their live 
writers, or those writers are fsynced in `commit_messages_inner` before the 
checkpoint is requested. `#[ignore]` removed and passing without `--ignored`.
   
   Found by an adversarial review of #4092. See also #4128 — same class of 
defect on the *purge* path rather than the checkpoint path.
   


-- 
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