We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 537f555 commit ace6f89Copy full SHA for ace6f89
src/sdam/description/topology/server_selection.rs
@@ -124,7 +124,12 @@ impl TopologyDescription {
124
SelectionCriteria::Predicate(ref filter) => self
125
.servers
126
.values()
127
- .filter(|s| s.server_type.is_data_bearing() && filter(&ServerInfo::new_borrowed(s)))
+ .filter(|s| {
128
+ // If we're direct-connected or connected to a standalone, ignore whether the
129
+ // single server in the topology is data-bearing.
130
+ (self.topology_type == TopologyType::Single || s.server_type.is_data_bearing())
131
+ && filter(&ServerInfo::new_borrowed(s))
132
+ })
133
.collect(),
134
};
135
0 commit comments