Refactors is_banned logic and forces health check on unban (#288)

* Refactors is_banned logic and forces healthcheck on unban

* typo

* Make is banned log debug

* addressing comments

* Comment
This commit is contained in:
zainkabani
2023-01-19 20:36:48 -05:00
committed by GitHub
parent c58f9557ae
commit a0e740d30f
3 changed files with 154 additions and 106 deletions

View File

@@ -774,6 +774,7 @@ mod test {
automatic_sharding_key: Some(String::from("id")),
healthcheck_delay: PoolSettings::default().healthcheck_delay,
healthcheck_timeout: PoolSettings::default().healthcheck_timeout,
ban_time: PoolSettings::default().ban_time,
};
let mut qr = QueryRouter::new();
assert_eq!(qr.active_role, None);