Load minimal set of config model versions in all zones
@@ -9,9 +9,7 @@ import com.yahoo.config.model.api.ModelFactory;
import com.yahoo.config.provision.AllocatedHosts;
import com.yahoo.config.provision.ApplicationId;
import com.yahoo.config.provision.ApplicationLockException;
-import com.yahoo.config.provision.Environment;
import com.yahoo.config.provision.OutOfCapacityException;
-import com.yahoo.config.provision.SystemName;
import com.yahoo.config.provision.Version;
import com.yahoo.config.provision.Zone;
import com.yahoo.lang.SettableOptional;
@@ -22,7 +20,6 @@ import com.yahoo.vespa.config.server.provision.StaticProvisioner;
import java.time.Instant;
import java.util.ArrayList;
-import java.util.Arrays;
import java.util.Collections;
import java.util.Comparator;
import java.util.List;
@@ -166,11 +163,7 @@ public abstract class ModelsBuilder<MODELRESULT extends ModelResult> {
}
private Set<Version> versionsToBuild(Set<Version> versions, com.yahoo.component.Version wantedVersion, AllocatedHosts allocatedHosts) {
- // TODO: Enable for all zones
- if (configserverConfig.buildMinimalSetOfConfigModels() &&
- (SystemName.from(configserverConfig.system()) == SystemName.cd ||
- Arrays.asList(Environment.dev, Environment.test, Environment.staging).contains(zone().environment()) ||
- Arrays.asList("corp-us-east-1", "ap-southeast-1", "us-central-1").contains(zone().region().value())))
+ if (configserverConfig.buildMinimalSetOfConfigModels())
versions = keepThoseUsedOn(allocatedHosts, versions);
// Make sure we build wanted version if we are building models for this major version and we are on hosted vespa
