0.7.48
This commit is contained in:
@@ -288,6 +288,7 @@ impl TokenBackfillService {
|
||||
}
|
||||
}
|
||||
self.backfill_missing_token_metadata_best_effort(100).await;
|
||||
self.refresh_event_coverage_best_effort().await;
|
||||
let summary_payload = serde_json::json!({
|
||||
"tokenMint": result.token_mint,
|
||||
"mintSignatureCount": result.mint_signature_count,
|
||||
@@ -572,6 +573,26 @@ impl TokenBackfillService {
|
||||
if let Err(error) = transaction_classification_result {
|
||||
return Err(error);
|
||||
}
|
||||
let instruction_observation_index =
|
||||
crate::InstructionObservationIndexService::new(self.database.clone());
|
||||
let instruction_observation_result =
|
||||
instruction_observation_index.refresh_signature(signature.as_str()).await;
|
||||
match instruction_observation_result {
|
||||
Ok(index_result) => {
|
||||
tracing::debug!(
|
||||
signature = %signature,
|
||||
upserted_observation_count = index_result.upserted_observation_count,
|
||||
"instruction observation index refreshed after signature replay"
|
||||
);
|
||||
},
|
||||
Err(error) => {
|
||||
tracing::warn!(
|
||||
signature = %signature,
|
||||
error = %error,
|
||||
"instruction observation index refresh failed after signature replay"
|
||||
);
|
||||
},
|
||||
}
|
||||
return Ok(TokenBackfillSignatureResult {
|
||||
resolved_transaction_count: 1,
|
||||
missing_transaction_count: 0,
|
||||
@@ -715,6 +736,7 @@ impl TokenBackfillService {
|
||||
}
|
||||
}
|
||||
self.backfill_missing_token_metadata_best_effort(100).await;
|
||||
self.refresh_event_coverage_best_effort().await;
|
||||
let summary_payload = serde_json::json!({
|
||||
"poolAddress": result.pool_address,
|
||||
"poolSignatureCount": result.pool_signature_count,
|
||||
@@ -785,6 +807,7 @@ impl TokenBackfillService {
|
||||
Err(error) => return Err(error),
|
||||
};
|
||||
self.backfill_missing_token_metadata_best_effort(100).await;
|
||||
self.refresh_event_coverage_best_effort().await;
|
||||
let result = crate::SignatureBackfillResult {
|
||||
signature: trimmed_signature.clone(),
|
||||
resolved_transaction_count: replay.resolved_transaction_count,
|
||||
@@ -918,6 +941,26 @@ impl TokenBackfillService {
|
||||
},
|
||||
}
|
||||
}
|
||||
|
||||
async fn refresh_event_coverage_best_effort(&self) {
|
||||
let coverage_service = crate::DexEventCoverageService::new(self.database.clone());
|
||||
let refresh_result = coverage_service.refresh_local_counts(None).await;
|
||||
match refresh_result {
|
||||
Ok(refresh_result) => {
|
||||
tracing::debug!(
|
||||
upserted_entry_count = refresh_result.upserted_entry_count,
|
||||
summary_count = refresh_result.summaries.len(),
|
||||
"dex event coverage refreshed after historical replay"
|
||||
);
|
||||
},
|
||||
Err(error) => {
|
||||
tracing::warn!(
|
||||
error = %error,
|
||||
"dex event coverage refresh failed after historical replay"
|
||||
);
|
||||
},
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
fn token_backfill_should_retry_http_error(error: &crate::Error) -> bool {
|
||||
|
||||
Reference in New Issue
Block a user