Return-Path: Delivered-To: apmail-hadoop-core-dev-archive@www.apache.org Received: (qmail 52686 invoked from network); 9 Apr 2008 00:44:13 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 9 Apr 2008 00:44:13 -0000 Received: (qmail 27014 invoked by uid 500); 9 Apr 2008 00:44:12 -0000 Delivered-To: apmail-hadoop-core-dev-archive@hadoop.apache.org Received: (qmail 26990 invoked by uid 500); 9 Apr 2008 00:44:12 -0000 Mailing-List: contact core-dev-help@hadoop.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: core-dev@hadoop.apache.org Delivered-To: mailing list core-dev@hadoop.apache.org Received: (qmail 26981 invoked by uid 99); 9 Apr 2008 00:44:12 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 08 Apr 2008 17:44:12 -0700 X-ASF-Spam-Status: No, hits=-2000.0 required=10.0 tests=ALL_TRUSTED X-Spam-Check-By: apache.org Received: from [140.211.11.140] (HELO brutus.apache.org) (140.211.11.140) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 09 Apr 2008 00:43:28 +0000 Received: from brutus (localhost [127.0.0.1]) by brutus.apache.org (Postfix) with ESMTP id 715D9234C0C4 for ; Tue, 8 Apr 2008 17:41:24 -0700 (PDT) Message-ID: <1383406852.1207701684463.JavaMail.jira@brutus> Date: Tue, 8 Apr 2008 17:41:24 -0700 (PDT) From: "Raghu Angadi (JIRA)" To: core-dev@hadoop.apache.org Subject: [jira] Commented: (HADOOP-2910) Throttle IPC Client/Server during bursts of requests or server slowdown In-Reply-To: <1655129481.1204139511113.JavaMail.jira@brutus> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-Virus-Checked: Checked by ClamAV on apache.org [ https://issues.apache.org/jira/browse/HADOOP-2910?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12587022#action_12587022 ] Raghu Angadi commented on HADOOP-2910: -------------------------------------- In addition to Doug's comment, though this patch indents accept all the incoming connections, looks like it is limited by the buffer size for the pipe (4k?).. once this buffer is full, Acceptor thread will spin, right? Apart from accept policy, since we handle queue differently with the patch, should queue size be larger (at least in the order of number of client NameNode expects).. right now it is 100*handlers. I think 100 is too low. How would the system behave when 12k clients are expected and queue size is 4k? > Throttle IPC Client/Server during bursts of requests or server slowdown > ----------------------------------------------------------------------- > > Key: HADOOP-2910 > URL: https://issues.apache.org/jira/browse/HADOOP-2910 > Project: Hadoop Core > Issue Type: Improvement > Components: ipc > Affects Versions: 0.16.0 > Reporter: Hairong Kuang > Assignee: Hairong Kuang > Fix For: 0.18.0 > > Attachments: callQueue.patch, callQueue1.patch, callQueue2.patch, callQueue3.patch, throttleClient.patch > > > I propose the following to avoid an IPC server being swarmed by too many requests and connections > 1. Limit call queue length or limit the amount of memory used in the call queue. This can be done by including the size of a request in the header and storing unmarshaled requests in the call queue. > 2. If the call queue is full or queue buffer is full, stop reading requests from sockets. So requests stay at the server's system buffer or at the client side and thus eventually throttle the client. > 3. Limit the total number of connections. Do not accept new connections if the connection limit is exceeded. (Note: this solution is unfair to new connections.) > 4. If receive out of memory exception, close the current connection. -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.