aboutsummaryrefslogtreecommitdiffstats
path: root/container-core/src/main/java/com/yahoo/container/di/componentgraph/core/ComponentRegistryNode.java
diff options
context:
space:
mode:
Diffstat (limited to 'container-core/src/main/java/com/yahoo/container/di/componentgraph/core/ComponentRegistryNode.java')
-rw-r--r--container-core/src/main/java/com/yahoo/container/di/componentgraph/core/ComponentRegistryNode.java9
1 files changed, 3 insertions, 6 deletions
diff --git a/container-core/src/main/java/com/yahoo/container/di/componentgraph/core/ComponentRegistryNode.java b/container-core/src/main/java/com/yahoo/container/di/componentgraph/core/ComponentRegistryNode.java
index ca10072c6c9..8b5fb128e2b 100644
--- a/container-core/src/main/java/com/yahoo/container/di/componentgraph/core/ComponentRegistryNode.java
+++ b/container-core/src/main/java/com/yahoo/container/di/componentgraph/core/ComponentRegistryNode.java
@@ -8,10 +8,8 @@ import com.yahoo.component.provider.ComponentRegistry;
import com.yahoo.config.ConfigInstance;
import com.yahoo.vespa.config.ConfigKey;
-import java.util.Collections;
import java.util.List;
import java.util.Set;
-import java.util.stream.Collectors;
/**
* @author Tony Vaagenes
@@ -20,7 +18,7 @@ import java.util.stream.Collectors;
*/
public class ComponentRegistryNode extends Node {
- private static ComponentId componentRegistryNamespace = ComponentId.fromString("ComponentRegistry");
+ private static final ComponentId componentRegistryNamespace = ComponentId.fromString("ComponentRegistry");
private final Class<?> componentClass;
@@ -63,7 +61,7 @@ public class ComponentRegistryNode extends Node {
@Override
public Set<ConfigKey<ConfigInstance>> configKeys() {
- return Collections.emptySet();
+ return Set.of();
}
@Override
@@ -76,8 +74,7 @@ public class ComponentRegistryNode extends Node {
@Override
public boolean equals(Object other) {
- if (other instanceof ComponentRegistryNode) {
- ComponentRegistryNode that = (ComponentRegistryNode) other;
+ if (other instanceof ComponentRegistryNode that) {
return this.componentId().equals(that.componentId()) && this.instanceType().equals(that.instanceType())
&& equalNodeEdges(this.usedComponents(), that.usedComponents());
} else {