swamirishi commented on PR #7862:
URL: https://github.com/apache/ozone/pull/7862#issuecomment-2675205130

   > @swamirishi, thanks for the explanation.
   > 
   > When there is a failure in `applyTransaction` and we add the Container to 
`unhealthyContainerSet`, no more transactions are applied to that Container.
   > 
   > In this case, there could be committed transactions in the `Raft Log` 
which will never get applied to the `State Machine`. This means that there are 
transactions committed by this Datanode which will be missing in the Container.
   > 
   > If that's the case, doesn't it make sense to mark the Container as 
`UNHEALTHY` rather than marking it as `QUASI_CLOSED`?
   > 
   > From my understanding, `QUASI_CLOSED` state means that all the 
transactions committed (to `Raft Log`) by the Datanode is applied on the 
Container. `QUASI_CLOSED` replica might miss some transactions which the other 
replica has (if this is not the leader), but those transactions are not 
committed to the `Raft Log` in first place.
   
   
   Having something in the raft log and not applying it & not having a txn in 
raft log is one and the same. Why have different states? If we move this to 
QUASI_CLOSED state we would be able to atleast close this container if all 
containers are in unhealthy state we won't be able to close it. If all replicas 
are in QUASI_CLOSED state the containers can be closed. I believe QUASI_CLOSED 
containers are containers which have missed a bunch of txns irrespective of it 
being in the raft log or not. Atleast the current implementation is so.
   
   > If we go with this definition of `QUASI_CLOSED`, SCM might be able to 
Close a `QUASI_CLOSED` Container using quorum. That is, if we fix all the other 
issues on the Datanode.
   > 
   > If we want to `QUASI_CLOSED` the Container, we should make sure that all 
the transaction committed to `Raft Log` are applied to the `State Machine`.
   
   


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


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to