Home
last modified time | relevance | path

Searched refs:HostAndPort (Results 1 – 25 of 413) sorted by relevance

12345678910>>...17

/dports/databases/mongodb36/mongodb-src-r3.6.23/src/mongo/util/net/
H A Dhostandport_test.cpp43 ASSERT_FALSE(HostAndPort("a", 1) < HostAndPort("a", 1)); in TEST()
47 ASSERT_FALSE(HostAndPort("b", 1) < HostAndPort("a", 1)); in TEST()
51 ASSERT_FALSE(HostAndPort("a", 2) < HostAndPort("a", 1)); in TEST()
56 ASSERT_EQUALS(HostAndPort("a", 1), HostAndPort("a", 1)); in TEST()
57 ASSERT_FALSE(HostAndPort("b", 1) == HostAndPort("a", 1)); in TEST()
58 ASSERT_FALSE(HostAndPort("a", 1) != HostAndPort("a", 1)); in TEST()
62 ASSERT_FALSE(HostAndPort("a", 1) == HostAndPort("a", 2)); in TEST()
111 ASSERT_EQUALS(HostAndPort("abc"), HostAndPort(HostAndPort("abc").toString())); in TEST()
112 ASSERT_EQUALS(HostAndPort("abc.def:3421"), HostAndPort(HostAndPort("abc.def:3421").toString())); in TEST()
113 ASSERT_EQUALS(HostAndPort("[124d:]:34"), HostAndPort(HostAndPort("[124d:]:34").toString())); in TEST()
[all …]
H A Dhostandport.cpp48 StatusWith<HostAndPort> HostAndPort::parse(StringData text) { in parse()
49 HostAndPort result; in parse()
57 HostAndPort::HostAndPort() : _port(-1) {} in HostAndPort() function in mongo::HostAndPort
59 HostAndPort::HostAndPort(StringData text) { in HostAndPort() function in mongo::HostAndPort
63 HostAndPort::HostAndPort(const std::string& h, int p) : _host(h), _port(p) {} in HostAndPort() function in mongo::HostAndPort
65 HostAndPort::HostAndPort(SockAddr addr) : _addr(std::move(addr)) { in HostAndPort() function in mongo::HostAndPort
69 bool HostAndPort::operator<(const HostAndPort& r) const { in operator <()
76 bool HostAndPort::operator==(const HostAndPort& r) const { in operator ==()
80 int HostAndPort::port() const { in port()
127 bool HostAndPort::empty() const { in empty()
[all …]
H A Dhostandport.h58 struct HostAndPort { struct
63 static StatusWith<HostAndPort> parse(StringData text);
68 HostAndPort();
74 explicit HostAndPort(StringData text);
81 HostAndPort(const std::string& h, int p);
89 explicit HostAndPort(SockAddr addr);
99 bool operator<(const HostAndPort& r) const;
100 bool operator==(const HostAndPort& r) const;
101 bool operator!=(const HostAndPort& r) const {
166 struct hash<mongo::HostAndPort> {
[all …]
/dports/databases/mongodb36/mongodb-src-r3.6.23/src/mongo/s/client/
H A Dshard_connection_test.cpp172 ShardConnection conn1(ConnectionString(HostAndPort(TARGET_HOST)), "test.user"); in TEST_F()
173 ShardConnection conn2(ConnectionString(HostAndPort(TARGET_HOST)), "test.user"); in TEST_F()
178 ShardConnection conn3(ConnectionString(HostAndPort(TARGET_HOST)), "test.user"); in TEST_F()
186 ShardConnection conn1(ConnectionString(HostAndPort(TARGET_HOST)), "test.user"); in TEST_F()
187 ShardConnection conn2(ConnectionString(HostAndPort(TARGET_HOST)), "test.user"); in TEST_F()
188 ShardConnection conn3(ConnectionString(HostAndPort(TARGET_HOST)), "test.user"); in TEST_F()
208 ShardConnection conn1(ConnectionString(HostAndPort(TARGET_HOST)), "test.user"); in TEST_F()
209 ShardConnection conn2(ConnectionString(HostAndPort(TARGET_HOST)), "test.user"); in TEST_F()
210 ShardConnection conn3(ConnectionString(HostAndPort(TARGET_HOST)), "test.user"); in TEST_F()
231 ShardConnection conn1(ConnectionString(HostAndPort(TARGET_HOST)), "test.user"); in TEST_F()
[all …]
/dports/databases/mongodb36/mongodb-src-r3.6.23/src/mongo/db/repl/
H A Dtopology_coordinator_v1_test.cpp191 const HostAndPort& syncingTo = HostAndPort()) { in receiveUpHeartbeat()
615 HostAndPort(), in TEST_F()
657 HostAndPort(), in TEST_F()
741 HostAndPort("h2"), in TEST_F()
752 HostAndPort("h2"), in TEST_F()
963 HostAndPort("h3"), in TEST_F()
1609 HostAndPort member = HostAndPort("test0:1234"); in TEST_F()
3403 HostAndPort("host2"), in TEST_F()
3409 HostAndPort("host2"), in TEST_F()
5904 HostAndPort target() { in target()
[all …]
H A Dsync_source_resolver_test.cpp345 HostAndPort candidate1("node1", 12345); in TEST_F()
361 HostAndPort candidate1("node1", 12345); in TEST_F()
407 HostAndPort candidate1("node1", 12345); in TEST_F()
408 HostAndPort candidate2("node2", 12345); in TEST_F()
433 HostAndPort candidate1("node1", 12345); in TEST_F()
434 HostAndPort candidate2("node2", 12345); in TEST_F()
435 HostAndPort candidate3("node3", 12345); in TEST_F()
474 HostAndPort candidate1("node1", 12345); in TEST_F()
475 HostAndPort candidate2("node2", 12345); in TEST_F()
499 HostAndPort candidate1("node1", 12345); in TEST_F()
[all …]
H A Dis_master_response.h112 const HostAndPort& getPrimary() const { in getPrimary()
144 const HostAndPort& getMe() const { in getMe()
207 void addHost(const HostAndPort& host);
209 void addPassive(const HostAndPort& passive);
211 void addArbiter(const HostAndPort& arbiter);
227 void setMe(const HostAndPort& me);
259 std::vector<HostAndPort> _hosts;
261 std::vector<HostAndPort> _passives;
263 std::vector<HostAndPort> _arbiters;
265 HostAndPort _primary;
[all …]
H A Dtopology_coordinator_test.cpp545 HostAndPort(), in TEST_F()
587 HostAndPort(), in TEST_F()
671 HostAndPort("h2"), in TEST_F()
682 HostAndPort("h2"), in TEST_F()
899 HostAndPort("h3"), in TEST_F()
1538 HostAndPort member = HostAndPort("test0:1234"); in TEST_F()
2472 HostAndPort target() { in target()
2478 HostAndPort _target;
2552 HostAndPort("host2"), in TEST_F()
2575 HostAndPort("host5"), in TEST_F()
[all …]
H A Dsync_source_selector_mock.h54 HostAndPort chooseNewSyncSource(const OpTime& ot) override;
55 void blacklistSyncSource(const HostAndPort& host, Date_t until) override;
56 bool shouldChangeSyncSource(const HostAndPort&,
68 void setChooseNewSyncSourceResult_forTest(const HostAndPort&);
78 HostAndPort getLastBlacklistedSyncSource_forTest() const;
87 HostAndPort _chooseNewSyncSourceResult = HostAndPort("localhost", -1);
96 HostAndPort _lastBlacklistedSyncSource;
H A Dsync_source_resolver.h70 StatusWith<HostAndPort> syncSourceStatus = {ErrorCodes::BadValue, "status not populated"};
84 HostAndPort getSyncSource() { in getSyncSource()
147 StatusWith<HostAndPort> _chooseNewSyncSource();
152 std::unique_ptr<Fetcher> _makeFirstOplogEntryFetcher(HostAndPort candidate,
158 std::unique_ptr<Fetcher> _makeRequiredOpTimeFetcher(HostAndPort candidate,
172 OpTime _parseRemoteEarliestOpTime(const HostAndPort& candidate,
179 HostAndPort candidate,
185 Status _scheduleRBIDRequest(HostAndPort candidate, OpTime earliestOpTimeSeen);
186 void _rbidRequestCallback(HostAndPort candidate,
199 HostAndPort candidate,
[all …]
H A Drepl_set_config_checks_test.cpp49 rses.addSelf(HostAndPort("h1")); in TEST()
78 presentOnceExternalState.addSelf(HostAndPort("h2")); in TEST()
80 presentTwiceExternalState.addSelf(HostAndPort("h3")); in TEST()
112 presentOnceExternalState.addSelf(HostAndPort("h2")); in TEST()
209 externalState.addSelf(HostAndPort("h1")); in TEST()
273 externalState.addSelf(HostAndPort("h1")); in TEST()
318 externalState.addSelf(HostAndPort("h1")); in TEST()
369 externalState.addSelf(HostAndPort("h1")); in TEST()
445 externalState.addSelf(HostAndPort("h1")); in TEST()
518 externalState.addSelf(HostAndPort("h1")); in TEST()
[all …]
/dports/databases/mongodb36/mongodb-src-r3.6.23/src/mongo/client/
H A Dreplica_set_monitor_internal.h76 HostAndPort primary; // empty if not present
77 std::set<HostAndPort> normalHosts; // both "hosts" and "passives"
83 HostAndPort host;
97 explicit Node(const HostAndPort& host);
128 HostAndPort host;
146 SetState(StringData name, const std::set<HostAndPort>& seedNodes);
157 HostAndPort getMatchingHost(const ReadPreferenceSetting& criteria) const;
162 Node* findNode(const HostAndPort& host);
168 Node* findOrCreateNode(const HostAndPort& host);
230 std::deque<HostAndPort> hostsToScan; // Work queue.
[all …]
H A Dreplica_set_monitor.h73 ReplicaSetMonitor(StringData name, const std::set<HostAndPort>& seeds);
106 HostAndPort getMasterOrUassert();
123 void failedHost(const HostAndPort& host, const Status& status);
129 bool isPrimary(const HostAndPort& host) const;
135 bool isHostUp(const HostAndPort& host) const;
161 bool contains(const HostAndPort& server) const;
309 HostAndPort refreshUntilMatches(const ReadPreferenceSetting& criteria);
338 explicit NextStep(StepKind step, const HostAndPort& host = HostAndPort())
342 HostAndPort host;
362 void failedHost(const HostAndPort& host, const Status& status);
[all …]
H A Dreplica_set_monitor_read_preference_test.cpp139 HostAndPort host = in TEST()
153 HostAndPort host = in TEST()
166 HostAndPort host = in TEST()
177 HostAndPort host = in TEST()
191 HostAndPort host = in TEST()
205 HostAndPort host = in TEST()
220 HostAndPort host = in TEST()
233 HostAndPort host = in TEST()
248 HostAndPort host = in TEST()
264 HostAndPort host = in TEST()
[all …]
H A Dreplica_set_monitor_test.cpp52 std::vector<HostAndPort> out; in basicSeedsBuilder()
352 set<HostAndPort> seen; in TEST()
399 set<HostAndPort> seen; in TEST()
456 set<HostAndPort> seen; in TEST()
502 set<HostAndPort> seen; in TEST()
577 set<HostAndPort> seen; in TEST()
683 set<HostAndPort> seen; in TEST()
796 set<HostAndPort> seen; in TEST()
982 set<HostAndPort> seen; in TEST()
1046 set<HostAndPort> seen; in TEST()
[all …]
H A Dreplica_set_monitor_node_test.cpp48 set<HostAndPort> seeds; in isCompatible()
77 Node node((HostAndPort())); in TEST()
85 Node node((HostAndPort())); in TEST()
91 Node node((HostAndPort())); in TEST()
97 Node node((HostAndPort())); in TEST()
103 Node node((HostAndPort())); in TEST()
110 Node node((HostAndPort())); in TEST()
121 Node node((HostAndPort())); in TEST()
130 Node node((HostAndPort())); in TEST()
137 Node node((HostAndPort())); in TEST()
[all …]
H A Dremote_command_targeter_standalone.h44 explicit RemoteCommandTargeterStandalone(const HostAndPort& hostAndPort);
48 StatusWith<HostAndPort> findHost(OperationContext* opCtx,
51 StatusWith<HostAndPort> findHostWithMaxWait(const ReadPreferenceSetting& readPref,
54 void markHostNotMaster(const HostAndPort& host, const Status& status) override;
56 void markHostUnreachable(const HostAndPort& host, const Status& status) override;
59 const HostAndPort _hostAndPort;
H A Dreplica_set_monitor.cpp135 bool operator()(const HostAndPort& lhs, const HostAndPort& rhs) { in operator ()()
146 bool operator()(const HostAndPort& host) { in operator ()()
152 const HostAndPort& _host;
157 bool operator()(const HostAndPort& host) { in operator ()()
163 const std::set<HostAndPort>& _hosts;
575 HostAndPort host = _scan->hostsToScan.front(); in getNextStep()
760 std::set<HostAndPort> newWaitingFor; in receivedIsMasterFromMaster()
915 primary = primaryString.empty() ? HostAndPort() : HostAndPort(primaryString); in parse()
1050 HostAndPort out = in getMatchingHost()
1073 return HostAndPort(); in getMatchingHost()
[all …]
H A Dremote_command_targeter.h42 struct HostAndPort;
70 virtual StatusWith<HostAndPort> findHost(OperationContext* opCtx,
81 virtual StatusWith<HostAndPort> findHostWithMaxWait(const ReadPreferenceSetting& readPref,
93 StatusWith<HostAndPort> findHostNoWait(const ReadPreferenceSetting& readPref) { in findHostNoWait()
102 virtual void markHostNotMaster(const HostAndPort& host, const Status& status) = 0;
109 virtual void markHostUnreachable(const HostAndPort& host, const Status& status) = 0;
H A Dremote_command_targeter_mock.h59 StatusWith<HostAndPort> findHostWithMaxWait(const ReadPreferenceSetting& readPref,
62 StatusWith<HostAndPort> findHost(OperationContext* opCtx,
68 void markHostNotMaster(const HostAndPort& host, const Status& status) override;
73 void markHostUnreachable(const HostAndPort& host, const Status& status) override;
83 void setFindHostReturnValue(StatusWith<HostAndPort> returnValue);
87 StatusWith<HostAndPort> _findHostReturnValue;
/dports/databases/mongodb36/mongodb-src-r3.6.23/src/mongo/executor/
H A Dconnection_pool_test.cpp82 pool.get(HostAndPort(), in TEST_F()
92 pool.get(HostAndPort(), in TEST_F()
283 pool.get(HostAndPort(), in TEST_F()
293 pool.get(HostAndPort(), in TEST_F()
348 pool.get(HostAndPort(), in TEST_F()
358 pool.get(HostAndPort(), in TEST_F()
387 pool.get(HostAndPort(), in TEST_F()
422 pool.get(HostAndPort(), in TEST_F()
460 pool.get(HostAndPort(), in TEST_F()
471 pool.get(HostAndPort(), in TEST_F()
[all …]
/dports/databases/mongodb36/mongodb-src-r3.6.23/src/mongo/transport/
H A Dmock_session.h50 static std::shared_ptr<MockSession> create(HostAndPort remote, in create()
51 HostAndPort local, in create()
62 const HostAndPort& remote() const override { in remote()
66 const HostAndPort& local() const override { in local()
72 explicit MockSession(HostAndPort remote, HostAndPort local, TransportLayer* tl) in MockSession()
77 HostAndPort _remote;
78 HostAndPort _local;
/dports/net/rclone/rclone-1.57.0/vendor/github.com/pengsrc/go-shared/check/
H A Dhost_test.go10 assert.False(t, HostAndPort("127.0.0.1:80:90"))
11 assert.False(t, HostAndPort("127.0.0.1"))
12 assert.False(t, HostAndPort("mysql"))
13 assert.False(t, HostAndPort("mysql:mysql"))
14 assert.True(t, HostAndPort("mysql:3306"))
15 assert.True(t, HostAndPort("172.16.70.50:6379"))
/dports/databases/mongodb36/mongodb-src-r3.6.23/src/mongo/dbtests/
H A Dreplica_set_monitor_test.cpp95 set<HostAndPort> seedList; in TEST_F()
96 seedList.insert(HostAndPort(replSet->getPrimary())); in TEST_F()
149 set<HostAndPort> seedList; in TEST()
150 seedList.insert(HostAndPort(replSet.getPrimary())); in TEST()
212 oldConfig.findMemberByHostAndPort(HostAndPort(host)); in setUp()
260 set<HostAndPort> seedList; in TEST_F()
261 seedList.insert(HostAndPort(replSet->getPrimary())); in TEST_F()
272 HostAndPort node = assertGet(monitor->getHostOrRefresh( in TEST_F()
286 set<HostAndPort> seedList; in TEST_F()
287 seedList.insert(HostAndPort(replSet->getPrimary())); in TEST_F()
[all …]
/dports/net/pichi/pichi-1.4.0/test/
H A Duri.cpp173 BOOST_CHECK_EXCEPTION(HostAndPort{""}, Exception, verifyException<PichiError::BAD_PROTO>); in BOOST_AUTO_TEST_CASE()
174 BOOST_CHECK_EXCEPTION(HostAndPort{"[]"}, Exception, verifyException<PichiError::BAD_PROTO>); in BOOST_AUTO_TEST_CASE()
175 BOOST_CHECK_EXCEPTION(HostAndPort{":80"}, Exception, verifyException<PichiError::BAD_PROTO>); in BOOST_AUTO_TEST_CASE()
181 auto domain = HostAndPort{"localhost"sv}; in BOOST_AUTO_TEST_CASE()
185 auto ipv4 = HostAndPort{"127.0.0.1"sv}; in BOOST_AUTO_TEST_CASE()
189 auto ipv6 = HostAndPort{"[fe80::1]"sv}; in BOOST_AUTO_TEST_CASE()
196 BOOST_CHECK_EXCEPTION(HostAndPort{"localhost:http"}, Exception, in BOOST_AUTO_TEST_CASE()
202 auto hp = HostAndPort{"example.com:443"}; in BOOST_AUTO_TEST_CASE()
209 BOOST_CHECK_EQUAL("::", HostAndPort{"[::]:80"}.host_); in BOOST_AUTO_TEST_CASE()
210 BOOST_CHECK_EQUAL("fe80::1", HostAndPort{"[fe80::1]:80"}.host_); in BOOST_AUTO_TEST_CASE()
[all …]

12345678910>>...17