@Test public void disabledTasksTest() { NodeAgentContext context1 = createContextWithDisabledTasks(); assertFalse(context1.isDisabled(NodeAgentTask.DiskCleanup)); assertFalse(context1.isDisabled(NodeAgentTask.CoreDumps)); NodeAgentContext context2 = createContextWithDisabledTasks("root>UpgradeTask", "DiskCleanup", "node>CoreDumps"); assertFalse(context2.isDisabled(NodeAgentTask.DiskCleanup)); assertTrue(context2.isDisabled(NodeAgentTask.CoreDumps)); }
@Override public boolean isDisabled(NodeAgentTask task) { return disabledNodeAgentTasks.contains(task); }
NodeAgentContextImpl implements NodeAgentContext { @Override public boolean isDisabled(NodeAgentTask task) { return disabledNodeAgentTasks.contains(task); } }
NodeAgentContextImpl implements NodeAgentContext { @Override public boolean isDisabled(NodeAgentTask task) { return disabledNodeAgentTasks.contains(task); } NodeAgentContextImpl(NodeSpec node, Acl acl, AthenzIdentity identity,
                                DockerNetworking dockerNetworking, ZoneApi zone,
                                FileSystem fileSystem, FlagSource flagSource,
                                Path pathToContainerStorage, Path pathToVespaHome,
                                String vespaUser, String vespaUserOnHost, double cpuSpeedup); }
NodeAgentContextImpl implements NodeAgentContext { @Override public boolean isDisabled(NodeAgentTask task) { return disabledNodeAgentTasks.contains(task); } NodeAgentContextImpl(NodeSpec node, Acl acl, AthenzIdentity identity,
                                DockerNetworking dockerNetworking, ZoneApi zone,
                                FileSystem fileSystem, FlagSource flagSource,
                                Path pathToContainerStorage, Path pathToVespaHome,
                                String vespaUser, String vespaUserOnHost, double cpuSpeedup); @Override NodeSpec node(); @Override Acl acl(); @Override ContainerName containerName(); @Override AthenzIdentity identity(); @Override DockerNetworking dockerNetworking(); @Override ZoneApi zone(); @Override String vespaUser(); @Override String vespaUserOnHost(); @Override boolean isDisabled(NodeAgentTask task); @Override double unscaledVcpu(); @Override FileSystem fileSystem(); @Override Path pathOnHostFromPathInNode(Path pathInNode); @Override Path pathInNodeFromPathOnHost(Path pathOnHost); @Override Path pathInNodeUnderVespaHome(Path relativePath); @Override void recordSystemModification(Logger logger, String message); @Override void log(Logger logger, Level level, String message); @Override void log(Logger logger, Level level, String message, Throwable throwable); @Override String toString(); }
NodeAgentContextImpl implements NodeAgentContext { @Override public boolean isDisabled(NodeAgentTask task) { return disabledNodeAgentTasks.contains(task); } NodeAgentContextImpl(NodeSpec node, Acl acl, AthenzIdentity identity,
                                DockerNetworking dockerNetworking, ZoneApi zone,
                                FileSystem fileSystem, FlagSource flagSource,
                                Path pathToContainerStorage, Path pathToVespaHome,
                                String vespaUser, String vespaUserOnHost, double cpuSpeedup); @Override NodeSpec node(); @Override Acl acl(); @Override ContainerName containerName(); @Override AthenzIdentity identity(); @Override DockerNetworking dockerNetworking(); @Override ZoneApi zone(); @Override String vespaUser(); @Override String vespaUserOnHost(); @Override boolean isDisabled(NodeAgentTask task); @Override double unscaledVcpu(); @Override FileSystem fileSystem(); @Override Path pathOnHostFromPathInNode(Path pathInNode); @Override Path pathInNodeFromPathOnHost(Path pathOnHost); @Override Path pathInNodeUnderVespaHome(Path relativePath); @Override void recordSystemModification(Logger logger, String message); @Override void log(Logger logger, Level level, String message); @Override void log(Logger logger, Level level, String message, Throwable throwable); @Override String toString();  }