X-Git-Url: https://git.opendaylight.org/gerrit/gitweb?a=blobdiff_plain;f=opendaylight%2Fmd-sal%2Fsal-remoterpc-connector%2Fsrc%2Ftest%2Fjava%2Forg%2Fopendaylight%2Fcontroller%2Fremote%2Frpc%2Fregistry%2FRpcRegistryTest.java;h=18b2f9f6e0769383b4c32a8d46c4b364129585f5;hb=HEAD;hp=d552ad5f1294ff6164618b0cb7c37d0d8c4ce241;hpb=1d0370feb32b84119bf4c570b9e6e9abbe8d9511;p=controller.git diff --git a/opendaylight/md-sal/sal-remoterpc-connector/src/test/java/org/opendaylight/controller/remote/rpc/registry/RpcRegistryTest.java b/opendaylight/md-sal/sal-remoterpc-connector/src/test/java/org/opendaylight/controller/remote/rpc/registry/RpcRegistryTest.java index d552ad5f12..18b2f9f6e0 100644 --- a/opendaylight/md-sal/sal-remoterpc-connector/src/test/java/org/opendaylight/controller/remote/rpc/registry/RpcRegistryTest.java +++ b/opendaylight/md-sal/sal-remoterpc-connector/src/test/java/org/opendaylight/controller/remote/rpc/registry/RpcRegistryTest.java @@ -27,7 +27,6 @@ import com.google.common.base.Stopwatch; import com.google.common.collect.Sets; import com.google.common.util.concurrent.Uninterruptibles; import com.typesafe.config.ConfigFactory; -import java.net.URI; import java.time.Duration; import java.util.ArrayList; import java.util.Arrays; @@ -305,7 +304,7 @@ public class RpcRegistryTest { assertNotNull(maybeEndpoint); assertTrue(maybeEndpoint.isPresent()); - final RemoteRpcEndpoint endpoint = maybeEndpoint.get(); + final RemoteRpcEndpoint endpoint = maybeEndpoint.orElseThrow(); final ActorRef router = endpoint.getRouter(); assertNotNull(router); @@ -369,7 +368,7 @@ public class RpcRegistryTest { final int nRoutes = 500; final Collection added = new ArrayList<>(nRoutes); for (int i = 0; i < nRoutes; i++) { - final DOMRpcIdentifier routeId = DOMRpcIdentifier.create(QName.create(URI.create("/mockrpc"), "type" + i)); + final DOMRpcIdentifier routeId = DOMRpcIdentifier.create(QName.create("/mockrpc", "type" + i)); added.add(routeId); //Uninterruptibles.sleepUninterruptibly(50, TimeUnit.MILLISECONDS); @@ -402,7 +401,7 @@ public class RpcRegistryTest { } private List createRouteIds() { - QName type = QName.create(URI.create("/mockrpc"), "mockrpc" + routeIdCounter++); + QName type = QName.create("/mockrpc", "mockrpc" + routeIdCounter++); List routeIds = new ArrayList<>(1); routeIds.add(DOMRpcIdentifier.create(type)); return routeIds;