AWS SDK Version 3 for .NET
API Reference

AWS services or capabilities described in AWS Documentation may vary by region/location. Click Getting Started with Amazon AWS to see specific differences applicable to the China (Beijing) Region.

Container for the parameters to the RegisterJobDefinition operation. Registers an AWS Batch job definition.

Inheritance Hierarchy

System.Object
  Amazon.Runtime.AmazonWebServiceRequest
    Amazon.Batch.AmazonBatchRequest
      Amazon.Batch.Model.RegisterJobDefinitionRequest

Namespace: Amazon.Batch.Model
Assembly: AWSSDK.Batch.dll
Version: 3.x.y.z

Syntax

C#
public class RegisterJobDefinitionRequest : AmazonBatchRequest
         IAmazonWebServiceRequest

The RegisterJobDefinitionRequest type exposes the following members

Constructors

Properties

NameTypeDescription
Public Property ContainerProperties Amazon.Batch.Model.ContainerProperties

Gets and sets the property ContainerProperties.

An object with various properties specific for container-based jobs. This parameter is required if the type parameter is container.

Public Property JobDefinitionName System.String

Gets and sets the property JobDefinitionName.

The name of the job definition to register. Up to 128 letters (uppercase and lowercase), numbers, hyphens, and underscores are allowed.

Public Property Parameters System.Collections.Generic.Dictionary<System.String, System.String>

Gets and sets the property Parameters.

Default parameter substitution placeholders to set in the job definition. Parameters are specified as a key-value pair mapping. Parameters in a SubmitJob request override any corresponding parameter defaults from the job definition.

Public Property RetryStrategy Amazon.Batch.Model.RetryStrategy

Gets and sets the property RetryStrategy.

The retry strategy to use for failed jobs that are submitted with this job definition. Any retry strategy that is specified during a SubmitJob operation overrides the retry strategy defined here.

Public Property Type Amazon.Batch.JobDefinitionType

Gets and sets the property Type.

The type of job definition.

Examples

This example registers a job definition for a simple container job.

To register a job definition


var response = client.RegisterJobDefinition(new RegisterJobDefinitionRequest 
{
    Type = "container",
    ContainerProperties = new ContainerProperties {
        Command = new List {
            "sleep",
            "10"
        },
        Image = "busybox",
        Memory = 128,
        Vcpus = 1
    },
    JobDefinitionName = "sleep10"
});

string jobDefinitionArn = response.JobDefinitionArn;
string jobDefinitionName = response.JobDefinitionName;
integer revision = response.Revision;

            

Version Information

.NET Standard:
Supported in: 1.3

.NET Framework:
Supported in: 4.5, 4.0, 3.5

Portable Class Library:
Supported in: Windows Store Apps
Supported in: Windows Phone 8.1
Supported in: Xamarin Android
Supported in: Xamarin iOS (Unified)
Supported in: Xamarin.Forms