Class CommandJob
- java.lang.Object
-
- com.azure.resourcemanager.machinelearning.models.ResourceBase
-
- com.azure.resourcemanager.machinelearning.models.JobBaseDetails
-
- com.azure.resourcemanager.machinelearning.models.CommandJob
-
public final class CommandJob extends JobBaseDetails
Command job definition.
-
-
Constructor Summary
Constructors Constructor Description CommandJob()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description String
codeId()
Get the codeId property: ARM resource ID of the code asset.String
command()
Get the command property: [Required] The command to execute on startup of the job.DistributionConfiguration
distribution()
Get the distribution property: Distribution configuration of the job.String
environmentId()
Get the environmentId property: [Required] The ARM resource ID of the Environment specification for the job.Map<String,String>
environmentVariables()
Get the environmentVariables property: Environment variables included in the job.Map<String,JobInput>
inputs()
Get the inputs property: Mapping of input data bindings used in the job.CommandJobLimits
limits()
Get the limits property: Command Job limit.Map<String,JobOutput>
outputs()
Get the outputs property: Mapping of output data bindings used in the job.Object
parameters()
Get the parameters property: Input parameters.ResourceConfiguration
resources()
Get the resources property: Compute Resource configuration for the job.void
validate()
Validates the instance.CommandJob
withCodeId(String codeId)
Set the codeId property: ARM resource ID of the code asset.CommandJob
withCommand(String command)
Set the command property: [Required] The command to execute on startup of the job.CommandJob
withComputeId(String computeId)
Set the computeId property: ARM resource ID of the compute resource.CommandJob
withDescription(String description)
Set the description property: The asset description text.CommandJob
withDisplayName(String displayName)
Set the displayName property: Display name of job.CommandJob
withDistribution(DistributionConfiguration distribution)
Set the distribution property: Distribution configuration of the job.CommandJob
withEnvironmentId(String environmentId)
Set the environmentId property: [Required] The ARM resource ID of the Environment specification for the job.CommandJob
withEnvironmentVariables(Map<String,String> environmentVariables)
Set the environmentVariables property: Environment variables included in the job.CommandJob
withExperimentName(String experimentName)
Set the experimentName property: The name of the experiment the job belongs to.CommandJob
withIdentity(IdentityConfiguration identity)
Set the identity property: Identity configuration.CommandJob
withInputs(Map<String,JobInput> inputs)
Set the inputs property: Mapping of input data bindings used in the job.CommandJob
withIsArchived(Boolean isArchived)
Set the isArchived property: Is the asset archived?.CommandJob
withLimits(CommandJobLimits limits)
Set the limits property: Command Job limit.CommandJob
withOutputs(Map<String,JobOutput> outputs)
Set the outputs property: Mapping of output data bindings used in the job.CommandJob
withProperties(Map<String,String> properties)
Set the properties property: The asset property dictionary.CommandJob
withResources(ResourceConfiguration resources)
Set the resources property: Compute Resource configuration for the job.CommandJob
withSchedule(ScheduleBase schedule)
Set the schedule property: Schedule definition of job.CommandJob
withServices(Map<String,JobService> services)
Set the services property: List of JobEndpoints.CommandJob
withTags(Map<String,String> tags)
Set the tags property: Tag dictionary.-
Methods inherited from class com.azure.resourcemanager.machinelearning.models.JobBaseDetails
computeId, displayName, experimentName, identity, isArchived, schedule, services, status
-
Methods inherited from class com.azure.resourcemanager.machinelearning.models.ResourceBase
description, properties, tags
-
-
-
-
Method Detail
-
codeId
public String codeId()
Get the codeId property: ARM resource ID of the code asset.- Returns:
- the codeId value.
-
withCodeId
public CommandJob withCodeId(String codeId)
Set the codeId property: ARM resource ID of the code asset.- Parameters:
codeId
- the codeId value to set.- Returns:
- the CommandJob object itself.
-
command
public String command()
Get the command property: [Required] The command to execute on startup of the job. eg. "python train.py".- Returns:
- the command value.
-
withCommand
public CommandJob withCommand(String command)
Set the command property: [Required] The command to execute on startup of the job. eg. "python train.py".- Parameters:
command
- the command value to set.- Returns:
- the CommandJob object itself.
-
distribution
public DistributionConfiguration distribution()
Get the distribution property: Distribution configuration of the job. If set, this should be one of Mpi, Tensorflow, PyTorch, or null.- Returns:
- the distribution value.
-
withDistribution
public CommandJob withDistribution(DistributionConfiguration distribution)
Set the distribution property: Distribution configuration of the job. If set, this should be one of Mpi, Tensorflow, PyTorch, or null.- Parameters:
distribution
- the distribution value to set.- Returns:
- the CommandJob object itself.
-
environmentId
public String environmentId()
Get the environmentId property: [Required] The ARM resource ID of the Environment specification for the job.- Returns:
- the environmentId value.
-
withEnvironmentId
public CommandJob withEnvironmentId(String environmentId)
Set the environmentId property: [Required] The ARM resource ID of the Environment specification for the job.- Parameters:
environmentId
- the environmentId value to set.- Returns:
- the CommandJob object itself.
-
environmentVariables
public Map<String,String> environmentVariables()
Get the environmentVariables property: Environment variables included in the job.- Returns:
- the environmentVariables value.
-
withEnvironmentVariables
public CommandJob withEnvironmentVariables(Map<String,String> environmentVariables)
Set the environmentVariables property: Environment variables included in the job.- Parameters:
environmentVariables
- the environmentVariables value to set.- Returns:
- the CommandJob object itself.
-
inputs
public Map<String,JobInput> inputs()
Get the inputs property: Mapping of input data bindings used in the job.- Returns:
- the inputs value.
-
withInputs
public CommandJob withInputs(Map<String,JobInput> inputs)
Set the inputs property: Mapping of input data bindings used in the job.- Parameters:
inputs
- the inputs value to set.- Returns:
- the CommandJob object itself.
-
limits
public CommandJobLimits limits()
Get the limits property: Command Job limit.- Returns:
- the limits value.
-
withLimits
public CommandJob withLimits(CommandJobLimits limits)
Set the limits property: Command Job limit.- Parameters:
limits
- the limits value to set.- Returns:
- the CommandJob object itself.
-
outputs
public Map<String,JobOutput> outputs()
Get the outputs property: Mapping of output data bindings used in the job.- Returns:
- the outputs value.
-
withOutputs
public CommandJob withOutputs(Map<String,JobOutput> outputs)
Set the outputs property: Mapping of output data bindings used in the job.- Parameters:
outputs
- the outputs value to set.- Returns:
- the CommandJob object itself.
-
parameters
public Object parameters()
Get the parameters property: Input parameters.- Returns:
- the parameters value.
-
resources
public ResourceConfiguration resources()
Get the resources property: Compute Resource configuration for the job.- Returns:
- the resources value.
-
withResources
public CommandJob withResources(ResourceConfiguration resources)
Set the resources property: Compute Resource configuration for the job.- Parameters:
resources
- the resources value to set.- Returns:
- the CommandJob object itself.
-
withComputeId
public CommandJob withComputeId(String computeId)
Set the computeId property: ARM resource ID of the compute resource.- Overrides:
withComputeId
in classJobBaseDetails
- Parameters:
computeId
- the computeId value to set.- Returns:
- the JobBaseDetails object itself.
-
withDisplayName
public CommandJob withDisplayName(String displayName)
Set the displayName property: Display name of job.- Overrides:
withDisplayName
in classJobBaseDetails
- Parameters:
displayName
- the displayName value to set.- Returns:
- the JobBaseDetails object itself.
-
withExperimentName
public CommandJob withExperimentName(String experimentName)
Set the experimentName property: The name of the experiment the job belongs to. If not set, the job is placed in the "Default" experiment.- Overrides:
withExperimentName
in classJobBaseDetails
- Parameters:
experimentName
- the experimentName value to set.- Returns:
- the JobBaseDetails object itself.
-
withIdentity
public CommandJob withIdentity(IdentityConfiguration identity)
Set the identity property: Identity configuration. If set, this should be one of AmlToken, ManagedIdentity, UserIdentity or null. Defaults to AmlToken if null.- Overrides:
withIdentity
in classJobBaseDetails
- Parameters:
identity
- the identity value to set.- Returns:
- the JobBaseDetails object itself.
-
withIsArchived
public CommandJob withIsArchived(Boolean isArchived)
Set the isArchived property: Is the asset archived?.- Overrides:
withIsArchived
in classJobBaseDetails
- Parameters:
isArchived
- the isArchived value to set.- Returns:
- the JobBaseDetails object itself.
-
withSchedule
public CommandJob withSchedule(ScheduleBase schedule)
Set the schedule property: Schedule definition of job. If no schedule is provided, the job is run once and immediately after submission.- Overrides:
withSchedule
in classJobBaseDetails
- Parameters:
schedule
- the schedule value to set.- Returns:
- the JobBaseDetails object itself.
-
withServices
public CommandJob withServices(Map<String,JobService> services)
Set the services property: List of JobEndpoints. For local jobs, a job endpoint will have an endpoint value of FileStreamObject.- Overrides:
withServices
in classJobBaseDetails
- Parameters:
services
- the services value to set.- Returns:
- the JobBaseDetails object itself.
-
withDescription
public CommandJob withDescription(String description)
Set the description property: The asset description text.- Overrides:
withDescription
in classJobBaseDetails
- Parameters:
description
- the description value to set.- Returns:
- the ResourceBase object itself.
-
withProperties
public CommandJob withProperties(Map<String,String> properties)
Set the properties property: The asset property dictionary.- Overrides:
withProperties
in classJobBaseDetails
- Parameters:
properties
- the properties value to set.- Returns:
- the ResourceBase object itself.
-
withTags
public CommandJob withTags(Map<String,String> tags)
Set the tags property: Tag dictionary. Tags can be added, removed, and updated.- Overrides:
withTags
in classJobBaseDetails
- Parameters:
tags
- the tags value to set.- Returns:
- the ResourceBase object itself.
-
validate
public void validate()
Validates the instance.- Overrides:
validate
in classJobBaseDetails
- Throws:
IllegalArgumentException
- thrown if the instance is not valid.
-
-