|
|
|
@ -149,10 +149,10 @@ impl Replica { |
|
|
|
|
///
|
|
|
|
|
/// In case of error: send help?
|
|
|
|
|
#[instrument(err)] |
|
|
|
|
async fn try_msg_by_domain_and_nonce(&self, domain: u32, nonce: u32) -> Result<bool> { |
|
|
|
|
async fn try_msg_by_domain_and_nonce(&self, domain: u32, current_seq: u32) -> Result<bool> { |
|
|
|
|
use optics_core::traits::Replica; |
|
|
|
|
|
|
|
|
|
let message = match self.home.message_by_nonce(domain, nonce).await { |
|
|
|
|
let message = match self.home.message_by_nonce(domain, current_seq).await { |
|
|
|
|
Ok(Some(m)) => m, |
|
|
|
|
Ok(None) => { |
|
|
|
|
info!("Message not yet found"); |
|
|
|
@ -205,7 +205,10 @@ impl Replica { |
|
|
|
|
sleep(Duration::from_secs(self.interval)).await; |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
info!("Dispatching a message for processing {}:{}", domain, nonce); |
|
|
|
|
info!( |
|
|
|
|
"Dispatching a message for processing {}:{}", |
|
|
|
|
domain, current_seq |
|
|
|
|
); |
|
|
|
|
|
|
|
|
|
self.process(message, proof).await?; |
|
|
|
|
|
|
|
|
|