Fix SMG service discovery Clippy lint (#26034)
This commit is contained in:
@@ -113,13 +113,12 @@ impl PodInfo {
|
||||
|
||||
pub fn should_include(pod: &Pod, config: &ServiceDiscoveryConfig) -> bool {
|
||||
if config.pd_mode {
|
||||
if config.prefill_selector.is_empty() && config.decode_selector.is_empty() {
|
||||
if !(config.igw_mode && !config.selector.is_empty()) {
|
||||
warn!(
|
||||
"PD mode enabled but both prefill_selector and decode_selector are empty"
|
||||
);
|
||||
return false;
|
||||
}
|
||||
if config.prefill_selector.is_empty()
|
||||
&& config.decode_selector.is_empty()
|
||||
&& (!config.igw_mode || config.selector.is_empty())
|
||||
{
|
||||
warn!("PD mode enabled but both prefill_selector and decode_selector are empty");
|
||||
return false;
|
||||
}
|
||||
let matches_pd = Self::matches_selector(pod, &config.prefill_selector)
|
||||
|| Self::matches_selector(pod, &config.decode_selector);
|
||||
|
||||
Reference in New Issue
Block a user