You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@iggy.apache.org by "numinnex (via GitHub)" <gi...@apache.org> on 2026/03/02 10:42:00 UTC
Re: [PR] feat(consensus): add loopback queue for primary self-addressed messages [iggy]
numinnex commented on code in PR #2825:
URL: https://github.com/apache/iggy/pull/2825#discussion_r2871697940
##########
core/consensus/src/impls.rs:
##########
@@ -1139,6 +1149,24 @@ impl<B: MessageBus, P: Pipeline<Entry = PipelineEntry>> VsrConsensus<B, P> {
false
}
+ /// Enqueue a self-addressed PrepareOk for the primary to process in the next loopback drain.
+ pub(crate) fn push_loopback(&self, message: Message<PrepareOkHeader>) {
Review Comment:
We don't send only PrepareOk to our selves, other messages such as `DoViewChange` and `StartViewChange`.
##########
core/consensus/src/impls.rs:
##########
@@ -1139,6 +1149,24 @@ impl<B: MessageBus, P: Pipeline<Entry = PipelineEntry>> VsrConsensus<B, P> {
false
}
+ /// Enqueue a self-addressed PrepareOk for the primary to process in the next loopback drain.
+ pub(crate) fn push_loopback(&self, message: Message<PrepareOkHeader>) {
Review Comment:
Also use that method inside of the `send_message_to_replica` or however it's called method, when the replica_id == self.replica_id.
--
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: commits-unsubscribe@iggy.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org