Skip to content

Commit

Permalink
Actually re-apply unloaded configs on future read
Browse files Browse the repository at this point in the history
Signed-off-by: Bob Weinand <bob.weinand@datadoghq.com>
  • Loading branch information
bwoebi committed Sep 27, 2024
1 parent 97feefb commit d62bffc
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions sidecar/src/shm_remote_config.rs
Original file line number Diff line number Diff line change
Expand Up @@ -437,6 +437,8 @@ impl RemoteConfigManager {
if *instant < Instant::now() - Duration::from_secs(3666) {
let (target, _) = self.unexpired_targets.pop().unwrap();
self.encountered_targets.remove(&target);
} else {
break;
}
}
}
Expand Down Expand Up @@ -533,6 +535,8 @@ impl RemoteConfigManager {
if let Some(pos) = self.check_configs.iter().position(|x| x == key) {
self.check_configs.swap_remove(pos);
}
// And re-apply it on next read
self.last_read_configs.push(key.clone());
false
} else {
true
Expand Down

0 comments on commit d62bffc

Please sign in to comment.