web search done right
deduplicate cluster members to remove services that have been restarted
Mikkel Denkerf6cd2e092605
diff --git a/crates/core/src/distributed/cluster.rs b/crates/core/src/distributed/cluster.rsindex f31dc39d..1b0e22af 100644--- a/crates/core/src/distributed/cluster.rs+++ b/crates/core/src/distributed/cluster.rs@@ -17,6 +17,7 @@ use chitchat::{spawn_chitchat, transport::UdpTransport, Chitchat, ChitchatConfig, ChitchatHandle,ClusterStateSnapshot, FailureDetectorConfig, NodeId,};+use itertools::Itertools;use std::{net::SocketAddr, sync::Arc, time::Duration};use tokio::sync::Mutex;@@ -141,6 +142,9 @@ impl Cluster {pub async fn members(&self) -> Vec<Member> {snapshot_members(self.chitchat.lock().await.state_snapshot())+ .into_iter()+ .unique_by(|m| m.service.clone())+ .collect()}pub async fn await_member<P>(&self, pred: P) -> Memberdiff --git a/crates/core/src/ranking/signals/core/non_text.rs b/crates/core/src/ranking/signals/core/non_text.rsindex e4f7498a..e895460c 100644--- a/crates/core/src/ranking/signals/core/non_text.rs+++ b/crates/core/src/ranking/signals/core/non_text.rs@@ -398,7 +398,7 @@ impl CoreSignal for FetchTimeMs {pub struct UpdateTimestamp;impl CoreSignal for UpdateTimestamp {fn default_coefficient(&self) -> f64 {- 0.5+ 0.85}fn as_field(&self) -> Option<Field> {