Return-Path: X-Original-To: apmail-accumulo-dev-archive@www.apache.org Delivered-To: apmail-accumulo-dev-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id BED0711479 for ; Thu, 3 Apr 2014 21:33:58 +0000 (UTC) Received: (qmail 25928 invoked by uid 500); 3 Apr 2014 21:33:58 -0000 Delivered-To: apmail-accumulo-dev-archive@accumulo.apache.org Received: (qmail 25679 invoked by uid 500); 3 Apr 2014 21:33:57 -0000 Mailing-List: contact dev-help@accumulo.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@accumulo.apache.org Delivered-To: mailing list dev@accumulo.apache.org Received: (qmail 25662 invoked by uid 99); 3 Apr 2014 21:33:56 -0000 Received: from reviews-vm.apache.org (HELO reviews.apache.org) (140.211.11.40) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 03 Apr 2014 21:33:56 +0000 Received: from reviews.apache.org (localhost [127.0.0.1]) by reviews.apache.org (Postfix) with ESMTP id BF2A71D43C7; Thu, 3 Apr 2014 21:33:52 +0000 (UTC) Content-Type: multipart/alternative; boundary="===============0737099313032518893==" MIME-Version: 1.0 Subject: Re: Review Request 19804: ACCUMULO-2519 Aborts upgrade if there are Fate transactions from an old version. From: keith@deenlo.com To: keith@deenlo.com Cc: "accumulo" , "Sean Busbey" Date: Thu, 03 Apr 2014 21:33:52 -0000 Message-ID: <20140403213352.18230.82810@reviews.apache.org> X-ReviewBoard-URL: https://reviews.apache.org Auto-Submitted: auto-generated Sender: noreply@reviews.apache.org X-ReviewGroup: accumulo X-ReviewRequest-URL: https://reviews.apache.org/r/19804/ X-Sender: noreply@reviews.apache.org References: <20140403200812.18371.82270@reviews.apache.org> In-Reply-To: <20140403200812.18371.82270@reviews.apache.org> Reply-To: keith@deenlo.com X-ReviewRequest-Repository: accumulo --===============0737099313032518893== Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit > On April 3, 2014, 8:08 p.m., kturner wrote: > > server/src/main/java/org/apache/accumulo/server/master/Master.java, line 276 > > > > > > this should be volatile because upgradeZookeeper() and upgradeMetadata() will be run by separate threads. > > Sean Busbey wrote: > in reading the code, I thought upgradeZooKeeper had to happen prior to the thread that calls upgradeMetadata being created. Am I reading the code wrong? > > Master.run() calls getMasterLock (which is synchronous) and then several lines later creates the status thread and starts it. OK. I did not look at the calling methods. Actually, setMasterState() is whats synchronized, and that method calls both upgradeZooKeeper() and upgradeMetadata(). So different threads will see any changes other threads make to the boolean. So it does not need to be volatile. I also think upgradeZooKeeper will be called before upgradeMetadata. - kturner ----------------------------------------------------------- This is an automatically generated e-mail. To reply, visit: https://reviews.apache.org/r/19804/#review39468 ----------------------------------------------------------- On April 2, 2014, 3:10 p.m., Sean Busbey wrote: > > ----------------------------------------------------------- > This is an automatically generated e-mail. To reply, visit: > https://reviews.apache.org/r/19804/ > ----------------------------------------------------------- > > (Updated April 2, 2014, 3:10 p.m.) > > > Review request for accumulo and kturner. > > > Bugs: ACCUMULO-2519 > https://issues.apache.org/jira/browse/ACCUMULO-2519 > > > Repository: accumulo > > > Description > ------- > > Adds "make sure Fate has no outstanding items" to the upgrade instructions. Makes sure the master and tabletservers don't take upgrade steps if they see fate ops waiting. > > > Diffs > ----- > > README 115a9b7 > server/src/main/java/org/apache/accumulo/server/Accumulo.java 99ec7e4 > server/src/main/java/org/apache/accumulo/server/master/Master.java 8c4c864 > server/src/main/java/org/apache/accumulo/server/tabletserver/TabletServer.java d76946d > server/src/main/java/org/apache/accumulo/server/util/MetadataTable.java 7328a55 > > Diff: https://reviews.apache.org/r/19804/diff/ > > > Testing > ------- > > Took a 1.4.5-SNAP cluster > > * loaded test data in a variety of table configs > * alternate table creation and deletion > * load additional table to cause !METADATA churn > * shutdown cluster uncleanly > * verified waiting Fate transactions (table deletion at success status) > * verified waiting local WALs > * verified waiting local WALs include !METADATA table (via LogReader) > * verified /accumulo/version showed 4 > * Start upgrade to 1.5.2-SNAP > * verified errors showing no upgrade and to go back to docs in: monitor, master logs, tabletserver logs > * verified same waiting Fate transactions > * verified same waiting local WALs > * verified /accumulo/version showed 4 > * Cleared Fate operations > * Start upgrade to 1.5.2-SNAP > * wait a terrifying long amount of time, check on progress via local logs > * verify no errors shown for upgrade > * verified WALs copied to HDFS > * verified /accumulo/version showed 5 > * verified monitor showed normal start up > * wait for all tablets to be hosted > * verify test data > > > Thanks, > > Sean Busbey > > --===============0737099313032518893==--