Do not use Guava in features-test-plugin 65/110065/2
authorRobert Varga <robert.varga@pantheon.tech>
Sun, 28 Jan 2024 21:08:49 +0000 (22:08 +0100)
committerRobert Varga <robert.varga@pantheon.tech>
Sun, 28 Jan 2024 21:42:43 +0000 (22:42 +0100)
Let's keep our coding dependencies minimal.

JIRA: ODLPARENT-262
Change-Id: I0addf87a61bd6c0770a66ee04257d55948e1bc60
Signed-off-by: Robert Varga <robert.varga@pantheon.tech>
features-test-plugin/src/main/java/org/opendaylight/odlparent/features/test/plugin/TestProbe.java

index a4c666ec3f52a561c535d1fca9453b1cd24f946f..7385307548765bd44aab24c940590794a16c14d4 100644 (file)
@@ -10,7 +10,6 @@ package org.opendaylight.odlparent.features.test.plugin;
 import static org.apache.karaf.bundle.core.BundleState.Installed;
 import static org.apache.karaf.bundle.core.BundleState.Waiting;
 
-import com.google.common.base.Functions;
 import java.io.File;
 import java.net.URI;
 import java.util.Arrays;
@@ -23,6 +22,7 @@ import java.util.concurrent.ExecutionException;
 import java.util.concurrent.TimeUnit;
 import java.util.concurrent.TimeoutException;
 import java.util.concurrent.atomic.AtomicReference;
+import java.util.function.Function;
 import java.util.stream.Collectors;
 import javax.inject.Inject;
 import org.apache.karaf.bundle.core.BundleService;
@@ -217,7 +217,7 @@ public final class TestProbe {
                         Arrays.stream(serviceRef.getUsingBundles()).map(Bundle::getSymbolicName).toList();
                     final var propKeys = serviceRef.getPropertyKeys();
                     final var serviceProps = Arrays.stream(propKeys)
-                        .collect(Collectors.toMap(Functions.identity(), serviceRef::getProperty));
+                        .collect(Collectors.toMap(Function.identity(), serviceRef::getProperty));
                     LOG.warn("NOK Service {} -> of bundle: {}, using: {}, props: {}",
                         serviceRef.getClass().getName(), bundle.getSymbolicName(), usingBundles, serviceProps);
                 }