aboutsummaryrefslogtreecommitdiffhomepage
path: root/test/cpp/grpclb
diff options
context:
space:
mode:
authorGravatar Craig Tiller <ctiller@google.com>2016-11-04 08:21:56 -0700
committerGravatar Craig Tiller <ctiller@google.com>2016-11-04 08:21:56 -0700
commit32df467f1189c2b1bc7010b0a99932a7a3fb2684 (patch)
tree106201276069914dcdcf2d9727047167486887a4 /test/cpp/grpclb
parent41fd9f2343ad39fc6db1b417ee403c976fc4b00f (diff)
parent852c58e8ae64ccd7361ab0bdc36f3297960c9d5b (diff)
Merge github.com:grpc/grpc into grpc_slice
Diffstat (limited to 'test/cpp/grpclb')
-rw-r--r--test/cpp/grpclb/grpclb_test.cc18
1 files changed, 14 insertions, 4 deletions
diff --git a/test/cpp/grpclb/grpclb_test.cc b/test/cpp/grpclb/grpclb_test.cc
index f3cfe53bda..3b37fa53f3 100644
--- a/test/cpp/grpclb/grpclb_test.cc
+++ b/test/cpp/grpclb/grpclb_test.cc
@@ -76,10 +76,22 @@ extern "C" {
// - Send a serverlist with faulty ip:port addresses (port > 2^16, etc).
// - Test reception of invalid serverlist
// - Test pinging
-// - Test against a non-LB server. That server should return UNIMPLEMENTED and
-// the call should fail.
+// - Test against a non-LB server.
// - Random LB server closing the stream unexpectedly.
// - Test using DNS-resolvable names (localhost?)
+//
+// Findings from end to end testing to be covered here:
+// - Handling of LB servers restart, including reconnection after backing-off
+// retries.
+// - Destruction of load balanced channel (and therefore of grpclb instance)
+// while:
+// 1) the internal LB call is still active. This should work by virtue
+// of the weak reference the LB call holds. The call should be terminated as
+// part of the grpclb shutdown process.
+// 2) the retry timer is active. Again, the weak reference it holds should
+// prevent a premature call to \a glb_destroy.
+// - Restart of backend servers with no changes to serverlist. This exercises
+// the RR handover mechanism.
namespace grpc {
namespace {
@@ -144,7 +156,6 @@ static grpc_slice build_response_payload_slice(
// disfunctional implementation of std::to_string in gcc 4.4, which doesn't
// have a version for int but does have one for long long int.
string token_data = "token" + std::to_string((long long int)ports[i]);
- token_data.resize(64, '-');
server->set_load_balance_token(token_data);
}
const grpc::string &enc_resp = response.SerializeAsString();
@@ -333,7 +344,6 @@ static void start_backend_server(server_fixture *sf) {
// disfunctional implementation of std::to_string in gcc 4.4, which doesn't
// have a version for int but does have one for long long int.
string expected_token = "token" + std::to_string((long long int)sf->port);
- expected_token.resize(64, '-');
GPR_ASSERT(contains_metadata(&request_metadata_recv, "lb-token",
expected_token.c_str()));