@@ -81,8 +81,8 @@ pub async fn run_listener(is_shutdown_arc: Arc<AtomicBool>) {
// 定时删除数据
tokio::spawn(async move {
loop {
+ tokio::time::sleep(Duration::from_secs(1800)).await;
delete_db_by_exchange(EXCHANGE_NAME, "trades", 5 * 60).await;
- tokio::time::sleep(Duration::from_secs(3600)).await;
}
});
@@ -80,8 +80,8 @@ pub async fn run_listener(is_shutdown_arc: Arc<AtomicBool>) {
@@ -84,8 +84,8 @@ pub async fn run_listener(is_shutdown_arc: Arc<AtomicBool>) {