accumulo-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ktur...@apache.org
Subject [accumulo] branch master updated: fix build problems from #458
Date Tue, 08 May 2018 17:20:13 GMT
This is an automated email from the ASF dual-hosted git repository.

kturner pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/accumulo.git


The following commit(s) were added to refs/heads/master by this push:
     new be7475e  fix build problems from #458
be7475e is described below

commit be7475e35a43346b5678039980315126a08c0b28
Author: Keith Turner <kturner@apache.org>
AuthorDate: Tue May 8 13:19:35 2018 -0400

    fix build problems from #458
---
 pom.xml                                                           | 2 +-
 .../org/apache/accumulo/tserver/log/RecoveryLogsIterator.java     | 8 +-------
 .../java/org/apache/accumulo/tserver/log/SortedLogRecovery.java   | 8 +-------
 3 files changed, 3 insertions(+), 15 deletions(-)

diff --git a/pom.xml b/pom.xml
index a76a375..733602e 100644
--- a/pom.xml
+++ b/pom.xml
@@ -808,7 +808,7 @@
             <failOnError>true</failOnError>
             <includeTests>true</includeTests>
             <maxRank>16</maxRank>
-            <jvmArgs>-Dcom.overstock.findbugs.ignore=com.google.common.util.concurrent.RateLimiter,com.google.common.hash.Hasher,com.google.common.hash.HashCode,com.google.common.hash.HashFunction,com.google.common.hash.Hashing,com.google.common.cache.Cache,com.google.common.io.CountingOutputStream,com.google.common.io.ByteStreams,com.google.common.cache.LoadingCache,com.google.common.base.Stopwatch,com.google.common.cache.RemovalNotification,com.google.common.util.concurrent.Uninterrupt
[...]
+            <jvmArgs>-Dcom.overstock.findbugs.ignore=com.google.common.util.concurrent.RateLimiter,com.google.common.hash.Hasher,com.google.common.hash.HashCode,com.google.common.hash.HashFunction,com.google.common.hash.Hashing,com.google.common.cache.Cache,com.google.common.io.CountingOutputStream,com.google.common.io.ByteStreams,com.google.common.cache.LoadingCache,com.google.common.base.Stopwatch,com.google.common.cache.RemovalNotification,com.google.common.util.concurrent.Uninterrupt
[...]
             <plugins>
               <plugin>
                 <groupId>com.overstock.findbugs</groupId>
diff --git a/server/tserver/src/main/java/org/apache/accumulo/tserver/log/RecoveryLogsIterator.java
b/server/tserver/src/main/java/org/apache/accumulo/tserver/log/RecoveryLogsIterator.java
index a68a4ec..64c7af2 100644
--- a/server/tserver/src/main/java/org/apache/accumulo/tserver/log/RecoveryLogsIterator.java
+++ b/server/tserver/src/main/java/org/apache/accumulo/tserver/log/RecoveryLogsIterator.java
@@ -18,7 +18,6 @@ package org.apache.accumulo.tserver.log;
 
 import java.io.IOException;
 import java.util.ArrayList;
-import java.util.Comparator;
 import java.util.List;
 import java.util.Map.Entry;
 
@@ -55,12 +54,7 @@ public class RecoveryLogsIterator implements CloseableIterator<Entry<LogFileKey,
         iterators.add(new RecoveryLogReader(fs, log, start, end));
       }
 
-      iter = Iterators.mergeSorted(iterators, new Comparator<Entry<LogFileKey,LogFileValue>>()
{
-        @Override
-        public int compare(Entry<LogFileKey,LogFileValue> o1, Entry<LogFileKey,LogFileValue>
o2) {
-          return o1.getKey().compareTo(o2.getKey());
-        }
-      });
+      iter = Iterators.mergeSorted(iterators, (o1, o2) -> o1.getKey().compareTo(o2.getKey()));
 
     } catch (RuntimeException | IOException e) {
       try {
diff --git a/server/tserver/src/main/java/org/apache/accumulo/tserver/log/SortedLogRecovery.java
b/server/tserver/src/main/java/org/apache/accumulo/tserver/log/SortedLogRecovery.java
index ebfa92f..6442991 100644
--- a/server/tserver/src/main/java/org/apache/accumulo/tserver/log/SortedLogRecovery.java
+++ b/server/tserver/src/main/java/org/apache/accumulo/tserver/log/SortedLogRecovery.java
@@ -42,7 +42,6 @@ import org.apache.hadoop.fs.Path;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
-import com.google.common.base.Function;
 import com.google.common.collect.Collections2;
 import com.google.common.collect.Iterators;
 import com.google.common.collect.PeekingIterator;
@@ -250,12 +249,7 @@ public class SortedLogRecovery {
   }
 
   Collection<String> asNames(List<Path> recoveryLogs) {
-    return Collections2.transform(recoveryLogs, new Function<Path,String>() {
-      @Override
-      public String apply(Path input) {
-        return input.getName();
-      }
-    });
+    return Collections2.transform(recoveryLogs, Path::getName);
   }
 
   public void recover(KeyExtent extent, List<Path> recoveryLogs, Set<String>
tabletFiles,

-- 
To stop receiving notification emails like this one, please contact
kturner@apache.org.

Mime
View raw message