Return-Path: X-Original-To: archive-asf-public-internal@cust-asf2.ponee.io Delivered-To: archive-asf-public-internal@cust-asf2.ponee.io Received: from cust-asf.ponee.io (cust-asf.ponee.io [163.172.22.183]) by cust-asf2.ponee.io (Postfix) with ESMTP id 9D705200BD3 for ; Tue, 6 Dec 2016 22:03:56 +0100 (CET) Received: by cust-asf.ponee.io (Postfix) id 9C15C160B1B; Tue, 6 Dec 2016 21:03:56 +0000 (UTC) Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by cust-asf.ponee.io (Postfix) with SMTP id E858C160B17 for ; Tue, 6 Dec 2016 22:03:55 +0100 (CET) Received: (qmail 16362 invoked by uid 500); 6 Dec 2016 21:03:55 -0000 Mailing-List: contact reviews-help@impala.incubator.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Delivered-To: mailing list reviews@impala.incubator.apache.org Received: (qmail 16345 invoked by uid 99); 6 Dec 2016 21:03:54 -0000 Received: from pnap-us-west-generic-nat.apache.org (HELO spamd1-us-west.apache.org) (209.188.14.142) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 06 Dec 2016 21:03:54 +0000 Received: from localhost (localhost [127.0.0.1]) by spamd1-us-west.apache.org (ASF Mail Server at spamd1-us-west.apache.org) with ESMTP id 872D4D37F3 for ; Tue, 6 Dec 2016 21:03:54 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd1-us-west.apache.org X-Spam-Flag: NO X-Spam-Score: 0.363 X-Spam-Level: X-Spam-Status: No, score=0.363 tagged_above=-999 required=6.31 tests=[RDNS_DYNAMIC=0.363, SPF_PASS=-0.001, URIBL_BLOCKED=0.001] autolearn=disabled Received: from mx1-lw-eu.apache.org ([10.40.0.8]) by localhost (spamd1-us-west.apache.org [10.40.0.7]) (amavisd-new, port 10024) with ESMTP id h0ZTQ4nx1Wfb for ; Tue, 6 Dec 2016 21:03:52 +0000 (UTC) Received: from ip-10-146-233-104.ec2.internal (ec2-75-101-130-251.compute-1.amazonaws.com [75.101.130.251]) by mx1-lw-eu.apache.org (ASF Mail Server at mx1-lw-eu.apache.org) with ESMTPS id 071725FB6B for ; Tue, 6 Dec 2016 21:03:51 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by ip-10-146-233-104.ec2.internal (8.14.4/8.14.4) with ESMTP id uB6L3eDH002378; Tue, 6 Dec 2016 21:03:40 GMT Message-Id: <201612062103.uB6L3eDH002378@ip-10-146-233-104.ec2.internal> Date: Tue, 6 Dec 2016 21:03:40 +0000 From: "Sailesh Mukil (Code Review)" To: impala-cr@cloudera.com, reviews@impala.incubator.apache.org Reply-To: sailesh@cloudera.com X-Gerrit-MessageType: newpatchset Subject: =?UTF-8?Q?=5BImpala-ASF-CR=5D_IMPALA-2864=3A_Ensure_that_client_connections_are_closed_after_a_failed_Open=28=29=0A?= X-Gerrit-Change-Id: Ia7e883d8224304ad13a051f595d0e8abf4f9671e X-Gerrit-ChangeURL: X-Gerrit-Commit: c3cf34b73e352d48ef2ca51dc3359cb9c4e22739 In-Reply-To: References: MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Content-Disposition: inline User-Agent: Gerrit/2.12.2 archived-at: Tue, 06 Dec 2016 21:03:56 -0000 Sailesh Mukil has uploaded a new patch set (#2). Change subject: IMPALA-2864: Ensure that client connections are closed after a failed Open() ...................................................................... IMPALA-2864: Ensure that client connections are closed after a failed Open() When a client tries to Open() a socket and fails, we previously assumed that the socket was never opened and therefore did not close it. However, if Kerberos is enabled, the ThriftClientImpl::Open() calls TSaslTransport::Open(), which not only opens the socket but also does the initial handshake. If there was an error during the handshake, we just returned with an error without closing the socket, causing the server side to wait on the same connection. This patch closes the client side socket, thereby terminating the connection to the server in the above scenario, so that the server side doesn't need to hold on to a connection until a timeout terminates the connection. A thrift-server-test is added to test the RPC failure path. Change-Id: Ia7e883d8224304ad13a051f595d0e8abf4f9671e --- M be/src/rpc/thrift-client.cc M be/src/rpc/thrift-client.h M be/src/rpc/thrift-server-test.cc M be/src/runtime/client-cache.h M be/src/runtime/data-stream-test.cc A be/src/testutil/bad-cert.pem A be/src/testutil/bad-key.pem 7 files changed, 85 insertions(+), 2 deletions(-) git pull ssh://gerrit.cloudera.org:29418/Impala-ASF refs/changes/85/5385/2 -- To view, visit http://gerrit.cloudera.org:8080/5385 To unsubscribe, visit http://gerrit.cloudera.org:8080/settings Gerrit-MessageType: newpatchset Gerrit-Change-Id: Ia7e883d8224304ad13a051f595d0e8abf4f9671e Gerrit-PatchSet: 2 Gerrit-Project: Impala-ASF Gerrit-Branch: master Gerrit-Owner: Sailesh Mukil