maybe it's the match statement? remove it

This commit is contained in:
Christian Schwarz
2025-02-07 02:13:25 +01:00
parent 43c47e684f
commit 1ce78b39fe

View File

@@ -1078,31 +1078,16 @@ impl PageServerHandler {
let flush_fut = pgb_writer.flush();
// do it while respecting cancellation
let _: () = async move {
match flushing_timer {
Some(flushing_timer) => {
tokio::select! {
biased;
_ = cancel.cancelled() => {
// We were requested to shut down.
info!("shutdown request received in page handler");
return Err(QueryError::Shutdown)
}
res = flush_fut => {
res?;
}
}
tokio::select! {
biased;
_ = cancel.cancelled() => {
// We were requested to shut down.
info!("shutdown request received in page handler");
return Err(QueryError::Shutdown)
}
res = flush_fut => {
res?;
}
None => tokio::select! {
biased;
_ = cancel.cancelled() => {
// We were requested to shut down.
info!("shutdown request received in page handler");
return Err(QueryError::Shutdown)
}
res = flush_fut => {
res?;
}
},
}
Ok(())
}