Return-Path: X-Original-To: apmail-accumulo-commits-archive@www.apache.org Delivered-To: apmail-accumulo-commits-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id A935017C8A for ; Mon, 23 Mar 2015 22:44:09 +0000 (UTC) Received: (qmail 98043 invoked by uid 500); 23 Mar 2015 22:44:06 -0000 Delivered-To: apmail-accumulo-commits-archive@accumulo.apache.org Received: (qmail 97996 invoked by uid 500); 23 Mar 2015 22:44:06 -0000 Mailing-List: contact commits-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 commits@accumulo.apache.org Received: (qmail 97981 invoked by uid 99); 23 Mar 2015 22:44:06 -0000 Received: from git1-us-west.apache.org (HELO git1-us-west.apache.org) (140.211.11.23) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 23 Mar 2015 22:44:06 +0000 Received: by git1-us-west.apache.org (ASF Mail Server at git1-us-west.apache.org, from userid 33) id 6F74FE1825; Mon, 23 Mar 2015 22:44:06 +0000 (UTC) Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit From: elserj@apache.org To: commits@accumulo.apache.org Date: Mon, 23 Mar 2015 22:44:06 -0000 Message-Id: <73be0fbfbb90431b84482b8ba7066214@git.apache.org> X-Mailer: ASF-Git Admin Mailer Subject: [1/3] accumulo git commit: ACCUMULO-3692 Fix checkstyle and remove test. Repository: accumulo Updated Branches: refs/heads/1.6 43e90022e -> 85942da72 refs/heads/master a1439e330 -> bbf5b7c3e ACCUMULO-3692 Fix checkstyle and remove test. Test relies on API that only exists in 1.7. Can't be in 1.7 as is. Project: http://git-wip-us.apache.org/repos/asf/accumulo/repo Commit: http://git-wip-us.apache.org/repos/asf/accumulo/commit/85942da7 Tree: http://git-wip-us.apache.org/repos/asf/accumulo/tree/85942da7 Diff: http://git-wip-us.apache.org/repos/asf/accumulo/diff/85942da7 Branch: refs/heads/1.6 Commit: 85942da722f012c4f44f9b01e4cfd912cd9dd7b9 Parents: 43e9002 Author: Josh Elser Authored: Mon Mar 23 18:27:13 2015 -0400 Committer: Josh Elser Committed: Mon Mar 23 18:27:13 2015 -0400 ---------------------------------------------------------------------- .../accumulo/master/TabletGroupWatcher.java | 1 - .../test/BalanceWithOfflineTableIT.java | 90 -------------------- 2 files changed, 91 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/accumulo/blob/85942da7/server/master/src/main/java/org/apache/accumulo/master/TabletGroupWatcher.java ---------------------------------------------------------------------- diff --git a/server/master/src/main/java/org/apache/accumulo/master/TabletGroupWatcher.java b/server/master/src/main/java/org/apache/accumulo/master/TabletGroupWatcher.java index e86edf3..e04e2e5 100644 --- a/server/master/src/main/java/org/apache/accumulo/master/TabletGroupWatcher.java +++ b/server/master/src/main/java/org/apache/accumulo/master/TabletGroupWatcher.java @@ -47,7 +47,6 @@ import org.apache.accumulo.core.data.PartialKey; import org.apache.accumulo.core.data.Range; import org.apache.accumulo.core.data.Value; import org.apache.accumulo.core.master.state.tables.TableState; -import org.apache.accumulo.core.master.thrift.MasterState; import org.apache.accumulo.core.master.thrift.TabletServerStatus; import org.apache.accumulo.core.metadata.MetadataTable; import org.apache.accumulo.core.metadata.RootTable; http://git-wip-us.apache.org/repos/asf/accumulo/blob/85942da7/test/src/test/java/org/apache/accumulo/test/BalanceWithOfflineTableIT.java ---------------------------------------------------------------------- diff --git a/test/src/test/java/org/apache/accumulo/test/BalanceWithOfflineTableIT.java b/test/src/test/java/org/apache/accumulo/test/BalanceWithOfflineTableIT.java deleted file mode 100644 index 86468c5..0000000 --- a/test/src/test/java/org/apache/accumulo/test/BalanceWithOfflineTableIT.java +++ /dev/null @@ -1,90 +0,0 @@ -/* - * Licensed to the Apache Software Foundation (ASF) under one or more - * contributor license agreements. See the NOTICE file distributed with - * this work for additional information regarding copyright ownership. - * The ASF licenses this file to You under the Apache License, Version 2.0 - * (the "License"); you may not use this file except in compliance with - * the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - package org.apache.accumulo.test; - -import java.util.SortedSet; -import java.util.TreeSet; -import java.util.concurrent.Callable; -import java.util.concurrent.Future; -import java.util.concurrent.TimeUnit; - -import org.apache.accumulo.core.client.Connector; -import org.apache.accumulo.core.util.SimpleThreadPool; -import org.apache.accumulo.minicluster.impl.MiniAccumuloConfigImpl; -import org.apache.accumulo.test.functional.ConfigurableMacIT; -import org.apache.hadoop.conf.Configuration; -import org.apache.hadoop.io.Text; -import org.junit.Test; - -// ACCUMULO-3692 -public class BalanceWithOfflineTableIT extends ConfigurableMacIT { - - @Override - protected int defaultTimeoutSeconds() { - return 30; - } - - @Override - protected void configure(MiniAccumuloConfigImpl cfg, Configuration hadoopCoreSite) { - } - - @Test - public void test() throws Exception { - final String tableNames[] = getUniqueNames(2); - final String tableName = tableNames[0]; - // create a table with a bunch of splits - - final Connector c = getConnector(); - log.info("Creating table " + tableName); - c.tableOperations().create(tableName);; - final SortedSet splits = new TreeSet<>(); - for (String split : "a,b,c,d,e,f,g,h,i,j,k,l,m,n,o,p,q,r,s,t,u,v,w,x,y,z".split(",")) { - splits.add(new Text(split)); - } - log.info("Splitting table " + tableName); - c.tableOperations().addSplits(tableName, splits); - log.info("Balancing"); - c.instanceOperations().waitForBalance(); - log.info("Balanced"); - - // create a new table which will unbalance the cluster - final String table2 = tableNames[1]; - log.info("Creating table " + table2); - c.tableOperations().create(table2); - log.info("Creating splits " + table2); - c.tableOperations().addSplits(table2, splits); - - // offline the table, hopefully while there are some migrations going on - log.info("Offlining " + table2); - c.tableOperations().offline(table2, true); - log.info("Offlined " + table2); - - log.info("Waiting for balance"); - - SimpleThreadPool pool = new SimpleThreadPool(1, "waitForBalance"); - Future wait = pool.submit(new Callable() { - @Override - public Boolean call() throws Exception { - c.instanceOperations().waitForBalance(); - return true; - } - }); - wait.get(20, TimeUnit.SECONDS); - log.info("Balance succeeded with an offline table"); - } - -}