code stringlengths 23 201k | docstring stringlengths 17 96.2k | func_name stringlengths 0 235 | language stringclasses 1
value | repo stringlengths 8 72 | path stringlengths 11 317 | url stringlengths 57 377 | license stringclasses 7
values |
|---|---|---|---|---|---|---|---|
@Override
public String toString() {
StringBuilder sb = new StringBuilder();
sb.append("class V1VerticalPodAutoscalerSpecRecommenders {\n");
sb.append(" name: ").append(toIndentedString(name)).append("\n");
sb.append("}");
return sb.toString();
} | Name of the recommender responsible for generating recommendation for this object.
@return name | toString | java | azkaban/azkaban | azkaban-common/src/main/java/io/kubernetes/autoscaling/models/V1VerticalPodAutoscalerSpecRecommenders.java | https://github.com/azkaban/azkaban/blob/master/azkaban-common/src/main/java/io/kubernetes/autoscaling/models/V1VerticalPodAutoscalerSpecRecommenders.java | Apache-2.0 |
private String toIndentedString(Object o) {
if (o == null) {
return "null";
}
return o.toString().replace("\n", "\n ");
} | Convert the given object to string with each line indented by 4 spaces
(except the first line). | toIndentedString | java | azkaban/azkaban | azkaban-common/src/main/java/io/kubernetes/autoscaling/models/V1VerticalPodAutoscalerSpecRecommenders.java | https://github.com/azkaban/azkaban/blob/master/azkaban-common/src/main/java/io/kubernetes/autoscaling/models/V1VerticalPodAutoscalerSpecRecommenders.java | Apache-2.0 |
public V1VerticalPodAutoscalerSpecResourcePolicy containerPolicies(List<V1VerticalPodAutoscalerSpecResourcePolicyContainerPolicies> containerPolicies) {
this.containerPolicies = containerPolicies;
return this;
} | Controls how the autoscaler computes recommended resources. The resource policy may be used to set constraints on the recommendations for individual containers. If not specified, the autoscaler computes recommended resources for all containers in the pod, without additional constraints. | containerPolicies | java | azkaban/azkaban | azkaban-common/src/main/java/io/kubernetes/autoscaling/models/V1VerticalPodAutoscalerSpecResourcePolicy.java | https://github.com/azkaban/azkaban/blob/master/azkaban-common/src/main/java/io/kubernetes/autoscaling/models/V1VerticalPodAutoscalerSpecResourcePolicy.java | Apache-2.0 |
public V1VerticalPodAutoscalerSpecResourcePolicy addContainerPoliciesItem(V1VerticalPodAutoscalerSpecResourcePolicyContainerPolicies containerPoliciesItem) {
if (this.containerPolicies == null) {
this.containerPolicies = new ArrayList<>();
}
this.containerPolicies.add(containerPoliciesItem);
retur... | Controls how the autoscaler computes recommended resources. The resource policy may be used to set constraints on the recommendations for individual containers. If not specified, the autoscaler computes recommended resources for all containers in the pod, without additional constraints. | addContainerPoliciesItem | java | azkaban/azkaban | azkaban-common/src/main/java/io/kubernetes/autoscaling/models/V1VerticalPodAutoscalerSpecResourcePolicy.java | https://github.com/azkaban/azkaban/blob/master/azkaban-common/src/main/java/io/kubernetes/autoscaling/models/V1VerticalPodAutoscalerSpecResourcePolicy.java | Apache-2.0 |
@javax.annotation.Nullable
@ApiModelProperty(value = "Per-container resource policies.")
public List<V1VerticalPodAutoscalerSpecResourcePolicyContainerPolicies> getContainerPolicies() {
return containerPolicies;
} | Per-container resource policies.
@return containerPolicies | getContainerPolicies | java | azkaban/azkaban | azkaban-common/src/main/java/io/kubernetes/autoscaling/models/V1VerticalPodAutoscalerSpecResourcePolicy.java | https://github.com/azkaban/azkaban/blob/master/azkaban-common/src/main/java/io/kubernetes/autoscaling/models/V1VerticalPodAutoscalerSpecResourcePolicy.java | Apache-2.0 |
public void setContainerPolicies(List<V1VerticalPodAutoscalerSpecResourcePolicyContainerPolicies> containerPolicies) {
this.containerPolicies = containerPolicies;
} | Per-container resource policies.
@return containerPolicies | setContainerPolicies | java | azkaban/azkaban | azkaban-common/src/main/java/io/kubernetes/autoscaling/models/V1VerticalPodAutoscalerSpecResourcePolicy.java | https://github.com/azkaban/azkaban/blob/master/azkaban-common/src/main/java/io/kubernetes/autoscaling/models/V1VerticalPodAutoscalerSpecResourcePolicy.java | Apache-2.0 |
@Override
public boolean equals(Object o) {
if (this == o) {
return true;
}
if (o == null || getClass() != o.getClass()) {
return false;
}
V1VerticalPodAutoscalerSpecResourcePolicy v1VerticalPodAutoscalerSpecResourcePolicy = (V1VerticalPodAutoscalerSpecResourcePolicy) o;
return Obj... | Per-container resource policies.
@return containerPolicies | equals | java | azkaban/azkaban | azkaban-common/src/main/java/io/kubernetes/autoscaling/models/V1VerticalPodAutoscalerSpecResourcePolicy.java | https://github.com/azkaban/azkaban/blob/master/azkaban-common/src/main/java/io/kubernetes/autoscaling/models/V1VerticalPodAutoscalerSpecResourcePolicy.java | Apache-2.0 |
@Override
public int hashCode() {
return Objects.hash(containerPolicies);
} | Per-container resource policies.
@return containerPolicies | hashCode | java | azkaban/azkaban | azkaban-common/src/main/java/io/kubernetes/autoscaling/models/V1VerticalPodAutoscalerSpecResourcePolicy.java | https://github.com/azkaban/azkaban/blob/master/azkaban-common/src/main/java/io/kubernetes/autoscaling/models/V1VerticalPodAutoscalerSpecResourcePolicy.java | Apache-2.0 |
@Override
public String toString() {
StringBuilder sb = new StringBuilder();
sb.append("class V1VerticalPodAutoscalerSpecResourcePolicy {\n");
sb.append(" containerPolicies: ").append(toIndentedString(containerPolicies)).append("\n");
sb.append("}");
return sb.toString();
} | Per-container resource policies.
@return containerPolicies | toString | java | azkaban/azkaban | azkaban-common/src/main/java/io/kubernetes/autoscaling/models/V1VerticalPodAutoscalerSpecResourcePolicy.java | https://github.com/azkaban/azkaban/blob/master/azkaban-common/src/main/java/io/kubernetes/autoscaling/models/V1VerticalPodAutoscalerSpecResourcePolicy.java | Apache-2.0 |
private String toIndentedString(Object o) {
if (o == null) {
return "null";
}
return o.toString().replace("\n", "\n ");
} | Convert the given object to string with each line indented by 4 spaces
(except the first line). | toIndentedString | java | azkaban/azkaban | azkaban-common/src/main/java/io/kubernetes/autoscaling/models/V1VerticalPodAutoscalerSpecResourcePolicy.java | https://github.com/azkaban/azkaban/blob/master/azkaban-common/src/main/java/io/kubernetes/autoscaling/models/V1VerticalPodAutoscalerSpecResourcePolicy.java | Apache-2.0 |
public String getValue() {
return value;
} | Whether autoscaler is enabled for the container. The default is \"Auto\". | getValue | java | azkaban/azkaban | azkaban-common/src/main/java/io/kubernetes/autoscaling/models/V1VerticalPodAutoscalerSpecResourcePolicyContainerPolicies.java | https://github.com/azkaban/azkaban/blob/master/azkaban-common/src/main/java/io/kubernetes/autoscaling/models/V1VerticalPodAutoscalerSpecResourcePolicyContainerPolicies.java | Apache-2.0 |
@Override
public String toString() {
return String.valueOf(value);
} | Whether autoscaler is enabled for the container. The default is \"Auto\". | toString | java | azkaban/azkaban | azkaban-common/src/main/java/io/kubernetes/autoscaling/models/V1VerticalPodAutoscalerSpecResourcePolicyContainerPolicies.java | https://github.com/azkaban/azkaban/blob/master/azkaban-common/src/main/java/io/kubernetes/autoscaling/models/V1VerticalPodAutoscalerSpecResourcePolicyContainerPolicies.java | Apache-2.0 |
public static ModeEnum fromValue(String value) {
for (ModeEnum b : ModeEnum.values()) {
if (b.value.equals(value)) {
return b;
}
}
throw new IllegalArgumentException("Unexpected value '" + value + "'");
} | Whether autoscaler is enabled for the container. The default is \"Auto\". | fromValue | java | azkaban/azkaban | azkaban-common/src/main/java/io/kubernetes/autoscaling/models/V1VerticalPodAutoscalerSpecResourcePolicyContainerPolicies.java | https://github.com/azkaban/azkaban/blob/master/azkaban-common/src/main/java/io/kubernetes/autoscaling/models/V1VerticalPodAutoscalerSpecResourcePolicyContainerPolicies.java | Apache-2.0 |
@Override
public void write(final JsonWriter jsonWriter, final ModeEnum enumeration) throws IOException {
jsonWriter.value(enumeration.getValue());
} | Whether autoscaler is enabled for the container. The default is \"Auto\". | write | java | azkaban/azkaban | azkaban-common/src/main/java/io/kubernetes/autoscaling/models/V1VerticalPodAutoscalerSpecResourcePolicyContainerPolicies.java | https://github.com/azkaban/azkaban/blob/master/azkaban-common/src/main/java/io/kubernetes/autoscaling/models/V1VerticalPodAutoscalerSpecResourcePolicyContainerPolicies.java | Apache-2.0 |
@Override
public ModeEnum read(final JsonReader jsonReader) throws IOException {
String value = jsonReader.nextString();
return ModeEnum.fromValue(value);
} | Whether autoscaler is enabled for the container. The default is \"Auto\". | read | java | azkaban/azkaban | azkaban-common/src/main/java/io/kubernetes/autoscaling/models/V1VerticalPodAutoscalerSpecResourcePolicyContainerPolicies.java | https://github.com/azkaban/azkaban/blob/master/azkaban-common/src/main/java/io/kubernetes/autoscaling/models/V1VerticalPodAutoscalerSpecResourcePolicyContainerPolicies.java | Apache-2.0 |
public V1VerticalPodAutoscalerSpecResourcePolicyContainerPolicies containerName(String containerName) {
this.containerName = containerName;
return this;
} | Whether autoscaler is enabled for the container. The default is \"Auto\". | containerName | java | azkaban/azkaban | azkaban-common/src/main/java/io/kubernetes/autoscaling/models/V1VerticalPodAutoscalerSpecResourcePolicyContainerPolicies.java | https://github.com/azkaban/azkaban/blob/master/azkaban-common/src/main/java/io/kubernetes/autoscaling/models/V1VerticalPodAutoscalerSpecResourcePolicyContainerPolicies.java | Apache-2.0 |
@javax.annotation.Nullable
@ApiModelProperty(value = "Name of the container or DefaultContainerResourcePolicy, in which case the policy is used by the containers that don't have their own policy specified.")
public String getContainerName() {
return containerName;
} | Name of the container or DefaultContainerResourcePolicy, in which case the policy is used by the containers that don't have their own policy specified.
@return containerName | getContainerName | java | azkaban/azkaban | azkaban-common/src/main/java/io/kubernetes/autoscaling/models/V1VerticalPodAutoscalerSpecResourcePolicyContainerPolicies.java | https://github.com/azkaban/azkaban/blob/master/azkaban-common/src/main/java/io/kubernetes/autoscaling/models/V1VerticalPodAutoscalerSpecResourcePolicyContainerPolicies.java | Apache-2.0 |
public void setContainerName(String containerName) {
this.containerName = containerName;
} | Name of the container or DefaultContainerResourcePolicy, in which case the policy is used by the containers that don't have their own policy specified.
@return containerName | setContainerName | java | azkaban/azkaban | azkaban-common/src/main/java/io/kubernetes/autoscaling/models/V1VerticalPodAutoscalerSpecResourcePolicyContainerPolicies.java | https://github.com/azkaban/azkaban/blob/master/azkaban-common/src/main/java/io/kubernetes/autoscaling/models/V1VerticalPodAutoscalerSpecResourcePolicyContainerPolicies.java | Apache-2.0 |
public V1VerticalPodAutoscalerSpecResourcePolicyContainerPolicies controlledResources(List<String> controlledResources) {
this.controlledResources = controlledResources;
return this;
} | Name of the container or DefaultContainerResourcePolicy, in which case the policy is used by the containers that don't have their own policy specified.
@return containerName | controlledResources | java | azkaban/azkaban | azkaban-common/src/main/java/io/kubernetes/autoscaling/models/V1VerticalPodAutoscalerSpecResourcePolicyContainerPolicies.java | https://github.com/azkaban/azkaban/blob/master/azkaban-common/src/main/java/io/kubernetes/autoscaling/models/V1VerticalPodAutoscalerSpecResourcePolicyContainerPolicies.java | Apache-2.0 |
public V1VerticalPodAutoscalerSpecResourcePolicyContainerPolicies addControlledResourcesItem(String controlledResourcesItem) {
if (this.controlledResources == null) {
this.controlledResources = new ArrayList<>();
}
this.controlledResources.add(controlledResourcesItem);
return this;
} | Name of the container or DefaultContainerResourcePolicy, in which case the policy is used by the containers that don't have their own policy specified.
@return containerName | addControlledResourcesItem | java | azkaban/azkaban | azkaban-common/src/main/java/io/kubernetes/autoscaling/models/V1VerticalPodAutoscalerSpecResourcePolicyContainerPolicies.java | https://github.com/azkaban/azkaban/blob/master/azkaban-common/src/main/java/io/kubernetes/autoscaling/models/V1VerticalPodAutoscalerSpecResourcePolicyContainerPolicies.java | Apache-2.0 |
@javax.annotation.Nullable
@ApiModelProperty(value = "Specifies the type of recommendations that will be computed (and possibly applied) by VPA. If not specified, the default of [ResourceCPU, ResourceMemory] will be used.")
public List<String> getControlledResources() {
return controlledResources;
} | Specifies the type of recommendations that will be computed (and possibly applied) by VPA. If not specified, the default of [ResourceCPU, ResourceMemory] will be used.
@return controlledResources | getControlledResources | java | azkaban/azkaban | azkaban-common/src/main/java/io/kubernetes/autoscaling/models/V1VerticalPodAutoscalerSpecResourcePolicyContainerPolicies.java | https://github.com/azkaban/azkaban/blob/master/azkaban-common/src/main/java/io/kubernetes/autoscaling/models/V1VerticalPodAutoscalerSpecResourcePolicyContainerPolicies.java | Apache-2.0 |
public void setControlledResources(List<String> controlledResources) {
this.controlledResources = controlledResources;
} | Specifies the type of recommendations that will be computed (and possibly applied) by VPA. If not specified, the default of [ResourceCPU, ResourceMemory] will be used.
@return controlledResources | setControlledResources | java | azkaban/azkaban | azkaban-common/src/main/java/io/kubernetes/autoscaling/models/V1VerticalPodAutoscalerSpecResourcePolicyContainerPolicies.java | https://github.com/azkaban/azkaban/blob/master/azkaban-common/src/main/java/io/kubernetes/autoscaling/models/V1VerticalPodAutoscalerSpecResourcePolicyContainerPolicies.java | Apache-2.0 |
public V1VerticalPodAutoscalerSpecResourcePolicyContainerPolicies controlledValues(ControlledValuesEnum controlledValues) {
this.controlledValues = controlledValues;
return this;
} | Specifies the type of recommendations that will be computed (and possibly applied) by VPA. If not specified, the default of [ResourceCPU, ResourceMemory] will be used.
@return controlledResources | controlledValues | java | azkaban/azkaban | azkaban-common/src/main/java/io/kubernetes/autoscaling/models/V1VerticalPodAutoscalerSpecResourcePolicyContainerPolicies.java | https://github.com/azkaban/azkaban/blob/master/azkaban-common/src/main/java/io/kubernetes/autoscaling/models/V1VerticalPodAutoscalerSpecResourcePolicyContainerPolicies.java | Apache-2.0 |
@javax.annotation.Nullable
@ApiModelProperty(value = "Specifies the maximum amount of resources that will be recommended for the container. The default is no maximum.")
public Map<String, Object> getMaxAllowed() {
return maxAllowed;
} | Specifies the maximum amount of resources that will be recommended for the container. The default is no maximum.
@return maxAllowed | getMaxAllowed | java | azkaban/azkaban | azkaban-common/src/main/java/io/kubernetes/autoscaling/models/V1VerticalPodAutoscalerSpecResourcePolicyContainerPolicies.java | https://github.com/azkaban/azkaban/blob/master/azkaban-common/src/main/java/io/kubernetes/autoscaling/models/V1VerticalPodAutoscalerSpecResourcePolicyContainerPolicies.java | Apache-2.0 |
public void setMaxAllowed(Map<String, Object> maxAllowed) {
this.maxAllowed = maxAllowed;
} | Specifies the maximum amount of resources that will be recommended for the container. The default is no maximum.
@return maxAllowed | setMaxAllowed | java | azkaban/azkaban | azkaban-common/src/main/java/io/kubernetes/autoscaling/models/V1VerticalPodAutoscalerSpecResourcePolicyContainerPolicies.java | https://github.com/azkaban/azkaban/blob/master/azkaban-common/src/main/java/io/kubernetes/autoscaling/models/V1VerticalPodAutoscalerSpecResourcePolicyContainerPolicies.java | Apache-2.0 |
public V1VerticalPodAutoscalerSpecResourcePolicyContainerPolicies minAllowed(Map<String, Object> minAllowed) {
this.minAllowed = minAllowed;
return this;
} | Specifies the maximum amount of resources that will be recommended for the container. The default is no maximum.
@return maxAllowed | minAllowed | java | azkaban/azkaban | azkaban-common/src/main/java/io/kubernetes/autoscaling/models/V1VerticalPodAutoscalerSpecResourcePolicyContainerPolicies.java | https://github.com/azkaban/azkaban/blob/master/azkaban-common/src/main/java/io/kubernetes/autoscaling/models/V1VerticalPodAutoscalerSpecResourcePolicyContainerPolicies.java | Apache-2.0 |
public V1VerticalPodAutoscalerSpecResourcePolicyContainerPolicies putMinAllowedItem(String key, Object minAllowedItem) {
if (this.minAllowed == null) {
this.minAllowed = new HashMap<>();
}
this.minAllowed.put(key, minAllowedItem);
return this;
} | Specifies the maximum amount of resources that will be recommended for the container. The default is no maximum.
@return maxAllowed | putMinAllowedItem | java | azkaban/azkaban | azkaban-common/src/main/java/io/kubernetes/autoscaling/models/V1VerticalPodAutoscalerSpecResourcePolicyContainerPolicies.java | https://github.com/azkaban/azkaban/blob/master/azkaban-common/src/main/java/io/kubernetes/autoscaling/models/V1VerticalPodAutoscalerSpecResourcePolicyContainerPolicies.java | Apache-2.0 |
@javax.annotation.Nullable
@ApiModelProperty(value = "Specifies the minimal amount of resources that will be recommended for the container. The default is no minimum.")
public Map<String, Object> getMinAllowed() {
return minAllowed;
} | Specifies the minimal amount of resources that will be recommended for the container. The default is no minimum.
@return minAllowed | getMinAllowed | java | azkaban/azkaban | azkaban-common/src/main/java/io/kubernetes/autoscaling/models/V1VerticalPodAutoscalerSpecResourcePolicyContainerPolicies.java | https://github.com/azkaban/azkaban/blob/master/azkaban-common/src/main/java/io/kubernetes/autoscaling/models/V1VerticalPodAutoscalerSpecResourcePolicyContainerPolicies.java | Apache-2.0 |
public void setMinAllowed(Map<String, Object> minAllowed) {
this.minAllowed = minAllowed;
} | Specifies the minimal amount of resources that will be recommended for the container. The default is no minimum.
@return minAllowed | setMinAllowed | java | azkaban/azkaban | azkaban-common/src/main/java/io/kubernetes/autoscaling/models/V1VerticalPodAutoscalerSpecResourcePolicyContainerPolicies.java | https://github.com/azkaban/azkaban/blob/master/azkaban-common/src/main/java/io/kubernetes/autoscaling/models/V1VerticalPodAutoscalerSpecResourcePolicyContainerPolicies.java | Apache-2.0 |
public V1VerticalPodAutoscalerSpecResourcePolicyContainerPolicies mode(ModeEnum mode) {
this.mode = mode;
return this;
} | Specifies the minimal amount of resources that will be recommended for the container. The default is no minimum.
@return minAllowed | mode | java | azkaban/azkaban | azkaban-common/src/main/java/io/kubernetes/autoscaling/models/V1VerticalPodAutoscalerSpecResourcePolicyContainerPolicies.java | https://github.com/azkaban/azkaban/blob/master/azkaban-common/src/main/java/io/kubernetes/autoscaling/models/V1VerticalPodAutoscalerSpecResourcePolicyContainerPolicies.java | Apache-2.0 |
@javax.annotation.Nullable
@ApiModelProperty(value = "Whether autoscaler is enabled for the container. The default is \"Auto\".")
public ModeEnum getMode() {
return mode;
} | Whether autoscaler is enabled for the container. The default is \"Auto\".
@return mode | getMode | java | azkaban/azkaban | azkaban-common/src/main/java/io/kubernetes/autoscaling/models/V1VerticalPodAutoscalerSpecResourcePolicyContainerPolicies.java | https://github.com/azkaban/azkaban/blob/master/azkaban-common/src/main/java/io/kubernetes/autoscaling/models/V1VerticalPodAutoscalerSpecResourcePolicyContainerPolicies.java | Apache-2.0 |
public void setMode(ModeEnum mode) {
this.mode = mode;
} | Whether autoscaler is enabled for the container. The default is \"Auto\".
@return mode | setMode | java | azkaban/azkaban | azkaban-common/src/main/java/io/kubernetes/autoscaling/models/V1VerticalPodAutoscalerSpecResourcePolicyContainerPolicies.java | https://github.com/azkaban/azkaban/blob/master/azkaban-common/src/main/java/io/kubernetes/autoscaling/models/V1VerticalPodAutoscalerSpecResourcePolicyContainerPolicies.java | Apache-2.0 |
@Override
public boolean equals(Object o) {
if (this == o) {
return true;
}
if (o == null || getClass() != o.getClass()) {
return false;
}
V1VerticalPodAutoscalerSpecResourcePolicyContainerPolicies v1VerticalPodAutoscalerSpecResourcePolicyContainerPolicies = (V1VerticalPodAutoscalerSpe... | Whether autoscaler is enabled for the container. The default is \"Auto\".
@return mode | equals | java | azkaban/azkaban | azkaban-common/src/main/java/io/kubernetes/autoscaling/models/V1VerticalPodAutoscalerSpecResourcePolicyContainerPolicies.java | https://github.com/azkaban/azkaban/blob/master/azkaban-common/src/main/java/io/kubernetes/autoscaling/models/V1VerticalPodAutoscalerSpecResourcePolicyContainerPolicies.java | Apache-2.0 |
@Override
public int hashCode() {
return Objects.hash(containerName, controlledResources, controlledValues, maxAllowed, minAllowed, mode);
} | Whether autoscaler is enabled for the container. The default is \"Auto\".
@return mode | hashCode | java | azkaban/azkaban | azkaban-common/src/main/java/io/kubernetes/autoscaling/models/V1VerticalPodAutoscalerSpecResourcePolicyContainerPolicies.java | https://github.com/azkaban/azkaban/blob/master/azkaban-common/src/main/java/io/kubernetes/autoscaling/models/V1VerticalPodAutoscalerSpecResourcePolicyContainerPolicies.java | Apache-2.0 |
@Override
public String toString() {
StringBuilder sb = new StringBuilder();
sb.append("class V1VerticalPodAutoscalerSpecResourcePolicyContainerPolicies {\n");
sb.append(" containerName: ").append(toIndentedString(containerName)).append("\n");
sb.append(" controlledResources: ").append(toIndente... | Whether autoscaler is enabled for the container. The default is \"Auto\".
@return mode | toString | java | azkaban/azkaban | azkaban-common/src/main/java/io/kubernetes/autoscaling/models/V1VerticalPodAutoscalerSpecResourcePolicyContainerPolicies.java | https://github.com/azkaban/azkaban/blob/master/azkaban-common/src/main/java/io/kubernetes/autoscaling/models/V1VerticalPodAutoscalerSpecResourcePolicyContainerPolicies.java | Apache-2.0 |
private String toIndentedString(Object o) {
if (o == null) {
return "null";
}
return o.toString().replace("\n", "\n ");
} | Convert the given object to string with each line indented by 4 spaces
(except the first line). | toIndentedString | java | azkaban/azkaban | azkaban-common/src/main/java/io/kubernetes/autoscaling/models/V1VerticalPodAutoscalerSpecResourcePolicyContainerPolicies.java | https://github.com/azkaban/azkaban/blob/master/azkaban-common/src/main/java/io/kubernetes/autoscaling/models/V1VerticalPodAutoscalerSpecResourcePolicyContainerPolicies.java | Apache-2.0 |
public String getValue() {
return value;
} | Controls when autoscaler applies changes to the pod resources. The default is 'Auto'. | getValue | java | azkaban/azkaban | azkaban-common/src/main/java/io/kubernetes/autoscaling/models/V1VerticalPodAutoscalerSpecUpdatePolicy.java | https://github.com/azkaban/azkaban/blob/master/azkaban-common/src/main/java/io/kubernetes/autoscaling/models/V1VerticalPodAutoscalerSpecUpdatePolicy.java | Apache-2.0 |
@Override
public String toString() {
return String.valueOf(value);
} | Controls when autoscaler applies changes to the pod resources. The default is 'Auto'. | toString | java | azkaban/azkaban | azkaban-common/src/main/java/io/kubernetes/autoscaling/models/V1VerticalPodAutoscalerSpecUpdatePolicy.java | https://github.com/azkaban/azkaban/blob/master/azkaban-common/src/main/java/io/kubernetes/autoscaling/models/V1VerticalPodAutoscalerSpecUpdatePolicy.java | Apache-2.0 |
public static UpdateModeEnum fromValue(String value) {
for (UpdateModeEnum b : UpdateModeEnum.values()) {
if (b.value.equals(value)) {
return b;
}
}
throw new IllegalArgumentException("Unexpected value '" + value + "'");
} | Controls when autoscaler applies changes to the pod resources. The default is 'Auto'. | fromValue | java | azkaban/azkaban | azkaban-common/src/main/java/io/kubernetes/autoscaling/models/V1VerticalPodAutoscalerSpecUpdatePolicy.java | https://github.com/azkaban/azkaban/blob/master/azkaban-common/src/main/java/io/kubernetes/autoscaling/models/V1VerticalPodAutoscalerSpecUpdatePolicy.java | Apache-2.0 |
@Override
public void write(final JsonWriter jsonWriter, final UpdateModeEnum enumeration) throws IOException {
jsonWriter.value(enumeration.getValue());
} | Controls when autoscaler applies changes to the pod resources. The default is 'Auto'. | write | java | azkaban/azkaban | azkaban-common/src/main/java/io/kubernetes/autoscaling/models/V1VerticalPodAutoscalerSpecUpdatePolicy.java | https://github.com/azkaban/azkaban/blob/master/azkaban-common/src/main/java/io/kubernetes/autoscaling/models/V1VerticalPodAutoscalerSpecUpdatePolicy.java | Apache-2.0 |
@Override
public UpdateModeEnum read(final JsonReader jsonReader) throws IOException {
String value = jsonReader.nextString();
return UpdateModeEnum.fromValue(value);
} | Controls when autoscaler applies changes to the pod resources. The default is 'Auto'. | read | java | azkaban/azkaban | azkaban-common/src/main/java/io/kubernetes/autoscaling/models/V1VerticalPodAutoscalerSpecUpdatePolicy.java | https://github.com/azkaban/azkaban/blob/master/azkaban-common/src/main/java/io/kubernetes/autoscaling/models/V1VerticalPodAutoscalerSpecUpdatePolicy.java | Apache-2.0 |
public V1VerticalPodAutoscalerSpecUpdatePolicy minReplicas(Integer minReplicas) {
this.minReplicas = minReplicas;
return this;
} | Controls when autoscaler applies changes to the pod resources. The default is 'Auto'. | minReplicas | java | azkaban/azkaban | azkaban-common/src/main/java/io/kubernetes/autoscaling/models/V1VerticalPodAutoscalerSpecUpdatePolicy.java | https://github.com/azkaban/azkaban/blob/master/azkaban-common/src/main/java/io/kubernetes/autoscaling/models/V1VerticalPodAutoscalerSpecUpdatePolicy.java | Apache-2.0 |
@javax.annotation.Nullable
@ApiModelProperty(value = "Minimal number of replicas which need to be alive for Updater to attempt pod eviction (pending other checks like PDB). Only positive values are allowed. Overrides global '--min-replicas' flag.")
public Integer getMinReplicas() {
return minReplicas;
} | Minimal number of replicas which need to be alive for Updater to attempt pod eviction (pending other checks like PDB). Only positive values are allowed. Overrides global '--min-replicas' flag.
@return minReplicas | getMinReplicas | java | azkaban/azkaban | azkaban-common/src/main/java/io/kubernetes/autoscaling/models/V1VerticalPodAutoscalerSpecUpdatePolicy.java | https://github.com/azkaban/azkaban/blob/master/azkaban-common/src/main/java/io/kubernetes/autoscaling/models/V1VerticalPodAutoscalerSpecUpdatePolicy.java | Apache-2.0 |
public void setMinReplicas(Integer minReplicas) {
this.minReplicas = minReplicas;
} | Minimal number of replicas which need to be alive for Updater to attempt pod eviction (pending other checks like PDB). Only positive values are allowed. Overrides global '--min-replicas' flag.
@return minReplicas | setMinReplicas | java | azkaban/azkaban | azkaban-common/src/main/java/io/kubernetes/autoscaling/models/V1VerticalPodAutoscalerSpecUpdatePolicy.java | https://github.com/azkaban/azkaban/blob/master/azkaban-common/src/main/java/io/kubernetes/autoscaling/models/V1VerticalPodAutoscalerSpecUpdatePolicy.java | Apache-2.0 |
public V1VerticalPodAutoscalerSpecUpdatePolicy updateMode(UpdateModeEnum updateMode) {
this.updateMode = updateMode;
return this;
} | Minimal number of replicas which need to be alive for Updater to attempt pod eviction (pending other checks like PDB). Only positive values are allowed. Overrides global '--min-replicas' flag.
@return minReplicas | updateMode | java | azkaban/azkaban | azkaban-common/src/main/java/io/kubernetes/autoscaling/models/V1VerticalPodAutoscalerSpecUpdatePolicy.java | https://github.com/azkaban/azkaban/blob/master/azkaban-common/src/main/java/io/kubernetes/autoscaling/models/V1VerticalPodAutoscalerSpecUpdatePolicy.java | Apache-2.0 |
@javax.annotation.Nullable
@ApiModelProperty(value = "Controls when autoscaler applies changes to the pod resources. The default is 'Auto'.")
public UpdateModeEnum getUpdateMode() {
return updateMode;
} | Controls when autoscaler applies changes to the pod resources. The default is 'Auto'.
@return updateMode | getUpdateMode | java | azkaban/azkaban | azkaban-common/src/main/java/io/kubernetes/autoscaling/models/V1VerticalPodAutoscalerSpecUpdatePolicy.java | https://github.com/azkaban/azkaban/blob/master/azkaban-common/src/main/java/io/kubernetes/autoscaling/models/V1VerticalPodAutoscalerSpecUpdatePolicy.java | Apache-2.0 |
public void setUpdateMode(UpdateModeEnum updateMode) {
this.updateMode = updateMode;
} | Controls when autoscaler applies changes to the pod resources. The default is 'Auto'.
@return updateMode | setUpdateMode | java | azkaban/azkaban | azkaban-common/src/main/java/io/kubernetes/autoscaling/models/V1VerticalPodAutoscalerSpecUpdatePolicy.java | https://github.com/azkaban/azkaban/blob/master/azkaban-common/src/main/java/io/kubernetes/autoscaling/models/V1VerticalPodAutoscalerSpecUpdatePolicy.java | Apache-2.0 |
@Override
public boolean equals(Object o) {
if (this == o) {
return true;
}
if (o == null || getClass() != o.getClass()) {
return false;
}
V1VerticalPodAutoscalerSpecUpdatePolicy v1VerticalPodAutoscalerSpecUpdatePolicy = (V1VerticalPodAutoscalerSpecUpdatePolicy) o;
return Objects.e... | Controls when autoscaler applies changes to the pod resources. The default is 'Auto'.
@return updateMode | equals | java | azkaban/azkaban | azkaban-common/src/main/java/io/kubernetes/autoscaling/models/V1VerticalPodAutoscalerSpecUpdatePolicy.java | https://github.com/azkaban/azkaban/blob/master/azkaban-common/src/main/java/io/kubernetes/autoscaling/models/V1VerticalPodAutoscalerSpecUpdatePolicy.java | Apache-2.0 |
@Override
public int hashCode() {
return Objects.hash(minReplicas, updateMode);
} | Controls when autoscaler applies changes to the pod resources. The default is 'Auto'.
@return updateMode | hashCode | java | azkaban/azkaban | azkaban-common/src/main/java/io/kubernetes/autoscaling/models/V1VerticalPodAutoscalerSpecUpdatePolicy.java | https://github.com/azkaban/azkaban/blob/master/azkaban-common/src/main/java/io/kubernetes/autoscaling/models/V1VerticalPodAutoscalerSpecUpdatePolicy.java | Apache-2.0 |
@Override
public String toString() {
StringBuilder sb = new StringBuilder();
sb.append("class V1VerticalPodAutoscalerSpecUpdatePolicy {\n");
sb.append(" minReplicas: ").append(toIndentedString(minReplicas)).append("\n");
sb.append(" updateMode: ").append(toIndentedString(updateMode)).append("\n"... | Controls when autoscaler applies changes to the pod resources. The default is 'Auto'.
@return updateMode | toString | java | azkaban/azkaban | azkaban-common/src/main/java/io/kubernetes/autoscaling/models/V1VerticalPodAutoscalerSpecUpdatePolicy.java | https://github.com/azkaban/azkaban/blob/master/azkaban-common/src/main/java/io/kubernetes/autoscaling/models/V1VerticalPodAutoscalerSpecUpdatePolicy.java | Apache-2.0 |
private String toIndentedString(Object o) {
if (o == null) {
return "null";
}
return o.toString().replace("\n", "\n ");
} | Convert the given object to string with each line indented by 4 spaces
(except the first line). | toIndentedString | java | azkaban/azkaban | azkaban-common/src/main/java/io/kubernetes/autoscaling/models/V1VerticalPodAutoscalerSpecUpdatePolicy.java | https://github.com/azkaban/azkaban/blob/master/azkaban-common/src/main/java/io/kubernetes/autoscaling/models/V1VerticalPodAutoscalerSpecUpdatePolicy.java | Apache-2.0 |
@Test
public void testCreateAzkabanEventReporter() {
final Props props = new Props();
props.put(AZKABAN_EVENT_REPORTING_ENABLED, "true");
props.put(AZKABAN_EVENT_REPORTING_CLASS_PARAM,
"azkaban.AzkabanEventReporterTest1");
final AzkabanCommonModule azkabanCommonModule... | Verify that alternate implementation of the <code>AzkabanEventReporter</code>
is initialized. | testCreateAzkabanEventReporter | java | azkaban/azkaban | azkaban-common/src/test/java/azkaban/AzkabanCommonModuleTest.java | https://github.com/azkaban/azkaban/blob/master/azkaban-common/src/test/java/azkaban/AzkabanCommonModuleTest.java | Apache-2.0 |
@Test
public void testAzkabanEventReporterInvalidProperties() {
final Props props = new Props();
props.put(AZKABAN_EVENT_REPORTING_ENABLED, "true");
props.put(AZKABAN_EVENT_REPORTING_CLASS_PARAM,
"azkaban.execapp.reporter.AzkabanKafkaAvroEventReporter");
final Azkaban... | Verify that <code>IllegalArgumentException</code> is thrown when required properties
are missing. | testAzkabanEventReporterInvalidProperties | java | azkaban/azkaban | azkaban-common/src/test/java/azkaban/AzkabanCommonModuleTest.java | https://github.com/azkaban/azkaban/blob/master/azkaban-common/src/test/java/azkaban/AzkabanCommonModuleTest.java | Apache-2.0 |
@Test
public void testAzkabanEventReporterInvalidConstructor() {
final Props props = new Props();
props.put(AZKABAN_EVENT_REPORTING_ENABLED, "true");
props.put(AZKABAN_EVENT_REPORTING_CLASS_PARAM,
"azkaban.execapp.AzkabanEventReporterTest3");
AzkabanCommonModule azkab... | Verify that a <code>RuntimeException</code> is thrown when valid constructor is
not found in the event reporter implementation. | testAzkabanEventReporterInvalidConstructor | java | azkaban/azkaban | azkaban-common/src/test/java/azkaban/AzkabanCommonModuleTest.java | https://github.com/azkaban/azkaban/blob/master/azkaban-common/src/test/java/azkaban/AzkabanCommonModuleTest.java | Apache-2.0 |
@Test
public void testEventReporterDisabled() {
final Props props = new Props();
AzkabanCommonModule AzkabanCommonModule = new AzkabanCommonModule(props);
final AzkabanEventReporter azkabanEventReporter = AzkabanCommonModule
.createAzkabanEventReporter();
assertThat(a... | Ensures that the event reporter is not initialized when the property 'event.reporter.enabled'
is not set. | testEventReporterDisabled | java | azkaban/azkaban | azkaban-common/src/test/java/azkaban/AzkabanCommonModuleTest.java | https://github.com/azkaban/azkaban/blob/master/azkaban-common/src/test/java/azkaban/AzkabanCommonModuleTest.java | Apache-2.0 |
@Override
public boolean report(final EventType eventType, final Map<String, String> metadata) {
return false;
} | Ensures that the event reporter is not initialized when the property 'event.reporter.enabled'
is not set. | report | java | azkaban/azkaban | azkaban-common/src/test/java/azkaban/AzkabanCommonModuleTest.java | https://github.com/azkaban/azkaban/blob/master/azkaban-common/src/test/java/azkaban/AzkabanCommonModuleTest.java | Apache-2.0 |
@Override
public boolean report(final EventType eventType, final Map<String, String> metadata) {
return false;
} | Ensures that the event reporter is not initialized when the property 'event.reporter.enabled'
is not set. | report | java | azkaban/azkaban | azkaban-common/src/test/java/azkaban/AzkabanCommonModuleTest.java | https://github.com/azkaban/azkaban/blob/master/azkaban-common/src/test/java/azkaban/AzkabanCommonModuleTest.java | Apache-2.0 |
@Override
public boolean report(final EventType eventType, final Map<String, String> metadata) {
return false;
} | Ensures that the event reporter is not initialized when the property 'event.reporter.enabled'
is not set. | report | java | azkaban/azkaban | azkaban-common/src/test/java/azkaban/AzkabanCommonModuleTest.java | https://github.com/azkaban/azkaban/blob/master/azkaban-common/src/test/java/azkaban/AzkabanCommonModuleTest.java | Apache-2.0 |
@Test
public void testLoadingSingleCluster() throws IOException {
final File clusterDir = this.testDir.newFolder("single-cluster");
final File clusterConfig = new File(clusterDir, ClusterLoader.CLUSTER_CONF_FILE);
try (final Writer fileWriter = new OutputStreamWriter(
new FileOutputStream(clusterC... | Sanity check when a single cluster is configured. | testLoadingSingleCluster | java | azkaban/azkaban | azkaban-common/src/test/java/azkaban/cluster/ClusterLoaderTest.java | https://github.com/azkaban/azkaban/blob/master/azkaban-common/src/test/java/azkaban/cluster/ClusterLoaderTest.java | Apache-2.0 |
@Test (expected = FileNotFoundException.class)
public void testLoadingSingleClusterWithMissingClusterConfig() throws IOException {
final File clusterDir = this.testDir.newFolder("single-cluster-no-config");
final ClusterRegistry clusterRegistry = new ClusterRegistry();
ClusterLoader.loadCluster(clusterDi... | Verify an exception is thrown properly when a single cluster is configured
but with its cluster.properties file missing. | testLoadingSingleClusterWithMissingClusterConfig | java | azkaban/azkaban | azkaban-common/src/test/java/azkaban/cluster/ClusterLoaderTest.java | https://github.com/azkaban/azkaban/blob/master/azkaban-common/src/test/java/azkaban/cluster/ClusterLoaderTest.java | Apache-2.0 |
@Test
public void testLoadingMultipleClusters() throws IOException {
final File clustersDir = new File(
getClass().getClassLoader().getResource("clusters").getFile());
final ClusterRegistry clusterRegistry = new ClusterRegistry();
final ClusterLoader clusterLoader = new ClusterLoader(clustersDir,... | Sanity check when multiple clusters are configured. | testLoadingMultipleClusters | java | azkaban/azkaban | azkaban-common/src/test/java/azkaban/cluster/ClusterLoaderTest.java | https://github.com/azkaban/azkaban/blob/master/azkaban-common/src/test/java/azkaban/cluster/ClusterLoaderTest.java | Apache-2.0 |
@Test
public void testGetClusterSecurityManager() throws ClassNotFoundException {
final String fakeHadoopSecurityManagerClassName = "org.hello.world.HelloWorld";
final Props clusterProps = new Props();
final File hadoopSecurityManagerJar =
new File(getClass().getClassLoader().getResource("hellowor... | Test loading of the HadoopSecurityManager class figured for a given cluster
from its dedicated HadoopSecurityManagerClassLoader instance. | testGetClusterSecurityManager | java | azkaban/azkaban | azkaban-common/src/test/java/azkaban/cluster/ClusterTest.java | https://github.com/azkaban/azkaban/blob/master/azkaban-common/src/test/java/azkaban/cluster/ClusterTest.java | Apache-2.0 |
@Test
public void testGetResource() throws IOException {
final URL testJar = makeTestJar().toURI().toURL();
final ClassLoader currentClassLoader = getClass().getClassLoader();
final ClassLoader hadoopSecurityManagerClassLoader =
new HadoopSecurityManagerClassLoader(
new URL[]{testJar}... | Test the case where a resource file exists in the HadoopSecurityManager classloader. | testGetResource | java | azkaban/azkaban | azkaban-common/src/test/java/azkaban/cluster/HadoopSecurityManagerClassLoaderTest.java | https://github.com/azkaban/azkaban/blob/master/azkaban-common/src/test/java/azkaban/cluster/HadoopSecurityManagerClassLoaderTest.java | Apache-2.0 |
private File makeTestJar() throws IOException {
final File jarFile = this.testDir.newFile("test.jar");
try (final JarOutputStream out = new JarOutputStream(new FileOutputStream(jarFile))) {
final ZipEntry entry = new ZipEntry(RESOURCE_FILE);
out.putNextEntry(entry);
out.write("hello".getBytes(... | Test the case where a resource file exists in the HadoopSecurityManager classloader. | makeTestJar | java | azkaban/azkaban | azkaban-common/src/test/java/azkaban/cluster/HadoopSecurityManagerClassLoaderTest.java | https://github.com/azkaban/azkaban/blob/master/azkaban-common/src/test/java/azkaban/cluster/HadoopSecurityManagerClassLoaderTest.java | Apache-2.0 |
@Test(expected = ClassNotFoundException.class)
public void testNonExistClass() throws ClassNotFoundException {
final ClassLoader currentClassLoader = getClass().getClassLoader();
final ClassLoader hadoopSecurityManagerClassLoader =
new HadoopSecurityManagerClassLoader(
new URL[]{}, current... | Test the case where the define job class does not exist. | testNonExistClass | java | azkaban/azkaban | azkaban-common/src/test/java/azkaban/cluster/HadoopSecurityManagerClassLoaderTest.java | https://github.com/azkaban/azkaban/blob/master/azkaban-common/src/test/java/azkaban/cluster/HadoopSecurityManagerClassLoaderTest.java | Apache-2.0 |
@Test
public void testClassAvailableInParentClassLoader() throws ClassNotFoundException {
final ClassLoader currentClassLoader = getClass().getClassLoader();
final ClassLoader hadoopSecurityManagerClassLoader =
new HadoopSecurityManagerClassLoader(
new URL[]{}, currentClassLoader, "testClu... | Test class loading of a class that is available only in the parent classloader. | testClassAvailableInParentClassLoader | java | azkaban/azkaban | azkaban-common/src/test/java/azkaban/cluster/HadoopSecurityManagerClassLoaderTest.java | https://github.com/azkaban/azkaban/blob/master/azkaban-common/src/test/java/azkaban/cluster/HadoopSecurityManagerClassLoaderTest.java | Apache-2.0 |
@Test
public void testClassAvailableInHadoopSecurityManagerClassLoader()
throws MalformedURLException, ClassNotFoundException {
final ClassLoader currentClassLoader = getClass().getClassLoader();
final File helloworldJar = new File(currentClassLoader.getResource(SAMPLE_JAR).getFile());
final URL he... | Test class loading of a class that is available only in the HadoopSecurityManagerClassLoader.
The class is provided in 'helloworld.jar'. | testClassAvailableInHadoopSecurityManagerClassLoader | java | azkaban/azkaban | azkaban-common/src/test/java/azkaban/cluster/HadoopSecurityManagerClassLoaderTest.java | https://github.com/azkaban/azkaban/blob/master/azkaban-common/src/test/java/azkaban/cluster/HadoopSecurityManagerClassLoaderTest.java | Apache-2.0 |
@Test
public void testPropsClass() throws ClassNotFoundException {
ClassLoader currentClassLoader = getClass().getClassLoader();
HadoopSecurityManagerClassLoader hadoopSecurityManagerClassLoader =
new HadoopSecurityManagerClassLoader(
new URL[] {}, currentClassLoader, "testCluster");
/... | Check {@link azkaban.utils.Props} is always loaded by its parent classloader. | testPropsClass | java | azkaban/azkaban | azkaban-common/src/test/java/azkaban/cluster/HadoopSecurityManagerClassLoaderTest.java | https://github.com/azkaban/azkaban/blob/master/azkaban-common/src/test/java/azkaban/cluster/HadoopSecurityManagerClassLoaderTest.java | Apache-2.0 |
@Test
public void testGetNewConnectionAfterClose() throws Exception {
this.connection.setAutoCommit(false);
/**
* See {@link org.apache.commons.dbcp2.PoolableConnectionFactory#passivateObject}.
* If the connection disables auto commit, when we close it, connection will be reset enabling auto commit... | {@link AzkabanDataSource#getConnection} fetches a new connection object other than one in the above, if we don't close. | testGetNewConnectionAfterClose | java | azkaban/azkaban | azkaban-common/src/test/java/azkaban/database/AzkabanConnectionPoolTest.java | https://github.com/azkaban/azkaban/blob/master/azkaban-common/src/test/java/azkaban/database/AzkabanConnectionPoolTest.java | Apache-2.0 |
@Test
public void testFlowParamForDispatchMethod() throws Exception {
initializeContainerizedDispatchImpl();
this.containerizedDispatchManager.getContainerRampUpCriteria().setRampUp(0);
this.containerizedDispatchManager.getContainerJobTypeCriteria().updateAllowList(ImmutableSet.of("ALL"));
DispatchMet... | This test case is verifying that if dispatch method is marked for containerization in flow
parameter then it should be respected first. If not then it should follow rest of the
criteria.
@throws Exception | testFlowParamForDispatchMethod | java | azkaban/azkaban | azkaban-common/src/test/java/azkaban/executor/ContainerizedDispatchManagerTest.java | https://github.com/azkaban/azkaban/blob/master/azkaban-common/src/test/java/azkaban/executor/ContainerizedDispatchManagerTest.java | Apache-2.0 |
@Test
public void testFlowParamForUseExecutor() throws Exception {
initializeContainerizedDispatchImpl();
this.containerizedDispatchManager.getContainerRampUpCriteria().setRampUp(0);
this.containerizedDispatchManager.getContainerJobTypeCriteria().updateAllowList(ImmutableSet.of("ALL"));
DispatchMethod... | This test case is verifying that if useExecutor flow param is set then dispatch method
should be POLL.
@throws Exception | testFlowParamForUseExecutor | java | azkaban/azkaban | azkaban-common/src/test/java/azkaban/executor/ContainerizedDispatchManagerTest.java | https://github.com/azkaban/azkaban/blob/master/azkaban-common/src/test/java/azkaban/executor/ContainerizedDispatchManagerTest.java | Apache-2.0 |
@Test
public void testAllowAndDenyList() throws Exception {
// Flow 5 comprises of "command" and "noop" jobtypes
initializeContainerizedDispatchImpl();
this.containerizedDispatchManager.getContainerRampUpCriteria().setRampUp(10);
this.containerizedDispatchManager.getContainerJobTypeCriteria().updateAl... | This test case is verifying that if useExecutor flow param is set then dispatch method
should be POLL.
@throws Exception | testAllowAndDenyList | java | azkaban/azkaban | azkaban-common/src/test/java/azkaban/executor/ContainerizedDispatchManagerTest.java | https://github.com/azkaban/azkaban/blob/master/azkaban-common/src/test/java/azkaban/executor/ContainerizedDispatchManagerTest.java | Apache-2.0 |
@Test
public void testFetchAllActiveFlowIds() throws Exception {
initializeContainerizedDispatchImpl();
initializeUnfinishedFlows();
assertThat(this.containerizedDispatchManager.getRunningFlowIds())
.isEqualTo(new ArrayList<>(this.unfinishedFlows.keySet()));
} | This test case is verifying that if useExecutor flow param is set then dispatch method
should be POLL.
@throws Exception | testFetchAllActiveFlowIds | java | azkaban/azkaban | azkaban-common/src/test/java/azkaban/executor/ContainerizedDispatchManagerTest.java | https://github.com/azkaban/azkaban/blob/master/azkaban-common/src/test/java/azkaban/executor/ContainerizedDispatchManagerTest.java | Apache-2.0 |
@Test
public void testFetchAllQueuedFlowIds() throws Exception {
initializeContainerizedDispatchImpl();
assertThat(this.containerizedDispatchManager.getQueuedFlowIds())
.isEqualTo(ImmutableList.of(this.flow1.getExecutionId()));
} | This test case is verifying that if useExecutor flow param is set then dispatch method
should be POLL.
@throws Exception | testFetchAllQueuedFlowIds | java | azkaban/azkaban | azkaban-common/src/test/java/azkaban/executor/ContainerizedDispatchManagerTest.java | https://github.com/azkaban/azkaban/blob/master/azkaban-common/src/test/java/azkaban/executor/ContainerizedDispatchManagerTest.java | Apache-2.0 |
@Test
public void testFetchQueuedFlowSize() throws Exception {
initializeContainerizedDispatchImpl();
assertThat(this.containerizedDispatchManager.getQueuedFlowSize())
.isEqualTo(this.queuedFlows.size());
} | This test case is verifying that if useExecutor flow param is set then dispatch method
should be POLL.
@throws Exception | testFetchQueuedFlowSize | java | azkaban/azkaban | azkaban-common/src/test/java/azkaban/executor/ContainerizedDispatchManagerTest.java | https://github.com/azkaban/azkaban/blob/master/azkaban-common/src/test/java/azkaban/executor/ContainerizedDispatchManagerTest.java | Apache-2.0 |
@Test
public void testFetchActiveFlowByProject() throws Exception {
initializeContainerizedDispatchImpl();
initializeUnfinishedFlows();
final List<Integer> executions = this.containerizedDispatchManager
.getRunningFlowIds(this.flow2.getProjectId(), this.flow2.getFlowId());
assertThat(execution... | This test case is verifying that if useExecutor flow param is set then dispatch method
should be POLL.
@throws Exception | testFetchActiveFlowByProject | java | azkaban/azkaban | azkaban-common/src/test/java/azkaban/executor/ContainerizedDispatchManagerTest.java | https://github.com/azkaban/azkaban/blob/master/azkaban-common/src/test/java/azkaban/executor/ContainerizedDispatchManagerTest.java | Apache-2.0 |
@Test
public void testSubmitFlows() throws Exception {
initializeContainerizedDispatchImpl();
this.containerizedDispatchManager.submitExecutableFlow(this.flow1, this.user.getUserId());
Assert.assertEquals(this.containerizedDispatchManager.eventListener, this.eventListener);
this.containerizedDispatchM... | This test case is verifying that if useExecutor flow param is set then dispatch method
should be POLL.
@throws Exception | testSubmitFlows | java | azkaban/azkaban | azkaban-common/src/test/java/azkaban/executor/ContainerizedDispatchManagerTest.java | https://github.com/azkaban/azkaban/blob/master/azkaban-common/src/test/java/azkaban/executor/ContainerizedDispatchManagerTest.java | Apache-2.0 |
@Test
public void testSubmitFlowsExceedingMaxConcurrentRuns() throws Exception {
initializeContainerizedDispatchImpl();
this.props.put(ConfigurationKeys.CONCURRENT_RUNS_ONEFLOW_WHITELIST, "exectest1,"
+ "exec2,3");
submitFlow(this.flow2, this.ref2);
submitFlow(this.flow3, this.ref3);
asser... | This test case is verifying that if useExecutor flow param is set then dispatch method
should be POLL.
@throws Exception | testSubmitFlowsExceedingMaxConcurrentRuns | java | azkaban/azkaban | azkaban-common/src/test/java/azkaban/executor/ContainerizedDispatchManagerTest.java | https://github.com/azkaban/azkaban/blob/master/azkaban-common/src/test/java/azkaban/executor/ContainerizedDispatchManagerTest.java | Apache-2.0 |
@Test
public void testSubmitFlowsConcurrentWhitelist() throws Exception {
initializeContainerizedDispatchImpl();
this.props.put(Constants.ConfigurationKeys.MAX_CONCURRENT_RUNS_ONEFLOW, 1);
submitFlow(this.flow2, this.ref2);
submitFlow(this.flow3, this.ref3);
assertThatThrownBy(() -> this.container... | This test case is verifying that if useExecutor flow param is set then dispatch method
should be POLL.
@throws Exception | testSubmitFlowsConcurrentWhitelist | java | azkaban/azkaban | azkaban-common/src/test/java/azkaban/executor/ContainerizedDispatchManagerTest.java | https://github.com/azkaban/azkaban/blob/master/azkaban-common/src/test/java/azkaban/executor/ContainerizedDispatchManagerTest.java | Apache-2.0 |
@Test
public void testSubmitFlowsWithSkipOption() throws Exception {
initializeContainerizedDispatchImpl();
submitFlow(this.flow2, this.ref2);
this.flow3.getExecutionOptions().setConcurrentOption(ExecutionOptions.CONCURRENT_OPTION_SKIP);
assertThatThrownBy(
() -> this.containerizedDispatchMana... | This test case is verifying that if useExecutor flow param is set then dispatch method
should be POLL.
@throws Exception | testSubmitFlowsWithSkipOption | java | azkaban/azkaban | azkaban-common/src/test/java/azkaban/executor/ContainerizedDispatchManagerTest.java | https://github.com/azkaban/azkaban/blob/master/azkaban-common/src/test/java/azkaban/executor/ContainerizedDispatchManagerTest.java | Apache-2.0 |
@Test
public void testSetFlowLock() throws Exception {
initializeContainerizedDispatchImpl();
// trying to execute a locked flow should raise an error
this.flow1.setLocked(true);
final String msg = this.containerizedDispatchManager
.submitExecutableFlow(this.flow1, this.user.getUserId());
... | This test case is verifying that if useExecutor flow param is set then dispatch method
should be POLL.
@throws Exception | testSetFlowLock | java | azkaban/azkaban | azkaban-common/src/test/java/azkaban/executor/ContainerizedDispatchManagerTest.java | https://github.com/azkaban/azkaban/blob/master/azkaban-common/src/test/java/azkaban/executor/ContainerizedDispatchManagerTest.java | Apache-2.0 |
@Test
public void testDisablingQueueProcessThread() throws Exception {
initializeContainerizedDispatchImpl();
this.containerizedDispatchManager.start();
Assert.assertEquals(this.containerizedDispatchManager.isQueueProcessorThreadActive(), true);
this.containerizedDispatchManager.disableQueueProcessorT... | This test case is verifying that if useExecutor flow param is set then dispatch method
should be POLL.
@throws Exception | testDisablingQueueProcessThread | java | azkaban/azkaban | azkaban-common/src/test/java/azkaban/executor/ContainerizedDispatchManagerTest.java | https://github.com/azkaban/azkaban/blob/master/azkaban-common/src/test/java/azkaban/executor/ContainerizedDispatchManagerTest.java | Apache-2.0 |
@Test
public void testEnablingQueueProcessThread() throws Exception {
initializeContainerizedDispatchImpl();
this.containerizedDispatchManager.start();
this.containerizedDispatchManager.disableQueueProcessorThread();
Assert.assertEquals(this.containerizedDispatchManager.isQueueProcessorThreadActive(),... | This test case is verifying that if useExecutor flow param is set then dispatch method
should be POLL.
@throws Exception | testEnablingQueueProcessThread | java | azkaban/azkaban | azkaban-common/src/test/java/azkaban/executor/ContainerizedDispatchManagerTest.java | https://github.com/azkaban/azkaban/blob/master/azkaban-common/src/test/java/azkaban/executor/ContainerizedDispatchManagerTest.java | Apache-2.0 |
private void submitFlow(final ExecutableFlow flow, final ExecutionReference ref) throws
Exception {
when(this.executorLoader.fetchExecutableFlow(flow.getExecutionId())).thenReturn(flow);
this.containerizedDispatchManager.submitExecutableFlow(flow, this.user.getUserId());
this.unfinishedFlows.put(flow.... | This test case is verifying that if useExecutor flow param is set then dispatch method
should be POLL.
@throws Exception | submitFlow | java | azkaban/azkaban | azkaban-common/src/test/java/azkaban/executor/ContainerizedDispatchManagerTest.java | https://github.com/azkaban/azkaban/blob/master/azkaban-common/src/test/java/azkaban/executor/ContainerizedDispatchManagerTest.java | Apache-2.0 |
private void initializeUnfinishedFlows() throws Exception {
this.unfinishedFlows = ImmutableMap
.of(this.flow1.getExecutionId(), new Pair<>(this.ref1, this.flow1),
this.flow2.getExecutionId(), new Pair<>(this.ref2, this.flow2),
this.flow3.getExecutionId(), new Pair<>(this.ref3, this.... | This test case is verifying that if useExecutor flow param is set then dispatch method
should be POLL.
@throws Exception | initializeUnfinishedFlows | java | azkaban/azkaban | azkaban-common/src/test/java/azkaban/executor/ContainerizedDispatchManagerTest.java | https://github.com/azkaban/azkaban/blob/master/azkaban-common/src/test/java/azkaban/executor/ContainerizedDispatchManagerTest.java | Apache-2.0 |
private void initializeUnfinishedFlowMock() throws Exception {
when(this.executorLoader.fetchUnfinishedFlows()).thenReturn(this.unfinishedFlows);
when(this.executorLoader.fetchUnfinishedFlow(anyInt())).thenAnswer(
(Answer<Pair<ExecutionReference, ExecutableFlow>>) invocation -> {
Object[] argu... | This test case is verifying that if useExecutor flow param is set then dispatch method
should be POLL.
@throws Exception | initializeUnfinishedFlowMock | java | azkaban/azkaban | azkaban-common/src/test/java/azkaban/executor/ContainerizedDispatchManagerTest.java | https://github.com/azkaban/azkaban/blob/master/azkaban-common/src/test/java/azkaban/executor/ContainerizedDispatchManagerTest.java | Apache-2.0 |
private void initializeContainerizedDispatchImpl() throws Exception{
this.containerizedDispatchManager =
new ContainerizedDispatchManager(this.props, null, this.executorLoader,
this.nearlineExecutionLogsLoader, this.offlineExecutionLogsLoader, this.commonMetrics,
this.apiGateway, thi... | This test case is verifying that if useExecutor flow param is set then dispatch method
should be POLL.
@throws Exception | initializeContainerizedDispatchImpl | java | azkaban/azkaban | azkaban-common/src/test/java/azkaban/executor/ContainerizedDispatchManagerTest.java | https://github.com/azkaban/azkaban/blob/master/azkaban-common/src/test/java/azkaban/executor/ContainerizedDispatchManagerTest.java | Apache-2.0 |
@Test
public void testGetFlowLogs() throws Exception {
WrappedExecutorApiClient apiClient =
new WrappedExecutorApiClient(createContainerDispatchEnabledProps(this.props));
ContainerizedDispatchManager dispatchManager = createDefaultDispatchWithGateway(apiClient);
apiClient.setNextHttpPostResponse(W... | This test case is verifying that if useExecutor flow param is set then dispatch method
should be POLL.
@throws Exception | testGetFlowLogs | java | azkaban/azkaban | azkaban-common/src/test/java/azkaban/executor/ContainerizedDispatchManagerTest.java | https://github.com/azkaban/azkaban/blob/master/azkaban-common/src/test/java/azkaban/executor/ContainerizedDispatchManagerTest.java | Apache-2.0 |
@Test
public void testGetJobLogs() throws Exception {
WrappedExecutorApiClient apiClient =
new WrappedExecutorApiClient(createContainerDispatchEnabledProps(this.props));
ContainerizedDispatchManager dispatchManager = createDefaultDispatchWithGateway(apiClient);
apiClient.setNextHttpPostResponse(Wr... | This test case is verifying that if useExecutor flow param is set then dispatch method
should be POLL.
@throws Exception | testGetJobLogs | java | azkaban/azkaban | azkaban-common/src/test/java/azkaban/executor/ContainerizedDispatchManagerTest.java | https://github.com/azkaban/azkaban/blob/master/azkaban-common/src/test/java/azkaban/executor/ContainerizedDispatchManagerTest.java | Apache-2.0 |
@Test
public void testCancelPreparingFlow() throws Exception {
initializeContainerizedDispatchImpl();
testCancelUnreachableFlowHelper(Status.PREPARING);
} | This test case is verifying that if useExecutor flow param is set then dispatch method
should be POLL.
@throws Exception | testCancelPreparingFlow | java | azkaban/azkaban | azkaban-common/src/test/java/azkaban/executor/ContainerizedDispatchManagerTest.java | https://github.com/azkaban/azkaban/blob/master/azkaban-common/src/test/java/azkaban/executor/ContainerizedDispatchManagerTest.java | Apache-2.0 |
@Test
public void testCancelDispatchingFlow() throws Exception {
initializeContainerizedDispatchImpl();
testCancelUnreachableFlowHelper(Status.DISPATCHING);
} | This test case is verifying that if useExecutor flow param is set then dispatch method
should be POLL.
@throws Exception | testCancelDispatchingFlow | java | azkaban/azkaban | azkaban-common/src/test/java/azkaban/executor/ContainerizedDispatchManagerTest.java | https://github.com/azkaban/azkaban/blob/master/azkaban-common/src/test/java/azkaban/executor/ContainerizedDispatchManagerTest.java | Apache-2.0 |
@Test
public void testCancelRunningFlow() throws Exception {
initializeContainerizedDispatchImpl();
testCancelUnreachableFlowHelper(Status.RUNNING);
} | This test case is verifying that if useExecutor flow param is set then dispatch method
should be POLL.
@throws Exception | testCancelRunningFlow | java | azkaban/azkaban | azkaban-common/src/test/java/azkaban/executor/ContainerizedDispatchManagerTest.java | https://github.com/azkaban/azkaban/blob/master/azkaban-common/src/test/java/azkaban/executor/ContainerizedDispatchManagerTest.java | Apache-2.0 |
private void testCancelUnreachableFlowHelper(Status initialStatus) throws Exception {
submitFlow(this.flow1, this.ref1);
this.flow1.setStatus(initialStatus);
try {
WrappedExecutorApiClient apiClient =
new WrappedExecutorApiClient(createContainerDispatchEnabledProps(this.props));
Contai... | This test case is verifying that if useExecutor flow param is set then dispatch method
should be POLL.
@throws Exception | testCancelUnreachableFlowHelper | java | azkaban/azkaban | azkaban-common/src/test/java/azkaban/executor/ContainerizedDispatchManagerTest.java | https://github.com/azkaban/azkaban/blob/master/azkaban-common/src/test/java/azkaban/executor/ContainerizedDispatchManagerTest.java | Apache-2.0 |
@Test
public void testCancelFlow() throws Exception {
initializeUnfinishedFlows();
WrappedExecutorApiClient apiClient =
new WrappedExecutorApiClient(createContainerDispatchEnabledProps(this.props));
ContainerizedDispatchManager dispatchManager = createDefaultDispatchWithGateway(apiClient);
api... | This test case is verifying that if useExecutor flow param is set then dispatch method
should be POLL.
@throws Exception | testCancelFlow | java | azkaban/azkaban | azkaban-common/src/test/java/azkaban/executor/ContainerizedDispatchManagerTest.java | https://github.com/azkaban/azkaban/blob/master/azkaban-common/src/test/java/azkaban/executor/ContainerizedDispatchManagerTest.java | Apache-2.0 |
@Test
public void testCancelFlowWithMissingExecutor() throws Exception {
initializeUnfinishedFlows();
WrappedExecutorApiClient apiClient =
new WrappedExecutorApiClient(createContainerDispatchEnabledProps(this.props));
ContainerizedDispatchManager dispatchManager = createDefaultDispatchWithGateway(... | This test case is verifying that if useExecutor flow param is set then dispatch method
should be POLL.
@throws Exception | testCancelFlowWithMissingExecutor | java | azkaban/azkaban | azkaban-common/src/test/java/azkaban/executor/ContainerizedDispatchManagerTest.java | https://github.com/azkaban/azkaban/blob/master/azkaban-common/src/test/java/azkaban/executor/ContainerizedDispatchManagerTest.java | Apache-2.0 |
@Test
public void testFlowFilter() throws Exception {
initializeContainerizedDispatchImpl();
// Flow names contained in flow_filter.txt must be loaded.
assertTrue(containerizedDispatchManager.getContainerFlowCriteria().flowExists("proj1", "flow1"));
assertTrue(containerizedDispatchManager.getContainer... | This test case is verifying that if useExecutor flow param is set then dispatch method
should be POLL.
@throws Exception | testFlowFilter | java | azkaban/azkaban | azkaban-common/src/test/java/azkaban/executor/ContainerizedDispatchManagerTest.java | https://github.com/azkaban/azkaban/blob/master/azkaban-common/src/test/java/azkaban/executor/ContainerizedDispatchManagerTest.java | Apache-2.0 |
private Props createContainerDispatchEnabledProps(Props parentProps) {
Props containerProps = new Props(parentProps);
containerProps.put(ConfigurationKeys.AZKABAN_EXECUTOR_REVERSE_PROXY_ENABLED, "true");
containerProps.put(AZKABAN_EXECUTOR_REVERSE_PROXY_HOSTNAME, REVERSE_PROXY_HOST);
containerProps.put(... | This test case is verifying that if useExecutor flow param is set then dispatch method
should be POLL.
@throws Exception | createContainerDispatchEnabledProps | java | azkaban/azkaban | azkaban-common/src/test/java/azkaban/executor/ContainerizedDispatchManagerTest.java | https://github.com/azkaban/azkaban/blob/master/azkaban-common/src/test/java/azkaban/executor/ContainerizedDispatchManagerTest.java | Apache-2.0 |
private ContainerizedDispatchManager createDefaultDispatchWithGateway(ExecutorApiClient apiClient) throws Exception {
Props containerEnabledProps = createContainerDispatchEnabledProps(this.props);
ExecutorApiGateway executorApiGateway = new ExecutorApiGateway(apiClient, containerEnabledProps);
return create... | This test case is verifying that if useExecutor flow param is set then dispatch method
should be POLL.
@throws Exception | createDefaultDispatchWithGateway | java | azkaban/azkaban | azkaban-common/src/test/java/azkaban/executor/ContainerizedDispatchManagerTest.java | https://github.com/azkaban/azkaban/blob/master/azkaban-common/src/test/java/azkaban/executor/ContainerizedDispatchManagerTest.java | Apache-2.0 |
private ContainerizedDispatchManager createDispatchWithGateway(ExecutorApiGateway apiGateway,
Props containerEnabledProps) throws Exception {
ContainerizedDispatchManager dispatchManager =
new ContainerizedDispatchManager(containerEnabledProps, null, this.executorLoader,
this.nearlineExecu... | This test case is verifying that if useExecutor flow param is set then dispatch method
should be POLL.
@throws Exception | createDispatchWithGateway | java | azkaban/azkaban | azkaban-common/src/test/java/azkaban/executor/ContainerizedDispatchManagerTest.java | https://github.com/azkaban/azkaban/blob/master/azkaban-common/src/test/java/azkaban/executor/ContainerizedDispatchManagerTest.java | Apache-2.0 |
@Ignore
@Test
public void testRestartFlow() throws Exception {
initializeContainerizedDispatchImpl();
doAnswer(e -> {
throw new ExecutorManagerException("Unable to create container");
}).when(this.containerizedImpl).createContainer(this.flow1.getExecutionId());
when(this.executorLoader.fetchEx... | This test tries to verify the the flow is finalized and restarted if the dispatch fails.
@throws Exception | testRestartFlow | java | azkaban/azkaban | azkaban-common/src/test/java/azkaban/executor/ContainerizedDispatchManagerTest.java | https://github.com/azkaban/azkaban/blob/master/azkaban-common/src/test/java/azkaban/executor/ContainerizedDispatchManagerTest.java | Apache-2.0 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.