Prechádzať zdrojové kódy

Remove HighLevelRestClient from CCSDuelIT (#102222)

Ignacio Vera 1 rok pred
rodič
commit
c579ab2d4a

+ 10 - 2
libs/core/src/main/java/org/elasticsearch/core/CheckedConsumer.java

@@ -8,12 +8,20 @@
 
 package org.elasticsearch.core;
 
-import java.util.function.Consumer;
+import java.util.Objects;
 
 /**
- * A {@link Consumer}-like interface which allows throwing checked exceptions.
+ * A {@link java.util.function.Consumer}-like interface which allows throwing checked exceptions.
  */
 @FunctionalInterface
 public interface CheckedConsumer<T, E extends Exception> {
     void accept(T t) throws E;
+
+    default CheckedConsumer<T, E> andThen(CheckedConsumer<? super T, E> after) throws E {
+        Objects.requireNonNull(after);
+        return (T t) -> {
+            accept(t);
+            after.accept(t);
+        };
+    }
 }

Rozdielové dáta súboru neboli zobrazené, pretože súbor je príliš veľký
+ 311 - 335
qa/multi-cluster-search/src/test/java/org/elasticsearch/search/CCSDuelIT.java


Niektoré súbory nie sú zobrazené, pretože je v týchto rozdielových dátach zmenené mnoho súborov