yihua commented on PR #19717:
URL: https://github.com/apache/hudi/pull/19717#issuecomment-5688848847

   Validation notes for the two regression tests added in the last commit, so 
the coverage is not overstated.
   
   **The requested-partition guard** is covered end to end by 
`testIndexerFailsWhenTheOnlyUninitializedDefinitionIsNotTheRequestedIndex` and 
at the resolver level by `TestSecondaryIndexer`. Both were confirmed to fail 
with the guard reverted.
   
   **The eager-rollback exemption** is covered by 
`testEagerWriterDoesNotRollBackAnInFlightRequestedIndexBootstrap`, which puts 
the table into the shape of a bootstrap still running under a pending indexing 
action and then runs a real concurrent writer through `getInstantsToRollback`. 
It also asserts the commit becomes rollback-eligible again once no action is 
pending, so the exemption is scoped rather than a blanket pass for the solo 
family. Confirmed to fail on the first assertion with the exemption reverted. 
The in-progress state is constructed rather than raced into: I tried to 
reproduce it live in spark-shell by driving an indexing action and a writer 
from two threads, and the two write clients contend on metadata-table 
instantiation in a single JVM, which is not a shape Hudi's multi-writer model 
supports. A two-process race would be the stronger check if anyone wants it.
   
   Two things worth recording from those spark-shell runs. The abort path added 
here did get live validation: a genuine indexing action failed mid-catchup and 
afterwards the data timeline had no indexing instant and the table config had 
nothing inflight, where previously the partition would have stranded inflight 
with the instant inflight. And the exemption only applies under the EAGER 
failed-writes policy, which for Spark means streaming writes to the metadata 
table are disabled; the Spark default enables them, which puts that client on 
LAZY and protects an in-progress bootstrap by heartbeat instead. With no 
indexing action pending the added condition short-circuits and the filter 
reduces to the original expression, so it is a no-op outside that window.
   


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