Return-Path: X-Original-To: apmail-hadoop-hdfs-issues-archive@minotaur.apache.org Delivered-To: apmail-hadoop-hdfs-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 E6F3F1927D for ; Tue, 29 Mar 2016 17:37:25 +0000 (UTC) Received: (qmail 54465 invoked by uid 500); 29 Mar 2016 17:37:25 -0000 Delivered-To: apmail-hadoop-hdfs-issues-archive@hadoop.apache.org Received: (qmail 54403 invoked by uid 500); 29 Mar 2016 17:37:25 -0000 Mailing-List: contact hdfs-issues-help@hadoop.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: hdfs-issues@hadoop.apache.org Delivered-To: mailing list hdfs-issues@hadoop.apache.org Received: (qmail 54384 invoked by uid 99); 29 Mar 2016 17:37:25 -0000 Received: from arcas.apache.org (HELO arcas) (140.211.11.28) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 29 Mar 2016 17:37:25 +0000 Received: from arcas.apache.org (localhost [127.0.0.1]) by arcas (Postfix) with ESMTP id 8D1CC2C14FB for ; Tue, 29 Mar 2016 17:37:25 +0000 (UTC) Date: Tue, 29 Mar 2016 17:37:25 +0000 (UTC) From: "James Clampffer (JIRA)" To: hdfs-issues@hadoop.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Updated] (HDFS-9890) libhdfs++: Add test suite to simulate network issues 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/HDFS-9890?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] James Clampffer updated HDFS-9890: ---------------------------------- Description: I propose adding a test suite to simulate various network issues/failures in order to get good test coverage on some of the retry paths that aren't easy to hit in mock unit tests. At the moment the only things that hit the retry paths are the gmock unit tests. The gmock are only as good as their mock implementations which do a great job of simulating protocol correctness but not more complex interactions. They also can't really simulate the types of lock contention and subtle memory stomps that show up while doing hundreds or thousands of concurrent reads. We should add a new minidfscluster test that focuses on heavy read/seek load and then randomly convert error codes returned by network functions into errors. List of things to simulate(while heavily loaded), roughly in order of how badly I think they need to be tested at the moment: -Rpc connection disconnect -Rpc connection slowed down enough to cause a timeout and trigger retry -DN connection disconnect was: I propose adding a test suite to simulate various network issues/failures in order to get good test coverage on some of the retry paths that aren't easy to hit in unit tests. At the moment the only things that hit the retry paths are the gmock unit tests. The gmock are only as good as their mock implementations which do a great job of simulating protocol correctness but not more complex interactions. They also can't really simulate the types of lock contention and subtle memory stomps that show up while doing hundreds or thousands of concurrent reads. I'd like to make a standalone "bring your own cluster" test suite that can do things like drop connections, slow connections down, and cause connections to hang for short periods of time. I think this should be a standalone test for a few reasons: -The tools for doing this sort of thing inside the tcp/ip stack are platform dependent. On linux it looks like it could be done with iptables but I'm not sure about mac or windows. I can make linux version, but I don't have enough windows and mac experience (or dev hardware) to be productive there. -This needs to scale as large as possible for machines capable of doing it. The CI tests could run a dialed back version but chances of hitting bugs is much lower. There are certain bugs that I've only been able to reproduce when running at sufficient scale. My laptop with 4 physical cores and 1 disk can't sustain the loads that start making lock contention and resource ownership gaps show up; running the client on a 24 core server against a "real" cluster tends to make issues apparent quickly. -As mentioned above, I think some of these bugs won't show up regardless of how long they run on low end hardware e.g. typical dev workstation. It's just not possible to get enough parts moving at once. I don't want people to waste time waiting for operations to run if it's only ever going to be running a few dozen concurrently. I'm not sure what sort of hardware the CI tests run on, but I don't think the rest of the Hadoop community would appreciate a test that attempts to hog all resources for an extended period of time. List of things to simulate(while heavily loaded), roughly in order of how badly I think they need to be tested at the moment: -Rpc connection disconnect -Rpc connection slowed down enough to cause a timeout and trigger retry -DN connection disconnect The initial motivation for filing this is that I've hit a bug 2 times (ever) where the rpc engine can't match a call-id with a request it sent out. I have a guess as to what's causing it, but not enough info to post a meaningful jira (haven't ruled out something else in the process stomping on libhdfs memory). > libhdfs++: Add test suite to simulate network issues > ---------------------------------------------------- > > Key: HDFS-9890 > URL: https://issues.apache.org/jira/browse/HDFS-9890 > Project: Hadoop HDFS > Issue Type: Sub-task > Components: hdfs-client > Reporter: James Clampffer > Assignee: James Clampffer > > I propose adding a test suite to simulate various network issues/failures in order to get good test coverage on some of the retry paths that aren't easy to hit in mock unit tests. > At the moment the only things that hit the retry paths are the gmock unit tests. The gmock are only as good as their mock implementations which do a great job of simulating protocol correctness but not more complex interactions. They also can't really simulate the types of lock contention and subtle memory stomps that show up while doing hundreds or thousands of concurrent reads. We should add a new minidfscluster test that focuses on heavy read/seek load and then randomly convert error codes returned by network functions into errors. > List of things to simulate(while heavily loaded), roughly in order of how badly I think they need to be tested at the moment: > -Rpc connection disconnect > -Rpc connection slowed down enough to cause a timeout and trigger retry > -DN connection disconnect -- This message was sent by Atlassian JIRA (v6.3.4#6332)