simple sleep for now. will fix with better waits later
This commit is contained in:
parent
86f9560fc3
commit
25e5caaab8
@ -57,6 +57,7 @@ impl SearchKafkaSubCommand {
|
||||
.kafka_urls
|
||||
.context("top_config.app.kafka_urls is required")?;
|
||||
|
||||
// TODO: sea-streamer instead of rdkafka?
|
||||
let mut consumer = ClientConfig::new();
|
||||
|
||||
let security_protocol = &top_config.app.kafka_protocol;
|
||||
|
@ -10,7 +10,7 @@ use migration::sea_orm::prelude::Decimal;
|
||||
use migration::sea_orm::DatabaseConnection;
|
||||
use std::time::Duration;
|
||||
use tokio::sync::broadcast;
|
||||
use tokio::time::interval;
|
||||
use tokio::time::{interval, sleep};
|
||||
use tracing::{error, info, trace};
|
||||
|
||||
#[derive(Debug, Default)]
|
||||
@ -162,6 +162,9 @@ impl StatBuffer {
|
||||
}
|
||||
}
|
||||
|
||||
// TODO: don't just sleep. wait for things to actually finish
|
||||
sleep(Duration::from_secs(10)).await;
|
||||
|
||||
let saved_relational = self.save_relational_stats().await;
|
||||
|
||||
info!("saved {} pending relational stat(s)", saved_relational);
|
||||
|
Loading…
Reference in New Issue
Block a user