Class JobDetail

    • Method Detail

      • jobArn

        public final String jobArn()

        The Amazon Resource Name (ARN) of the job.

        Returns:
        The Amazon Resource Name (ARN) of the job.
      • jobName

        public final String jobName()

        The job name.

        Returns:
        The job name.
      • jobId

        public final String jobId()

        The job ID.

        Returns:
        The job ID.
      • jobQueue

        public final String jobQueue()

        The Amazon Resource Name (ARN) of the job queue that the job is associated with.

        Returns:
        The Amazon Resource Name (ARN) of the job queue that the job is associated with.
      • shareIdentifier

        public final String shareIdentifier()

        The share identifier for the job.

        Returns:
        The share identifier for the job.
      • schedulingPriority

        public final Integer schedulingPriority()

        The scheduling policy of the job definition. This only affects jobs in job queues with a fair share policy. Jobs with a higher scheduling priority are scheduled before jobs with a lower scheduling priority.

        Returns:
        The scheduling policy of the job definition. This only affects jobs in job queues with a fair share policy. Jobs with a higher scheduling priority are scheduled before jobs with a lower scheduling priority.
      • hasAttempts

        public final boolean hasAttempts()
        For responses, this returns true if the service returned a value for the Attempts property. This DOES NOT check that the value is non-empty (for which, you should check the isEmpty() method on the property). This is useful because the SDK will never return a null collection or map, but you may need to differentiate between the service returning nothing (or null) and the service returning an empty collection or map. For requests, this returns true if a value for the property was specified in the request builder, and false if a value was not specified.
      • attempts

        public final List<AttemptDetail> attempts()

        A list of job attempts that are associated with this job.

        Attempts to modify the collection returned by this method will result in an UnsupportedOperationException.

        This method will never return null. If you would like to know whether the service returned this field (so that you can differentiate between null and empty), you can use the hasAttempts() method.

        Returns:
        A list of job attempts that are associated with this job.
      • statusReason

        public final String statusReason()

        A short, human-readable string to provide more details for the current status of the job.

        Returns:
        A short, human-readable string to provide more details for the current status of the job.
      • createdAt

        public final Long createdAt()

        The Unix timestamp (in milliseconds) for when the job was created. For non-array jobs and parent array jobs, this is when the job entered the SUBMITTED state. This is specifically at the time SubmitJob was called. For array child jobs, this is when the child job was spawned by its parent and entered the PENDING state.

        Returns:
        The Unix timestamp (in milliseconds) for when the job was created. For non-array jobs and parent array jobs, this is when the job entered the SUBMITTED state. This is specifically at the time SubmitJob was called. For array child jobs, this is when the child job was spawned by its parent and entered the PENDING state.
      • retryStrategy

        public final RetryStrategy retryStrategy()

        The retry strategy to use for this job if an attempt fails.

        Returns:
        The retry strategy to use for this job if an attempt fails.
      • startedAt

        public final Long startedAt()

        The Unix timestamp (in milliseconds) for when the job was started. More specifically, it's when the job transitioned from the STARTING state to the RUNNING state. This parameter isn't provided for child jobs of array jobs or multi-node parallel jobs.

        Returns:
        The Unix timestamp (in milliseconds) for when the job was started. More specifically, it's when the job transitioned from the STARTING state to the RUNNING state. This parameter isn't provided for child jobs of array jobs or multi-node parallel jobs.
      • stoppedAt

        public final Long stoppedAt()

        The Unix timestamp (in milliseconds) for when the job was stopped. More specifically, it's when the job transitioned from the RUNNING state to a terminal state, such as SUCCEEDED or FAILED.

        Returns:
        The Unix timestamp (in milliseconds) for when the job was stopped. More specifically, it's when the job transitioned from the RUNNING state to a terminal state, such as SUCCEEDED or FAILED.
      • hasDependsOn

        public final boolean hasDependsOn()
        For responses, this returns true if the service returned a value for the DependsOn property. This DOES NOT check that the value is non-empty (for which, you should check the isEmpty() method on the property). This is useful because the SDK will never return a null collection or map, but you may need to differentiate between the service returning nothing (or null) and the service returning an empty collection or map. For requests, this returns true if a value for the property was specified in the request builder, and false if a value was not specified.
      • dependsOn

        public final List<JobDependency> dependsOn()

        A list of job IDs that this job depends on.

        Attempts to modify the collection returned by this method will result in an UnsupportedOperationException.

        This method will never return null. If you would like to know whether the service returned this field (so that you can differentiate between null and empty), you can use the hasDependsOn() method.

        Returns:
        A list of job IDs that this job depends on.
      • jobDefinition

        public final String jobDefinition()

        The Amazon Resource Name (ARN) of the job definition that this job uses.

        Returns:
        The Amazon Resource Name (ARN) of the job definition that this job uses.
      • hasParameters

        public final boolean hasParameters()
        For responses, this returns true if the service returned a value for the Parameters property. This DOES NOT check that the value is non-empty (for which, you should check the isEmpty() method on the property). This is useful because the SDK will never return a null collection or map, but you may need to differentiate between the service returning nothing (or null) and the service returning an empty collection or map. For requests, this returns true if a value for the property was specified in the request builder, and false if a value was not specified.
      • parameters

        public final Map<String,​String> parameters()

        Additional parameters that are passed to the job that replace parameter substitution placeholders or override any corresponding parameter defaults from the job definition.

        Attempts to modify the collection returned by this method will result in an UnsupportedOperationException.

        This method will never return null. If you would like to know whether the service returned this field (so that you can differentiate between null and empty), you can use the hasParameters() method.

        Returns:
        Additional parameters that are passed to the job that replace parameter substitution placeholders or override any corresponding parameter defaults from the job definition.
      • container

        public final ContainerDetail container()

        An object that represents the details for the container that's associated with the job.

        Returns:
        An object that represents the details for the container that's associated with the job.
      • nodeDetails

        public final NodeDetails nodeDetails()

        An object that represents the details of a node that's associated with a multi-node parallel job.

        Returns:
        An object that represents the details of a node that's associated with a multi-node parallel job.
      • nodeProperties

        public final NodeProperties nodeProperties()

        An object that represents the node properties of a multi-node parallel job.

        This isn't applicable to jobs that are running on Fargate resources.

        Returns:
        An object that represents the node properties of a multi-node parallel job.

        This isn't applicable to jobs that are running on Fargate resources.

      • arrayProperties

        public final ArrayPropertiesDetail arrayProperties()

        The array properties of the job, if it's an array job.

        Returns:
        The array properties of the job, if it's an array job.
      • timeout

        public final JobTimeout timeout()

        The timeout configuration for the job.

        Returns:
        The timeout configuration for the job.
      • hasTags

        public final boolean hasTags()
        For responses, this returns true if the service returned a value for the Tags property. This DOES NOT check that the value is non-empty (for which, you should check the isEmpty() method on the property). This is useful because the SDK will never return a null collection or map, but you may need to differentiate between the service returning nothing (or null) and the service returning an empty collection or map. For requests, this returns true if a value for the property was specified in the request builder, and false if a value was not specified.
      • tags

        public final Map<String,​String> tags()

        The tags that are applied to the job.

        Attempts to modify the collection returned by this method will result in an UnsupportedOperationException.

        This method will never return null. If you would like to know whether the service returned this field (so that you can differentiate between null and empty), you can use the hasTags() method.

        Returns:
        The tags that are applied to the job.
      • propagateTags

        public final Boolean propagateTags()

        Specifies whether to propagate the tags from the job or job definition to the corresponding Amazon ECS task. If no value is specified, the tags aren't propagated. Tags can only be propagated to the tasks when the tasks are created. For tags with the same name, job tags are given priority over job definitions tags. If the total number of combined tags from the job and job definition is over 50, the job is moved to the FAILED state.

        Returns:
        Specifies whether to propagate the tags from the job or job definition to the corresponding Amazon ECS task. If no value is specified, the tags aren't propagated. Tags can only be propagated to the tasks when the tasks are created. For tags with the same name, job tags are given priority over job definitions tags. If the total number of combined tags from the job and job definition is over 50, the job is moved to the FAILED state.
      • platformCapabilities

        public final List<PlatformCapability> platformCapabilities()

        The platform capabilities required by the job definition. If no value is specified, it defaults to EC2. Jobs run on Fargate resources specify FARGATE.

        Attempts to modify the collection returned by this method will result in an UnsupportedOperationException.

        This method will never return null. If you would like to know whether the service returned this field (so that you can differentiate between null and empty), you can use the hasPlatformCapabilities() method.

        Returns:
        The platform capabilities required by the job definition. If no value is specified, it defaults to EC2. Jobs run on Fargate resources specify FARGATE.
      • hasPlatformCapabilities

        public final boolean hasPlatformCapabilities()
        For responses, this returns true if the service returned a value for the PlatformCapabilities property. This DOES NOT check that the value is non-empty (for which, you should check the isEmpty() method on the property). This is useful because the SDK will never return a null collection or map, but you may need to differentiate between the service returning nothing (or null) and the service returning an empty collection or map. For requests, this returns true if a value for the property was specified in the request builder, and false if a value was not specified.
      • platformCapabilitiesAsStrings

        public final List<String> platformCapabilitiesAsStrings()

        The platform capabilities required by the job definition. If no value is specified, it defaults to EC2. Jobs run on Fargate resources specify FARGATE.

        Attempts to modify the collection returned by this method will result in an UnsupportedOperationException.

        This method will never return null. If you would like to know whether the service returned this field (so that you can differentiate between null and empty), you can use the hasPlatformCapabilities() method.

        Returns:
        The platform capabilities required by the job definition. If no value is specified, it defaults to EC2. Jobs run on Fargate resources specify FARGATE.
      • eksProperties

        public final EksPropertiesDetail eksProperties()

        An object with various properties that are specific to Amazon EKS based jobs. Only one of container, eksProperties, or nodeDetails is specified.

        Returns:
        An object with various properties that are specific to Amazon EKS based jobs. Only one of container, eksProperties, or nodeDetails is specified.
      • hasEksAttempts

        public final boolean hasEksAttempts()
        For responses, this returns true if the service returned a value for the EksAttempts property. This DOES NOT check that the value is non-empty (for which, you should check the isEmpty() method on the property). This is useful because the SDK will never return a null collection or map, but you may need to differentiate between the service returning nothing (or null) and the service returning an empty collection or map. For requests, this returns true if a value for the property was specified in the request builder, and false if a value was not specified.
      • eksAttempts

        public final List<EksAttemptDetail> eksAttempts()

        A list of job attempts that are associated with this job.

        Attempts to modify the collection returned by this method will result in an UnsupportedOperationException.

        This method will never return null. If you would like to know whether the service returned this field (so that you can differentiate between null and empty), you can use the hasEksAttempts() method.

        Returns:
        A list of job attempts that are associated with this job.
      • isCancelled

        public final Boolean isCancelled()

        Indicates whether the job is canceled.

        Returns:
        Indicates whether the job is canceled.
      • isTerminated

        public final Boolean isTerminated()

        Indicates whether the job is terminated.

        Returns:
        Indicates whether the job is terminated.
      • hashCode

        public final int hashCode()
        Overrides:
        hashCode in class Object
      • equals

        public final boolean equals​(Object obj)
        Overrides:
        equals in class Object
      • toString

        public final String toString()
        Returns a string representation of this object. This is useful for testing and debugging. Sensitive data will be redacted from this string using a placeholder value.
        Overrides:
        toString in class Object
      • getValueForField

        public final <T> Optional<T> getValueForField​(String fieldName,
                                                      Class<T> clazz)