Skip to content
Permalink
Browse files
HBASE-23124 Remove commons-lang3 dependency (#41)
Signed-off-by: Michael Stack <stack@apache.org>
  • Loading branch information
petersomogyi committed Oct 7, 2019
1 parent 6cb31c6 commit e4f73fb8e4a640cfbda657523581d6523519fab0
Showing 5 changed files with 4 additions and 19 deletions.
@@ -175,10 +175,6 @@
<version>${hbase-thirdparty.version}</version>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>org.apache.commons</groupId>
<artifactId>commons-lang3</artifactId>
</dependency>

<!--We want to use the shaded client but for testing, we need to rely on hbase-server.
HBASE-15666 is about how shaded-client and hbase-server won't work together.
@@ -17,8 +17,6 @@
*/
package org.apache.hbase;

import org.apache.commons.lang3.StringUtils;

/**
* Check versions.
*/
@@ -94,9 +92,9 @@ private static String[] getVersionComponents(final String version) {

String[] comps = new String[strComps.length];
for (int i = 0; i < strComps.length; ++i) {
if (StringUtils.isNumeric(strComps[i])) {
if (strComps[i].matches("\\d+")) {
comps[i] = strComps[i];
} else if (StringUtils.isEmpty(strComps[i])) {
} else if (strComps[i] == null || strComps[i].isEmpty()) {
comps[i] = String.valueOf(VERY_LARGE_NUMBER);
} else {
if("SNAPSHOT".equals(strComps[i])) {
@@ -61,7 +61,6 @@
import java.util.concurrent.atomic.AtomicInteger;
import java.util.stream.Collectors;
import org.apache.commons.io.IOUtils;
import org.apache.commons.lang3.StringUtils;
import org.apache.hadoop.conf.Configuration;
import org.apache.hadoop.conf.Configured;
import org.apache.hadoop.fs.FSDataOutputStream;
@@ -5407,7 +5406,7 @@ private void setRepairHolesFlags() {

public HBaseFsck exec(ExecutorService exec, String[] args)
throws KeeperException, IOException, InterruptedException, ReplicationException {
errors.print("HBaseFsck command line options: " + StringUtils.join(args, " "));
errors.print("HBaseFsck command line options: " + String.join(" ", args));
CommandLineData cld = new CommandLineData();
doCommandLine(args, cld);

@@ -19,8 +19,6 @@

import java.io.IOException;

import org.apache.commons.lang3.StringUtils;

import org.apache.hadoop.conf.Configuration;
import org.apache.hadoop.fs.Path;
import org.apache.hadoop.hbase.HBaseConfiguration;
@@ -105,7 +103,7 @@ public static void main(String[] args) throws Exception {
}
}

System.out.println("OfflineMetaRepair command line options: " + StringUtils.join(args, " "));
System.out.println("OfflineMetaRepair command line options: " + String.join(" ", args));

// Fsck doesn't shutdown and and doesn't provide a way to shutdown its
// threads cleanly, so we do a System.exit.
@@ -134,7 +134,6 @@
<checkstyle.version>8.11</checkstyle.version>
<maven.checkstyle.version>3.0.0</maven.checkstyle.version>
<hbase.checkstyle.version>2.2.0</hbase.checkstyle.version>
<commons-lang3.version>3.9</commons-lang3.version>
<enforcer.version>3.0.0-M2</enforcer.version>
<extra.enforcer.version>1.0-beta-9</extra.enforcer.version>
</properties>
@@ -145,11 +144,6 @@
<artifactId>hbase-zookeeper</artifactId>
<version>${hbase.version}</version>
</dependency>
<dependency>
<groupId>org.apache.commons</groupId>
<artifactId>commons-lang3</artifactId>
<version>${commons-lang3.version}</version>
</dependency>
<dependency>
<groupId>org.apache.hbase.operator.tools</groupId>
<artifactId>hbase-hbck2</artifactId>

0 comments on commit e4f73fb

Please sign in to comment.