JobUpdateParameter Class

  • java.lang.Object
    • com.microsoft.azure.batch.protocol.models.JobUpdateParameter

public class JobUpdateParameter

The set of changes to be made to a job.

Method Summary

Modifier and Type Method and Description
JobConstraints constraints()

Get if omitted, the constraints are cleared.

List<MetadataItem> metadata()

Get if omitted, it takes the default value of an empty list; in effect, any existing metadata is deleted.

OnAllTasksComplete onAllTasksComplete()

Get if omitted, the completion behavior is set to noaction. If the current value is terminatejob, this is an error because a job's completion behavior may not be changed from terminatejob to noaction. You may not change the value from terminatejob to noaction - that is, once you have engaged automatic job termination, you cannot turn it off again. If you try to do this, the request fails and Batch returns status code 400 (Bad Request) and an 'invalid property value' error response. If you do not specify this element in a PUT request, it is equivalent to passing noaction. This is an error if the current value is terminatejob. Possible values include: 'noAction', 'terminateJob'.

PoolInformation poolInfo()

Get you may change the pool for a job only when the job is disabled. The Update Job call will fail if you include the poolInfo element and the job is not disabled. If you specify an autoPoolSpecification specification in the poolInfo, only the keepAlive property can be updated, and then only if the auto pool has a poolLifetimeOption of job.

Integer priority()

Get priority values can range from -1000 to 1000, with -1000 being the lowest priority and 1000 being the highest priority. If omitted, it is set to the default value 0.

JobUpdateParameter withConstraints(JobConstraints constraints)

Set if omitted, the constraints are cleared.

JobUpdateParameter withMetadata(List<MetadataItem> metadata)

Set if omitted, it takes the default value of an empty list; in effect, any existing metadata is deleted.

JobUpdateParameter withOnAllTasksComplete(OnAllTasksComplete onAllTasksComplete)

Set if omitted, the completion behavior is set to noaction. If the current value is terminatejob, this is an error because a job's completion behavior may not be changed from terminatejob to noaction. You may not change the value from terminatejob to noaction - that is, once you have engaged automatic job termination, you cannot turn it off again. If you try to do this, the request fails and Batch returns status code 400 (Bad Request) and an 'invalid property value' error response. If you do not specify this element in a PUT request, it is equivalent to passing noaction. This is an error if the current value is terminatejob. Possible values include: 'noAction', 'terminateJob'.

JobUpdateParameter withPoolInfo(PoolInformation poolInfo)

Set you may change the pool for a job only when the job is disabled. The Update Job call will fail if you include the poolInfo element and the job is not disabled. If you specify an autoPoolSpecification specification in the poolInfo, only the keepAlive property can be updated, and then only if the auto pool has a poolLifetimeOption of job.

JobUpdateParameter withPriority(Integer priority)

Set priority values can range from -1000 to 1000, with -1000 being the lowest priority and 1000 being the highest priority. If omitted, it is set to the default value 0.

Method Details

constraints

public JobConstraints constraints()

Get if omitted, the constraints are cleared.

Returns:

the constraints value

metadata

public List metadata()

Get if omitted, it takes the default value of an empty list; in effect, any existing metadata is deleted.

Returns:

the metadata value

onAllTasksComplete

public OnAllTasksComplete onAllTasksComplete()

Get if omitted, the completion behavior is set to noaction. If the current value is terminatejob, this is an error because a job's completion behavior may not be changed from terminatejob to noaction. You may not change the value from terminatejob to noaction - that is, once you have engaged automatic job termination, you cannot turn it off again. If you try to do this, the request fails and Batch returns status code 400 (Bad Request) and an 'invalid property value' error response. If you do not specify this element in a PUT request, it is equivalent to passing noaction. This is an error if the current value is terminatejob. Possible values include: 'noAction', 'terminateJob'.

Returns:

the onAllTasksComplete value

poolInfo

public PoolInformation poolInfo()

Get you may change the pool for a job only when the job is disabled. The Update Job call will fail if you include the poolInfo element and the job is not disabled. If you specify an autoPoolSpecification specification in the poolInfo, only the keepAlive property can be updated, and then only if the auto pool has a poolLifetimeOption of job.

Returns:

the poolInfo value

priority

public Integer priority()

Get priority values can range from -1000 to 1000, with -1000 being the lowest priority and 1000 being the highest priority. If omitted, it is set to the default value 0.

Returns:

the priority value

withConstraints

public JobUpdateParameter withConstraints(JobConstraints constraints)

Set if omitted, the constraints are cleared.

Parameters:

constraints - the constraints value to set

Returns:

the JobUpdateParameter object itself.

withMetadata

public JobUpdateParameter withMetadata(List metadata)

Set if omitted, it takes the default value of an empty list; in effect, any existing metadata is deleted.

Parameters:

metadata - the metadata value to set

Returns:

the JobUpdateParameter object itself.

withOnAllTasksComplete

public JobUpdateParameter withOnAllTasksComplete(OnAllTasksComplete onAllTasksComplete)

Set if omitted, the completion behavior is set to noaction. If the current value is terminatejob, this is an error because a job's completion behavior may not be changed from terminatejob to noaction. You may not change the value from terminatejob to noaction - that is, once you have engaged automatic job termination, you cannot turn it off again. If you try to do this, the request fails and Batch returns status code 400 (Bad Request) and an 'invalid property value' error response. If you do not specify this element in a PUT request, it is equivalent to passing noaction. This is an error if the current value is terminatejob. Possible values include: 'noAction', 'terminateJob'.

Parameters:

onAllTasksComplete - the onAllTasksComplete value to set

Returns:

the JobUpdateParameter object itself.

withPoolInfo

public JobUpdateParameter withPoolInfo(PoolInformation poolInfo)

Set you may change the pool for a job only when the job is disabled. The Update Job call will fail if you include the poolInfo element and the job is not disabled. If you specify an autoPoolSpecification specification in the poolInfo, only the keepAlive property can be updated, and then only if the auto pool has a poolLifetimeOption of job.

Parameters:

poolInfo - the poolInfo value to set

Returns:

the JobUpdateParameter object itself.

withPriority

public JobUpdateParameter withPriority(Integer priority)

Set priority values can range from -1000 to 1000, with -1000 being the lowest priority and 1000 being the highest priority. If omitted, it is set to the default value 0.

Parameters:

priority - the priority value to set

Returns:

the JobUpdateParameter object itself.

Applies to