Skip to content

Commit

Permalink
actually poll nexus storage notifications
Browse files Browse the repository at this point in the history
  • Loading branch information
andrewjstone committed Oct 26, 2023
1 parent 82e2505 commit a622fec
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions sled-agent/src/storage_monitor.rs
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ use crate::nexus::NexusClientWithResolver;
use derive_more::From;
use futures::stream::FuturesOrdered;
use futures::FutureExt;
use futures::StreamExt;
use nexus_client::types::PhysicalDiskDeleteRequest;
use nexus_client::types::PhysicalDiskPutRequest;
use nexus_client::types::ZpoolPutRequest;
Expand Down Expand Up @@ -116,6 +117,11 @@ impl StorageMonitor {
pub async fn run(&mut self) {
loop {
tokio::select! {
_ = self.nexus_notifications.next(),
if !self.nexus_notifications.is_empty() =>
{
debug!(self.log, "Processing nexus notification");
}
resources = self.storage_manager.wait_for_changes() => {
info!(
self.log,
Expand Down

0 comments on commit a622fec

Please sign in to comment.