kubernetes-client的使用--java中提交argo工作流(6)
- UID
- 1066743
|
kubernetes-client的使用--java中提交argo工作流(6)
初始化几个类
ArgoCluster.java
package com.biologic.entity;
import java.util.ArrayList;
import java.util.Map;
import io.fabric8.kubernetes.client.CustomResource;
public class ArgoCluster extends CustomResource{
private ArgoSpec spec;
private Map<String,Object> status;
@Override
public String toString() {
return "Argo{" +
"apiVersion='" + getApiVersion() + '\'' +
", metadata=" + getMetadata() +
", spec=" + spec +
'}';
}
public ArgoSpec getSpec() {
return spec;
}
public void setSpec(ArgoSpec spec) {
this.spec = spec;
}
public Map<String, Object> getStatus() {
return status;
}
public void setStatus(Map<String, Object> status) {
this.status = status;
}
}
ArgoSpec.java
package com.biologic.entity;
import com.fasterxml.jackson.databind.JsonDeserializer;
import com.fasterxml.jackson.databind.annotation.JsonDeserialize;
import io.fabric8.kubernetes.api.model.KubernetesResource;
@JsonDeserialize(
using = JsonDeserializer.None.class
)
public class ArgoSpec implements KubernetesResource {
private Object entrypoint;
private Object arguments;
private Object templates;
private Object volumes;
public Object getEntrypoint() {
return entrypoint;
}
public void setEntrypoint(Object entrypoint) {
this.entrypoint = entrypoint;
}
public Object getArguments() {
return arguments;
}
public void setArguments(Object arguments) {
this.arguments = arguments;
}
public Object getTemplates() {
return templates;
}
public void setTemplates(Object templates) {
this.templates = templates;
}
public Object getVolumes() {
return volumes;
}
public void setVolumes(Object volumes) {
this.volumes = volumes;
}
} |
|
|
|
|
|