|
@@ -26,6 +26,8 @@ import java.util.Collections;
|
|
import java.util.List;
|
|
import java.util.List;
|
|
import java.util.Objects;
|
|
import java.util.Objects;
|
|
|
|
|
|
|
|
+import javax.xml.bind.annotation.XmlAccessType;
|
|
|
|
+import javax.xml.bind.annotation.XmlAccessorType;
|
|
import javax.xml.bind.annotation.XmlElement;
|
|
import javax.xml.bind.annotation.XmlElement;
|
|
import javax.xml.bind.annotation.XmlRootElement;
|
|
import javax.xml.bind.annotation.XmlRootElement;
|
|
|
|
|
|
@@ -46,22 +48,53 @@ import org.apache.hadoop.classification.InterfaceStability;
|
|
@ApiModel(description = "One or more components of the service. If the service is HBase say, then the component can be a simple role like master or regionserver. If the service is a complex business webapp then a component can be other services say Kafka or Storm. Thereby it opens up the support for complex and nested services.")
|
|
@ApiModel(description = "One or more components of the service. If the service is HBase say, then the component can be a simple role like master or regionserver. If the service is a complex business webapp then a component can be other services say Kafka or Storm. Thereby it opens up the support for complex and nested services.")
|
|
@javax.annotation.Generated(value = "class io.swagger.codegen.languages.JavaClientCodegen", date = "2016-06-02T08:15:05.615-07:00")
|
|
@javax.annotation.Generated(value = "class io.swagger.codegen.languages.JavaClientCodegen", date = "2016-06-02T08:15:05.615-07:00")
|
|
@XmlRootElement
|
|
@XmlRootElement
|
|
|
|
+@XmlAccessorType(XmlAccessType.FIELD)
|
|
@JsonInclude(JsonInclude.Include.NON_NULL)
|
|
@JsonInclude(JsonInclude.Include.NON_NULL)
|
|
public class Component implements Serializable {
|
|
public class Component implements Serializable {
|
|
private static final long serialVersionUID = -8430058381509087805L;
|
|
private static final long serialVersionUID = -8430058381509087805L;
|
|
|
|
|
|
|
|
+ @JsonProperty("name")
|
|
private String name = null;
|
|
private String name = null;
|
|
|
|
+
|
|
|
|
+ @JsonProperty("dependencies")
|
|
private List<String> dependencies = new ArrayList<String>();
|
|
private List<String> dependencies = new ArrayList<String>();
|
|
|
|
+
|
|
|
|
+ @JsonProperty("readiness_check")
|
|
|
|
+ @XmlElement(name = "readiness_check")
|
|
private ReadinessCheck readinessCheck = null;
|
|
private ReadinessCheck readinessCheck = null;
|
|
|
|
+
|
|
|
|
+ @JsonProperty("artifact")
|
|
private Artifact artifact = null;
|
|
private Artifact artifact = null;
|
|
|
|
+
|
|
|
|
+ @JsonProperty("launch_command")
|
|
|
|
+ @XmlElement(name = "launch_command")
|
|
private String launchCommand = null;
|
|
private String launchCommand = null;
|
|
|
|
+
|
|
|
|
+ @JsonProperty("resource")
|
|
private Resource resource = null;
|
|
private Resource resource = null;
|
|
|
|
+
|
|
|
|
+ @JsonProperty("number_of_containers")
|
|
|
|
+ @XmlElement(name = "number_of_containers")
|
|
private Long numberOfContainers = null;
|
|
private Long numberOfContainers = null;
|
|
|
|
+
|
|
|
|
+ @JsonProperty("run_privileged_container")
|
|
|
|
+ @XmlElement(name = "run_privileged_container")
|
|
private Boolean runPrivilegedContainer = false;
|
|
private Boolean runPrivilegedContainer = false;
|
|
|
|
+
|
|
|
|
+ @JsonProperty("placement_policy")
|
|
|
|
+ @XmlElement(name = "placement_policy")
|
|
private PlacementPolicy placementPolicy = null;
|
|
private PlacementPolicy placementPolicy = null;
|
|
|
|
+
|
|
|
|
+ @JsonProperty("state")
|
|
private ComponentState state = ComponentState.FLEXING;
|
|
private ComponentState state = ComponentState.FLEXING;
|
|
|
|
+
|
|
|
|
+ @JsonProperty("configuration")
|
|
private Configuration configuration = new Configuration();
|
|
private Configuration configuration = new Configuration();
|
|
|
|
+
|
|
|
|
+ @JsonProperty("quicklinks")
|
|
private List<String> quicklinks = new ArrayList<String>();
|
|
private List<String> quicklinks = new ArrayList<String>();
|
|
|
|
+
|
|
|
|
+ @JsonProperty("containers")
|
|
private List<Container> containers =
|
|
private List<Container> containers =
|
|
Collections.synchronizedList(new ArrayList<Container>());
|
|
Collections.synchronizedList(new ArrayList<Container>());
|
|
|
|
|
|
@@ -74,7 +107,6 @@ public class Component implements Serializable {
|
|
}
|
|
}
|
|
|
|
|
|
@ApiModelProperty(example = "null", required = true, value = "Name of the service component (mandatory).")
|
|
@ApiModelProperty(example = "null", required = true, value = "Name of the service component (mandatory).")
|
|
- @JsonProperty("name")
|
|
|
|
public String getName() {
|
|
public String getName() {
|
|
return name;
|
|
return name;
|
|
}
|
|
}
|
|
@@ -95,7 +127,6 @@ public class Component implements Serializable {
|
|
}
|
|
}
|
|
|
|
|
|
@ApiModelProperty(example = "null", value = "An array of service components which should be in READY state (as defined by readiness check), before this component can be started. The dependencies across all components of an service should be represented as a DAG.")
|
|
@ApiModelProperty(example = "null", value = "An array of service components which should be in READY state (as defined by readiness check), before this component can be started. The dependencies across all components of an service should be represented as a DAG.")
|
|
- @JsonProperty("dependencies")
|
|
|
|
public List<String> getDependencies() {
|
|
public List<String> getDependencies() {
|
|
return dependencies;
|
|
return dependencies;
|
|
}
|
|
}
|
|
@@ -113,12 +144,10 @@ public class Component implements Serializable {
|
|
}
|
|
}
|
|
|
|
|
|
@ApiModelProperty(example = "null", value = "Readiness check for this component.")
|
|
@ApiModelProperty(example = "null", value = "Readiness check for this component.")
|
|
- @JsonProperty("readiness_check")
|
|
|
|
public ReadinessCheck getReadinessCheck() {
|
|
public ReadinessCheck getReadinessCheck() {
|
|
return readinessCheck;
|
|
return readinessCheck;
|
|
}
|
|
}
|
|
|
|
|
|
- @XmlElement(name = "readiness_check")
|
|
|
|
public void setReadinessCheck(ReadinessCheck readinessCheck) {
|
|
public void setReadinessCheck(ReadinessCheck readinessCheck) {
|
|
this.readinessCheck = readinessCheck;
|
|
this.readinessCheck = readinessCheck;
|
|
}
|
|
}
|
|
@@ -133,7 +162,6 @@ public class Component implements Serializable {
|
|
}
|
|
}
|
|
|
|
|
|
@ApiModelProperty(example = "null", value = "Artifact of the component (optional). If not specified, the service level global artifact takes effect.")
|
|
@ApiModelProperty(example = "null", value = "Artifact of the component (optional). If not specified, the service level global artifact takes effect.")
|
|
- @JsonProperty("artifact")
|
|
|
|
public Artifact getArtifact() {
|
|
public Artifact getArtifact() {
|
|
return artifact;
|
|
return artifact;
|
|
}
|
|
}
|
|
@@ -153,12 +181,10 @@ public class Component implements Serializable {
|
|
}
|
|
}
|
|
|
|
|
|
@ApiModelProperty(example = "null", value = "The custom launch command of this component (optional). When specified at the component level, it overrides the value specified at the global level (if any).")
|
|
@ApiModelProperty(example = "null", value = "The custom launch command of this component (optional). When specified at the component level, it overrides the value specified at the global level (if any).")
|
|
- @JsonProperty("launch_command")
|
|
|
|
public String getLaunchCommand() {
|
|
public String getLaunchCommand() {
|
|
return launchCommand;
|
|
return launchCommand;
|
|
}
|
|
}
|
|
|
|
|
|
- @XmlElement(name = "launch_command")
|
|
|
|
public void setLaunchCommand(String launchCommand) {
|
|
public void setLaunchCommand(String launchCommand) {
|
|
this.launchCommand = launchCommand;
|
|
this.launchCommand = launchCommand;
|
|
}
|
|
}
|
|
@@ -173,7 +199,6 @@ public class Component implements Serializable {
|
|
}
|
|
}
|
|
|
|
|
|
@ApiModelProperty(example = "null", value = "Resource of this component (optional). If not specified, the service level global resource takes effect.")
|
|
@ApiModelProperty(example = "null", value = "Resource of this component (optional). If not specified, the service level global resource takes effect.")
|
|
- @JsonProperty("resource")
|
|
|
|
public Resource getResource() {
|
|
public Resource getResource() {
|
|
return resource;
|
|
return resource;
|
|
}
|
|
}
|
|
@@ -192,18 +217,15 @@ public class Component implements Serializable {
|
|
}
|
|
}
|
|
|
|
|
|
@ApiModelProperty(example = "null", value = "Number of containers for this component (optional). If not specified, the service level global number_of_containers takes effect.")
|
|
@ApiModelProperty(example = "null", value = "Number of containers for this component (optional). If not specified, the service level global number_of_containers takes effect.")
|
|
- @JsonProperty("number_of_containers")
|
|
|
|
public Long getNumberOfContainers() {
|
|
public Long getNumberOfContainers() {
|
|
return numberOfContainers;
|
|
return numberOfContainers;
|
|
}
|
|
}
|
|
|
|
|
|
- @XmlElement(name = "number_of_containers")
|
|
|
|
public void setNumberOfContainers(Long numberOfContainers) {
|
|
public void setNumberOfContainers(Long numberOfContainers) {
|
|
this.numberOfContainers = numberOfContainers;
|
|
this.numberOfContainers = numberOfContainers;
|
|
}
|
|
}
|
|
|
|
|
|
@ApiModelProperty(example = "null", value = "Containers of a started component. Specifying a value for this attribute for the POST payload raises a validation error. This blob is available only in the GET response of a started service.")
|
|
@ApiModelProperty(example = "null", value = "Containers of a started component. Specifying a value for this attribute for the POST payload raises a validation error. This blob is available only in the GET response of a started service.")
|
|
- @JsonProperty("containers")
|
|
|
|
public List<Container> getContainers() {
|
|
public List<Container> getContainers() {
|
|
return containers;
|
|
return containers;
|
|
}
|
|
}
|
|
@@ -237,12 +259,10 @@ public class Component implements Serializable {
|
|
}
|
|
}
|
|
|
|
|
|
@ApiModelProperty(example = "null", value = "Run all containers of this component in privileged mode (YARN-4262).")
|
|
@ApiModelProperty(example = "null", value = "Run all containers of this component in privileged mode (YARN-4262).")
|
|
- @JsonProperty("run_privileged_container")
|
|
|
|
public Boolean getRunPrivilegedContainer() {
|
|
public Boolean getRunPrivilegedContainer() {
|
|
return runPrivilegedContainer;
|
|
return runPrivilegedContainer;
|
|
}
|
|
}
|
|
|
|
|
|
- @XmlElement(name = "run_privileged_container")
|
|
|
|
public void setRunPrivilegedContainer(Boolean runPrivilegedContainer) {
|
|
public void setRunPrivilegedContainer(Boolean runPrivilegedContainer) {
|
|
this.runPrivilegedContainer = runPrivilegedContainer;
|
|
this.runPrivilegedContainer = runPrivilegedContainer;
|
|
}
|
|
}
|
|
@@ -259,12 +279,10 @@ public class Component implements Serializable {
|
|
}
|
|
}
|
|
|
|
|
|
@ApiModelProperty(example = "null", value = "Advanced scheduling and placement policies for all containers of this component (optional). If not specified, the service level placement_policy takes effect. Refer to the description at the global level for more details.")
|
|
@ApiModelProperty(example = "null", value = "Advanced scheduling and placement policies for all containers of this component (optional). If not specified, the service level placement_policy takes effect. Refer to the description at the global level for more details.")
|
|
- @JsonProperty("placement_policy")
|
|
|
|
public PlacementPolicy getPlacementPolicy() {
|
|
public PlacementPolicy getPlacementPolicy() {
|
|
return placementPolicy;
|
|
return placementPolicy;
|
|
}
|
|
}
|
|
|
|
|
|
- @XmlElement(name = "placement_policy")
|
|
|
|
public void setPlacementPolicy(PlacementPolicy placementPolicy) {
|
|
public void setPlacementPolicy(PlacementPolicy placementPolicy) {
|
|
this.placementPolicy = placementPolicy;
|
|
this.placementPolicy = placementPolicy;
|
|
}
|
|
}
|
|
@@ -278,7 +296,6 @@ public class Component implements Serializable {
|
|
}
|
|
}
|
|
|
|
|
|
@ApiModelProperty(example = "null", value = "Config properties for this component.")
|
|
@ApiModelProperty(example = "null", value = "Config properties for this component.")
|
|
- @JsonProperty("configuration")
|
|
|
|
public Configuration getConfiguration() {
|
|
public Configuration getConfiguration() {
|
|
return configuration;
|
|
return configuration;
|
|
}
|
|
}
|
|
@@ -297,7 +314,6 @@ public class Component implements Serializable {
|
|
}
|
|
}
|
|
|
|
|
|
@ApiModelProperty(example = "null", value = "A list of quicklink keys defined at the service level, and to be resolved by this component.")
|
|
@ApiModelProperty(example = "null", value = "A list of quicklink keys defined at the service level, and to be resolved by this component.")
|
|
- @JsonProperty("quicklinks")
|
|
|
|
public List<String> getQuicklinks() {
|
|
public List<String> getQuicklinks() {
|
|
return quicklinks;
|
|
return quicklinks;
|
|
}
|
|
}
|
|
@@ -312,7 +328,6 @@ public class Component implements Serializable {
|
|
}
|
|
}
|
|
|
|
|
|
@ApiModelProperty(example = "null", value = "State of the component.")
|
|
@ApiModelProperty(example = "null", value = "State of the component.")
|
|
- @JsonProperty("state")
|
|
|
|
public ComponentState getState() {
|
|
public ComponentState getState() {
|
|
return state;
|
|
return state;
|
|
}
|
|
}
|