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 8EDFE9567 for ; Fri, 3 Feb 2012 06:58:37 +0000 (UTC) Received: (qmail 90625 invoked by uid 500); 3 Feb 2012 06:58:36 -0000 Delivered-To: apmail-hbase-issues-archive@hbase.apache.org Received: (qmail 90438 invoked by uid 500); 3 Feb 2012 06:58:24 -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 90418 invoked by uid 99); 3 Feb 2012 06:58:17 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 03 Feb 2012 06:58:17 +0000 X-ASF-Spam-Status: No, hits=-2000.0 required=5.0 tests=ALL_TRUSTED,T_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, 03 Feb 2012 06:58:14 +0000 Received: from hel.zones.apache.org (hel.zones.apache.org [140.211.11.116]) by hel.zones.apache.org (Postfix) with ESMTP id 83EDF18AB3F for ; Fri, 3 Feb 2012 06:57:53 +0000 (UTC) Date: Fri, 3 Feb 2012 06:57:53 +0000 (UTC) From: "stack (Updated) (JIRA)" To: issues@hbase.apache.org Message-ID: <2039008841.6691.1328252273542.JavaMail.tomcat@hel.zones.apache.org> In-Reply-To: <727713864.6682.1328251674038.JavaMail.tomcat@hel.zones.apache.org> Subject: [jira] [Updated] (HBASE-5328) Small changes to Master to make it more testable MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 X-Virus-Checked: Checked by ClamAV on apache.org [ https://issues.apache.org/jira/browse/HBASE-5328?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] stack updated HBASE-5328: ------------------------- Attachment: 5328.txt Need to finish more tests to prove these changes enough (also need to make it so you don't need to know that much about Master's workings writing tests). M src/main/java/org/apache/hadoop/hbase/catalog/CatalogTracker.java (waitForRoot) Remove toxic method M src/main/java/org/apache/hadoop/hbase/master/AssignmentManager.java Javadoc and added check of master still running in a few strategic places so we don't do infinite loop. M src/main/java/org/apache/hadoop/hbase/master/HMaster.java Refactor moving the instant schema change out to its own method. Added flag to indicate when master can receive RPCs. (createCatalogTracker, createServerManager, getRemoteInetAddress): put these creations out in methods so can override in tests to insert mocks, etc. A src/test/java/org/apache/hadoop/hbase/master/MockRegionServer.java Added a mock regionserver in the master package for testing master A src/test/java/org/apache/hadoop/hbase/master/Mocking.java Utility shared by tests in the master package A src/test/java/org/apache/hadoop/hbase/master/TestMasterNoCluster.java A few tests that put up master and poke it to make it move through states. Patch is not done. Need to remove the gratuitous changes. Also need to add some tests that simulate some of the states that Ram and crew are finding. > Small changes to Master to make it more testable > ------------------------------------------------ > > Key: HBASE-5328 > URL: https://issues.apache.org/jira/browse/HBASE-5328 > Project: HBase > Issue Type: Task > Reporter: stack > Attachments: 5328.txt > > > Here are some small changes in Master that make it more testable. Included tests stand up a Master and then fake it into thinking that three regionservers are registering making master assign root and meta, etc. -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa For more information on JIRA, see: http://www.atlassian.com/software/jira