You are viewing documentation for version 3 of the AWS SDK for Ruby. Version 2 documentation can be found here.

Class: Aws::Batch::Types::SubmitJobRequest

Inherits:
Struct
  • Object
show all
Defined in:
gems/aws-sdk-batch/lib/aws-sdk-batch/types.rb

Overview

Note:

When making an API call, you may pass SubmitJobRequest data as a hash:

{
  job_name: "String", # required
  job_queue: "String", # required
  array_properties: {
    size: 1,
  },
  depends_on: [
    {
      job_id: "String",
      type: "N_TO_N", # accepts N_TO_N, SEQUENTIAL
    },
  ],
  job_definition: "String", # required
  parameters: {
    "String" => "String",
  },
  container_overrides: {
    vcpus: 1,
    memory: 1,
    command: ["String"],
    environment: [
      {
        name: "String",
        value: "String",
      },
    ],
  },
  retry_strategy: {
    attempts: 1,
  },
  timeout: {
    attempt_duration_seconds: 1,
  },
}

Instance Attribute Summary collapse

Instance Attribute Details

#array_propertiesTypes::ArrayProperties

The array properties for the submitted job, such as the size of the array. The array size can be between 2 and 10,000. If you specify array properties for a job, it becomes an array job. For more information, see Array Jobs in the AWS Batch User Guide.



2091
2092
2093
2094
2095
2096
2097
2098
2099
2100
2101
2102
# File 'gems/aws-sdk-batch/lib/aws-sdk-batch/types.rb', line 2091

class SubmitJobRequest < Struct.new(
  :job_name,
  :job_queue,
  :array_properties,
  :depends_on,
  :job_definition,
  :parameters,
  :container_overrides,
  :retry_strategy,
  :timeout)
  include Aws::Structure
end

#container_overridesTypes::ContainerOverrides

A list of container overrides in JSON format that specify the name of a container in the specified job definition and the overrides it should receive. You can override the default command for a container (that is specified in the job definition or the Docker image) with a command override. You can also override existing environment variables (that are specified in the job definition or Docker image) on a container or add new environment variables to it with an environment override.



2091
2092
2093
2094
2095
2096
2097
2098
2099
2100
2101
2102
# File 'gems/aws-sdk-batch/lib/aws-sdk-batch/types.rb', line 2091

class SubmitJobRequest < Struct.new(
  :job_name,
  :job_queue,
  :array_properties,
  :depends_on,
  :job_definition,
  :parameters,
  :container_overrides,
  :retry_strategy,
  :timeout)
  include Aws::Structure
end

#depends_onArray<Types::JobDependency>

A list of dependencies for the job. A job can depend upon a maximum of 20 jobs. You can specify a SEQUENTIAL type dependency without specifying a job ID for array jobs so that each child array job completes sequentially, starting at index 0. You can also specify an N_TO_N type dependency with a job ID for array jobs so that each index child of this job must wait for the corresponding index child of each dependency to complete before it can begin.

Returns:



2091
2092
2093
2094
2095
2096
2097
2098
2099
2100
2101
2102
# File 'gems/aws-sdk-batch/lib/aws-sdk-batch/types.rb', line 2091

class SubmitJobRequest < Struct.new(
  :job_name,
  :job_queue,
  :array_properties,
  :depends_on,
  :job_definition,
  :parameters,
  :container_overrides,
  :retry_strategy,
  :timeout)
  include Aws::Structure
end

#job_definitionString

The job definition used by this job. This value can be either a name:revision or the Amazon Resource Name (ARN) for the job definition.

Returns:

  • (String)


2091
2092
2093
2094
2095
2096
2097
2098
2099
2100
2101
2102
# File 'gems/aws-sdk-batch/lib/aws-sdk-batch/types.rb', line 2091

class SubmitJobRequest < Struct.new(
  :job_name,
  :job_queue,
  :array_properties,
  :depends_on,
  :job_definition,
  :parameters,
  :container_overrides,
  :retry_strategy,
  :timeout)
  include Aws::Structure
end

#job_nameString

The name of the job. The first character must be alphanumeric, and up to 128 letters (uppercase and lowercase), numbers, hyphens, and underscores are allowed.

Returns:

  • (String)


2091
2092
2093
2094
2095
2096
2097
2098
2099
2100
2101
2102
# File 'gems/aws-sdk-batch/lib/aws-sdk-batch/types.rb', line 2091

class SubmitJobRequest < Struct.new(
  :job_name,
  :job_queue,
  :array_properties,
  :depends_on,
  :job_definition,
  :parameters,
  :container_overrides,
  :retry_strategy,
  :timeout)
  include Aws::Structure
end

#job_queueString

The job queue into which the job is submitted. You can specify either the name or the Amazon Resource Name (ARN) of the queue.

Returns:

  • (String)


2091
2092
2093
2094
2095
2096
2097
2098
2099
2100
2101
2102
# File 'gems/aws-sdk-batch/lib/aws-sdk-batch/types.rb', line 2091

class SubmitJobRequest < Struct.new(
  :job_name,
  :job_queue,
  :array_properties,
  :depends_on,
  :job_definition,
  :parameters,
  :container_overrides,
  :retry_strategy,
  :timeout)
  include Aws::Structure
end

#parametersHash<String,String>

Additional parameters passed to the job that replace parameter substitution placeholders that are set in the job definition. Parameters are specified as a key and value pair mapping. Parameters in a SubmitJob request override any corresponding parameter defaults from the job definition.

Returns:

  • (Hash<String,String>)


2091
2092
2093
2094
2095
2096
2097
2098
2099
2100
2101
2102
# File 'gems/aws-sdk-batch/lib/aws-sdk-batch/types.rb', line 2091

class SubmitJobRequest < Struct.new(
  :job_name,
  :job_queue,
  :array_properties,
  :depends_on,
  :job_definition,
  :parameters,
  :container_overrides,
  :retry_strategy,
  :timeout)
  include Aws::Structure
end

#retry_strategyTypes::RetryStrategy

The retry strategy to use for failed jobs from this SubmitJob operation. When a retry strategy is specified here, it overrides the retry strategy defined in the job definition.



2091
2092
2093
2094
2095
2096
2097
2098
2099
2100
2101
2102
# File 'gems/aws-sdk-batch/lib/aws-sdk-batch/types.rb', line 2091

class SubmitJobRequest < Struct.new(
  :job_name,
  :job_queue,
  :array_properties,
  :depends_on,
  :job_definition,
  :parameters,
  :container_overrides,
  :retry_strategy,
  :timeout)
  include Aws::Structure
end

#timeoutTypes::JobTimeout

The timeout configuration for this SubmitJob operation. You can specify a timeout duration after which AWS Batch terminates your jobs if they have not finished. If a job is terminated due to a timeout, it is not retried. The minimum value for the timeout is 60 seconds. This configuration overrides any timeout configuration specified in the job definition. For array jobs, child jobs have the same timeout configuration as the parent job. For more information, see Job Timeouts in the Amazon Elastic Container Service Developer Guide.

Returns:



2091
2092
2093
2094
2095
2096
2097
2098
2099
2100
2101
2102
# File 'gems/aws-sdk-batch/lib/aws-sdk-batch/types.rb', line 2091

class SubmitJobRequest < Struct.new(
  :job_name,
  :job_queue,
  :array_properties,
  :depends_on,
  :job_definition,
  :parameters,
  :container_overrides,
  :retry_strategy,
  :timeout)
  include Aws::Structure
end