Return-Path: X-Original-To: apmail-geode-issues-archive@minotaur.apache.org Delivered-To: apmail-geode-issues-archive@minotaur.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 4200F17F22 for ; Tue, 15 Sep 2015 21:19:47 +0000 (UTC) Received: (qmail 45107 invoked by uid 500); 15 Sep 2015 21:19:47 -0000 Delivered-To: apmail-geode-issues-archive@geode.apache.org Received: (qmail 45073 invoked by uid 500); 15 Sep 2015 21:19:47 -0000 Mailing-List: contact issues-help@geode.incubator.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@geode.incubator.apache.org Delivered-To: mailing list issues@geode.incubator.apache.org Received: (qmail 45058 invoked by uid 99); 15 Sep 2015 21:19:47 -0000 Received: from Unknown (HELO spamd1-us-west.apache.org) (209.188.14.142) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 15 Sep 2015 21:19:47 +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 AB9A4F2C4A for ; Tue, 15 Sep 2015 21:19:46 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd1-us-west.apache.org X-Spam-Flag: NO X-Spam-Score: 1.77 X-Spam-Level: * X-Spam-Status: No, score=1.77 tagged_above=-999 required=6.31 tests=[KAM_ASCII_DIVIDERS=0.8, KAM_LAZY_DOMAIN_SECURITY=1, RCVD_IN_MSPIKE_H3=-0.01, RCVD_IN_MSPIKE_WL=-0.01, T_RP_MATCHES_RCVD=-0.01] autolearn=disabled Received: from mx1-us-west.apache.org ([10.40.0.8]) by localhost (spamd1-us-west.apache.org [10.40.0.7]) (amavisd-new, port 10024) with ESMTP id sPDiaijGEWGl for ; Tue, 15 Sep 2015 21:19:46 +0000 (UTC) Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by mx1-us-west.apache.org (ASF Mail Server at mx1-us-west.apache.org) with SMTP id 2483F20382 for ; Tue, 15 Sep 2015 21:19:46 +0000 (UTC) Received: (qmail 45031 invoked by uid 99); 15 Sep 2015 21:19:45 -0000 Received: from arcas.apache.org (HELO arcas.apache.org) (140.211.11.28) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 15 Sep 2015 21:19:45 +0000 Date: Tue, 15 Sep 2015 21:19:45 +0000 (UTC) From: "Darrel Schneider (JIRA)" To: issues@geode.incubator.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Commented] (GEODE-332) Add thread pooling to peer to peer distribution layer MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 [ https://issues.apache.org/jira/browse/GEODE-332?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14746233#comment-14746233 ] Darrel Schneider commented on GEODE-332: ---------------------------------------- We found when testing network outages that calling close could hang. Bruce attempted to get rid of the async close in 7.0 by setting SO_LINGER but we still saw close hangs. Here is his last comment on this (he made it 3 years ago): {quote} The problem seems to be that we believed that removing the SO_LINGER setting on a tcp/ip socket would keep it from hanging when closed in a situation like this. I removed the spawning of threads to close receiver sockets in the com.gemstone.gemfire.internal.tcp package because of that belief and it seemed to be working. That change has been run through network-down tests many times but maybe we haven't run the pull-the-plug tests very much? I'm going to revert the change and have it spawn threads to do the closing again. {quote} > Add thread pooling to peer to peer distribution layer > ----------------------------------------------------- > > Key: GEODE-332 > URL: https://issues.apache.org/jira/browse/GEODE-332 > Project: Geode > Issue Type: Improvement > Reporter: Darrel Schneider > Assignee: Darrel Schneider > Original Estimate: 48h > Remaining Estimate: 48h > > Every time geode makes a peer-to-peer connection it creates a thread to read from that connection. When the connection is closed it creates another thread to do the socket close in the background just in case the close hangs. For certain use cases the lifetime of these threads can be short but the rate at which they are created can be high. > It would both improve performance and improve memory footprint if these threads were reused from a pool instead of creating them every time. -- This message was sent by Atlassian JIRA (v6.3.4#6332)