类 CreateTemplateRequest
- java.lang.Object
-
- com.baidubce.model.AbstractBceRequest
-
- com.baidubce.services.bmr.model.CreateTemplateRequest
-
public class CreateTemplateRequest extends AbstractBceRequest
-
-
构造器概要
构造器 构造器 说明 CreateTemplateRequest()
-
方法概要
所有方法 实例方法 具体方法 修饰符和类型 方法 说明 StringgetAdminPassword()List<Application>getApplications()BooleangetAutoTerminate()StringgetAvailabilityZone()StringgetImageType()StringgetImageVersion()List<InstanceGroupConfig>getInstanceGroups()StringgetLogUri()StringgetName()StringgetPayType()BooleangetSafeModeEnabled()BooleangetServiceHaEnabled()List<StepConfig>getSteps()StringgetSubnetId()StringgetSystemSecurityGroup()StringgetTemplateType()StringgetVpcId()voidsetAdminPassword(String adminPassword)voidsetApplications(List<Application> applications)voidsetAutoTerminate(Boolean autoTerminate)voidsetAvailabilityZone(String availabilityZone)voidsetImageType(String imageType)voidsetImageVersion(String imageVersion)voidsetInstanceGroups(List<InstanceGroupConfig> instanceGroups)voidsetLogUri(String logUri)voidsetName(String name)voidsetPayType(String payType)voidsetSafeModeEnabled(Boolean safeModeEnabled)voidsetServiceHaEnabled(Boolean serviceHaEnabled)voidsetSteps(List<StepConfig> steps)voidsetSubnetId(String subnetId)voidsetSystemSecurityGroup(String systemSecurityGroup)voidsetTemplateType(String templateType)voidsetVpcId(String vpcId)CreateTemplateRequestwithAdminPassword(String adminPassword)Configure request adminPassword for the request.CreateTemplateRequestwithApplication(Application application)Configure optional application for the cluster.CreateTemplateRequestwithAutoTerminate(boolean autoTerminate)Configure auto-terminate property for the cluster.CreateTemplateRequestwithAvailabilityZone(String availabilityZone)Configure request availabilityZone of creating cluster.CreateTemplateRequestwithImageType(String imageType)Configure the image type for the cluster.CreateTemplateRequestwithImageVersion(String imageVersion)Configure image version for the cluster.CreateTemplateRequestwithInstanceGroup(InstanceGroupConfig instanceGroup)Configure the instance group for the cluster.CreateTemplateRequestwithLogUri(String logUri)Configure optional BOS uri for logs of steps.CreateTemplateRequestwithName(String name)Configure optional name of the cluster.If not set, then the name of the cluster will be "my-cluster" by default.AbstractBceRequestwithRequestCredentials(BceCredentials credentials)CreateTemplateRequestwithSafeModeEnabled(boolean safeModeEnabled)Configure optional safe mode enable of the cluster.CreateTemplateRequestwithSecurityGroup(String securityGroup)Configure request security group for the request.CreateTemplateRequestwithServiceHaEnabled(boolean serviceHaEnabled)Configure optional service HA enable of the cluster.CreateTemplateRequestwithStep(StepConfig step)Configure optional step for the cluster.CreateTemplateRequestwithSteps(List<StepConfig> steps)Configure the steps to be added.CreateTemplateRequestwithSubnetId(String subnetId)Configure request subnet name for the request.CreateTemplateRequestwithTemplateType(String templateType)Configure the template type for the cluster.CreateTemplateRequestwithVpcId(String vpcId)Configure request vpc network name for the request.-
从类继承的方法 com.baidubce.model.AbstractBceRequest
getRequestCredentials, setRequestCredentials
-
-
-
-
方法详细资料
-
withTemplateType
public CreateTemplateRequest withTemplateType(String templateType)
Configure the template type for the cluster.- 参数:
templateType- The template type for cluster- 返回:
- CreateClusterRequest
-
withImageType
public CreateTemplateRequest withImageType(String imageType)
Configure the image type for the cluster.- 参数:
imageType- The image type for cluster's instances.- 返回:
- CreateClusterRequest
-
withImageVersion
public CreateTemplateRequest withImageVersion(String imageVersion)
Configure image version for the cluster.- 参数:
imageVersion- The image version for the cluster's instance.- 返回:
- CreateClusterRequest
-
withAutoTerminate
public CreateTemplateRequest withAutoTerminate(boolean autoTerminate)
Configure auto-terminate property for the cluster. If set the autoTerminate as true, then the cluster will be terminated when all the steps are done. And the autoTerminate is true by default.- 参数:
autoTerminate- true if the cluster should be auto terminated.- 返回:
- CreateClusterRequest
-
withLogUri
public CreateTemplateRequest withLogUri(String logUri)
Configure optional BOS uri for logs of steps. If the uri is not set, then the logs for the cluster and steps are not saved in the BOS.- 参数:
logUri- The valid BOS uri for the logs.- 返回:
- CreateClusterRequest
-
withName
public CreateTemplateRequest withName(String name)
Configure optional name of the cluster.If not set, then the name of the cluster will be "my-cluster" by default.- 参数:
name- The name for the cluster.- 返回:
- CreateClusterRequest
-
withServiceHaEnabled
public CreateTemplateRequest withServiceHaEnabled(boolean serviceHaEnabled)
Configure optional service HA enable of the cluster. If true will create a ha cluster, default is false.- 参数:
serviceHaEnabled- true if the serivce ha enable, default is false.- 返回:
- CreateClusterRequest
-
withSafeModeEnabled
public CreateTemplateRequest withSafeModeEnabled(boolean safeModeEnabled)
Configure optional safe mode enable of the cluster. If true will create a cluster running as safe mode, default is false.- 参数:
safeModeEnabled- true if the safe mode enable, default is false.- 返回:
- CreateClusterRequest
-
withInstanceGroup
public CreateTemplateRequest withInstanceGroup(InstanceGroupConfig instanceGroup)
Configure the instance group for the cluster.- 参数:
instanceGroup- An InstanceGroupConfig instance.- 返回:
- CreateClusterRequest
-
withApplication
public CreateTemplateRequest withApplication(Application application)
Configure optional application for the cluster. BMR provides applications such as Hive、Pig、HBase for the cluster.- 参数:
application- An ApplicationConfig instance.- 返回:
- CreateClusterRequest
-
withStep
public CreateTemplateRequest withStep(StepConfig step)
Configure optional step for the cluster. The step will be scheduled and executed after the cluster is ACTIVE. And the step also can be added to the cluster by sending AddStepsRequest.- 参数:
step- a StepConfig instance to be added.- 返回:
- CreateClusterRequest
-
withSteps
public CreateTemplateRequest withSteps(List<StepConfig> steps)
Configure the steps to be added. This method will replace the CreateClusterRequest instance's steps by the @param steps totally, thus it should be invoked ahead of withStep method if both of them are used for the same CreateClusterRequest instance.- 参数:
steps- a List of StepConfig instances to be added.- 返回:
- CreateClusterRequest
-
withAdminPassword
public CreateTemplateRequest withAdminPassword(String adminPassword)
Configure request adminPassword for the request.- 参数:
adminPassword- adminPassword for example bmrtest@123- 返回:
- CreateClusterRequest
-
withVpcId
public CreateTemplateRequest withVpcId(String vpcId)
Configure request vpc network name for the request.- 参数:
vpcId- vpcId for cluster- 返回:
- CreateClusterRequest
-
withSubnetId
public CreateTemplateRequest withSubnetId(String subnetId)
Configure request subnet name for the request.- 参数:
subnetId- subnetId for cluster- 返回:
- CreateClusterRequest
-
withAvailabilityZone
public CreateTemplateRequest withAvailabilityZone(String availabilityZone)
Configure request availabilityZone of creating cluster.- 参数:
availabilityZone- availabilityZone for cluster- 返回:
- CreateClusterRequest
-
withSecurityGroup
public CreateTemplateRequest withSecurityGroup(String securityGroup)
Configure request security group for the request.- 参数:
securityGroup- securityGroup for cluster- 返回:
- CreateClusterRequest
-
getName
public String getName()
-
setName
public void setName(String name)
-
getPayType
public String getPayType()
-
setPayType
public void setPayType(String payType)
-
getApplications
public List<Application> getApplications()
-
setApplications
public void setApplications(List<Application> applications)
-
getAutoTerminate
public Boolean getAutoTerminate()
-
setAutoTerminate
public void setAutoTerminate(Boolean autoTerminate)
-
getImageType
public String getImageType()
-
setImageType
public void setImageType(String imageType)
-
getImageVersion
public String getImageVersion()
-
setImageVersion
public void setImageVersion(String imageVersion)
-
getInstanceGroups
public List<InstanceGroupConfig> getInstanceGroups()
-
setInstanceGroups
public void setInstanceGroups(List<InstanceGroupConfig> instanceGroups)
-
getLogUri
public String getLogUri()
-
setLogUri
public void setLogUri(String logUri)
-
getSteps
public List<StepConfig> getSteps()
-
setSteps
public void setSteps(List<StepConfig> steps)
-
getAdminPassword
public String getAdminPassword()
-
setAdminPassword
public void setAdminPassword(String adminPassword)
-
getAvailabilityZone
public String getAvailabilityZone()
-
setAvailabilityZone
public void setAvailabilityZone(String availabilityZone)
-
getVpcId
public String getVpcId()
-
setVpcId
public void setVpcId(String vpcId)
-
getSubnetId
public String getSubnetId()
-
setSubnetId
public void setSubnetId(String subnetId)
-
getSystemSecurityGroup
public String getSystemSecurityGroup()
-
setSystemSecurityGroup
public void setSystemSecurityGroup(String systemSecurityGroup)
-
getServiceHaEnabled
public Boolean getServiceHaEnabled()
-
setServiceHaEnabled
public void setServiceHaEnabled(Boolean serviceHaEnabled)
-
getSafeModeEnabled
public Boolean getSafeModeEnabled()
-
setSafeModeEnabled
public void setSafeModeEnabled(Boolean safeModeEnabled)
-
getTemplateType
public String getTemplateType()
-
setTemplateType
public void setTemplateType(String templateType)
-
withRequestCredentials
public AbstractBceRequest withRequestCredentials(BceCredentials credentials)
- 指定者:
withRequestCredentials在类中AbstractBceRequest
-
-