Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions docs/configuration/cluster_manager/cluster.rst
Original file line number Diff line number Diff line change
Expand Up @@ -58,23 +58,23 @@ hosts

.. code-block:: json

["tcp://10.0.0.2:1234", "tcp://10.0.0.3:5678"]
[{"url": "tcp://10.0.0.2:1234"}, {"url": "tcp://10.0.0.3:5678"}]

strict_dns
Strict DNS clusters can specify any number of DNS/port combinations. All DNS addresses will be
resolved and grouped together to form the final cluster. For example:

.. code-block:: json

["tcp://foo1.bar.com:1234", "tcp://foo2.bar.com:5678"]
[{"url": "tcp://foo1.bar.com:1234"}, {"url": "tcp://foo2.bar.com:5678"}]

logical_dns
Logical DNS clusters specify a host much like strict DNS, however only the first host will be
used. For example:

.. code-block:: json

["tcp://foo1.bar.com:1234"]
[{"url": "tcp://foo1.bar.com:1234"}]

.. _config_cluster_manager_cluster_service_name:

Expand Down
2 changes: 1 addition & 1 deletion docs/intro/real_world_deployments.rst
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,4 @@ Real world deployments
Lyft
Envoy was initially developed for use at Lyft as the primary edge and service to service
networking layer. Lyft's deployment is currently across thousands of hosts and processes over
1 million requests per second at peak.
2 million requests per second at peak.
46 changes: 4 additions & 42 deletions test/common/upstream/upstream_impl_test.cc
Original file line number Diff line number Diff line change
Expand Up @@ -217,44 +217,6 @@ TEST(StaticClusterImplTest, UrlConfig) {
EXPECT_EQ(0UL, cluster.localZoneHealthyHosts().size());
}

TEST(StaticClusterImplTest, BothAddressPortAndURLConfig) {
Stats::IsolatedStoreImpl stats;
Ssl::MockContextManager ssl_context_manager;
std::string json = R"EOF(
{
"name": "addressportconfig",
"connect_timeout_ms": 250,
"type": "static",
"lb_type": "round_robin",
"hosts": [{"address": "1.2.3.4", "port": 99, "url": "tcp://192.168.1.1:22"},
{"address":"5.6.7.8", "port": 63, "url": "tcp://192.168.1.2:44"}]
}
)EOF";

Json::StringLoader config(json);
StaticClusterImpl cluster(config, stats, ssl_context_manager);
EXPECT_THAT(std::list<std::string>({"tcp://192.168.1.1:22", "tcp://192.168.1.2:44"}),
ContainerEq(hostListToURLs(cluster.hosts())));
}

TEST(StaticClusterImplTest, AddressMissingPortConfig) {
Stats::IsolatedStoreImpl stats;
Ssl::MockContextManager ssl_context_manager;
std::string json = R"EOF(
{
"name": "addressportconfig",
"connect_timeout_ms": 250,
"type": "static",
"lb_type": "round_robin",
"hosts": [{"address": "1.2.3.4"},
{"address":"5.6.7.8"}]
}
)EOF";

Json::StringLoader config(json);
EXPECT_THROW(StaticClusterImpl(config, stats, ssl_context_manager), EnvoyException);
}

TEST(StaticClusterImplTest, UnsupportedLBType) {
Stats::IsolatedStoreImpl stats;
Ssl::MockContextManager ssl_context_manager;
Expand All @@ -264,8 +226,8 @@ TEST(StaticClusterImplTest, UnsupportedLBType) {
"connect_timeout_ms": 250,
"type": "static",
"lb_type": "fakelbtype",
"hosts": [{"address": "1.2.3.4", "port": 99, "url": "tcp://192.168.1.1:22"},
{"address":"5.6.7.8", "port": 63, "url": "tcp://192.168.1.2:44"}]
"hosts": [{"url": "tcp://192.168.1.1:22"},
{"url": "tcp://192.168.1.2:44"}]
}
)EOF";

Expand All @@ -283,8 +245,8 @@ TEST(StaticClusterImplTest, UnsupportedFeature) {
"type": "static",
"lb_type": "round_robin",
"features": "fake",
"hosts": [{"address": "1.2.3.4", "port": 99, "url": "tcp://192.168.1.1:22"},
{"address":"5.6.7.8", "port": 63, "url": "tcp://192.168.1.2:44"}]
"hosts": [{"url": "tcp://192.168.1.1:22"},
{"url": "tcp://192.168.1.2:44"}]
}
)EOF";

Expand Down