@Override
    public void validate(ChangeContext context) {
        boolean nodesUnchanged = context.previousModel().allocatedHosts().equals(context.model().allocatedHosts());
        boolean contentUnchanged = contentHostsOf(context.previousModel()).equals(contentHostsOf(context.model()));
        for (ContainerCluster<ApplicationContainer> cluster : context.model().getContainerClusters().values()) {
            cluster.getContainers().stream()
                   .filter(container -> isExistingContainer(container, context.previousModel()))
                   .filter(container -> shouldContainerRestartOnDeploy(container, context.model()))
                   .map(container -> createConfigChangeAction(cluster.id(), container, context.model(), nodesUnchanged, contentUnchanged))
                   .forEach(context::require);
        }
    }
Returns a restart action for each container that has turned on {@link QrConfig#restartOnDeploy()}.

@author bjorncs
config-model/src/main/java/com/yahoo/vespa/model/application/validation/change/ContainerRestartValidator.java