Return-Path: X-Original-To: apmail-hbase-issues-archive@www.apache.org Delivered-To: apmail-hbase-issues-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id AAF9E7335 for ; Fri, 2 Sep 2011 03:22:49 +0000 (UTC) Received: (qmail 92502 invoked by uid 500); 2 Sep 2011 03:22:47 -0000 Delivered-To: apmail-hbase-issues-archive@hbase.apache.org Received: (qmail 92168 invoked by uid 500); 2 Sep 2011 03:22:37 -0000 Mailing-List: contact issues-help@hbase.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Delivered-To: mailing list issues@hbase.apache.org Received: (qmail 92150 invoked by uid 99); 2 Sep 2011 03:22:33 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 02 Sep 2011 03:22:33 +0000 X-ASF-Spam-Status: No, hits=-2000.5 required=5.0 tests=ALL_TRUSTED,RP_MATCHES_RCVD X-Spam-Check-By: apache.org Received: from [140.211.11.116] (HELO hel.zones.apache.org) (140.211.11.116) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 02 Sep 2011 03:22:30 +0000 Received: from hel.zones.apache.org (hel.zones.apache.org [140.211.11.116]) by hel.zones.apache.org (Postfix) with ESMTP id 2063637EBF for ; Fri, 2 Sep 2011 03:22:10 +0000 (UTC) Date: Fri, 2 Sep 2011 03:22:10 +0000 (UTC) From: "Jonathan Hsieh (JIRA)" To: issues@hbase.apache.org Message-ID: <265481651.9242.1314933730129.JavaMail.tomcat@hel.zones.apache.org> In-Reply-To: <1569343419.9144.1314930069812.JavaMail.tomcat@hel.zones.apache.org> Subject: [jira] [Commented] (HBASE-4326) Tests that use HBaseTestingUtility.startMiniCluster(n) should shutdown with HBaseTestingUtility.shutdownMiniCluster. 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/HBASE-4326?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13095742#comment-13095742 ] Jonathan Hsieh commented on HBASE-4326: --------------------------------------- Its seems to generate a random dir unless a test.build.data system property is set. If it is set the entire suite of tests may clash. How does one get the properties set before the build/test suites are run? > Tests that use HBaseTestingUtility.startMiniCluster(n) should shutdown with HBaseTestingUtility.shutdownMiniCluster. > -------------------------------------------------------------------------------------------------------------------- > > Key: HBASE-4326 > URL: https://issues.apache.org/jira/browse/HBASE-4326 > Project: HBase > Issue Type: Bug > Affects Versions: 0.90.4 > Reporter: Jonathan Hsieh > > Most tests that use mini clusters use this pattern > {code} > private final static HBaseTestingUtility UTIL = new HBaseTestingUtility(); > @BeforeClass > public static void beforeClass() throws Exception { > UTIL.startMiniCluster(1); > } > @AfterClass > public static void afterClass() throws IOException { > UTIL.shutdownMiniCluster(); > } > {code} > Some tests (like hbase-4269) > {code} > @BeforeClass > public static void beforeClass() throws Exception { > UTIL.startMiniCluster(1); > } > @AfterClass > public static void afterClass() throws IOException { > UTIL.getMiniCluster().shutdown(); > // or UTIL.shutdownMiniHBaseCluster(); > // and likely others. > } > {code} > There is a difference between the two shutdown -- the former deletes files created during the tests while the latter does not. This funny state persisting (zk or hbase/mr data) may be the cause of strange inter-testcase problems when full suites are run. -- This message is automatically generated by JIRA. For more information on JIRA, see: http://www.atlassian.com/software/jira