amazonka-iot-2.0: Amazon IoT SDK.
Copyright(c) 2013-2023 Brendan Hay
LicenseMozilla Public License, v. 2.0.
MaintainerBrendan Hay
Stabilityauto-generated
Portabilitynon-portable (GHC extensions)
Safe HaskellSafe-Inferred
LanguageHaskell2010

Amazonka.IoT.Types.Job

Description

 
Synopsis

Documentation

data Job Source #

The Job object contains details about a job.

See: newJob smart constructor.

Constructors

Job' 

Fields

  • abortConfig :: Maybe AbortConfig

    Configuration for criteria to abort the job.

  • comment :: Maybe Text

    If the job was updated, describes the reason for the update.

  • completedAt :: Maybe POSIX

    The time, in seconds since the epoch, when the job was completed.

  • createdAt :: Maybe POSIX

    The time, in seconds since the epoch, when the job was created.

  • description :: Maybe Text

    A short text description of the job.

  • documentParameters :: Maybe (HashMap Text Text)

    A key-value map that pairs the patterns that need to be replaced in a managed template job document schema. You can use the description of each key as a guidance to specify the inputs during runtime when creating a job.

    documentParameters can only be used when creating jobs from Amazon Web Services managed templates. This parameter can't be used with custom job templates or to create jobs from them.

  • forceCanceled :: Maybe Bool

    Will be true if the job was canceled with the optional force parameter set to true.

  • isConcurrent :: Maybe Bool

    Indicates whether a job is concurrent. Will be true when a job is rolling out new job executions or canceling previously created executions, otherwise false.

  • jobArn :: Maybe Text

    An ARN identifying the job with format "arn:aws:iot:region:account:job/jobId".

  • jobExecutionsRetryConfig :: Maybe JobExecutionsRetryConfig

    The configuration for the criteria to retry the job.

  • jobExecutionsRolloutConfig :: Maybe JobExecutionsRolloutConfig

    Allows you to create a staged rollout of a job.

  • jobId :: Maybe Text

    The unique identifier you assigned to this job when it was created.

  • jobProcessDetails :: Maybe JobProcessDetails

    Details about the job process.

  • jobTemplateArn :: Maybe Text

    The ARN of the job template used to create the job.

  • lastUpdatedAt :: Maybe POSIX

    The time, in seconds since the epoch, when the job was last updated.

  • namespaceId :: Maybe Text

    The namespace used to indicate that a job is a customer-managed job.

    When you specify a value for this parameter, Amazon Web Services IoT Core sends jobs notifications to MQTT topics that contain the value in the following format.

    $aws/things/THING_NAME/jobs/JOB_ID/notify-namespace-NAMESPACE_ID/

    The namespaceId feature is in public preview.

  • presignedUrlConfig :: Maybe PresignedUrlConfig

    Configuration for pre-signed S3 URLs.

  • reasonCode :: Maybe Text

    If the job was updated, provides the reason code for the update.

  • schedulingConfig :: Maybe SchedulingConfig

    The configuration that allows you to schedule a job for a future date and time in addition to specifying the end behavior for each job execution.

  • status :: Maybe JobStatus

    The status of the job, one of IN_PROGRESS, CANCELED, DELETION_IN_PROGRESS or COMPLETED.

  • targetSelection :: Maybe TargetSelection

    Specifies whether the job will continue to run (CONTINUOUS), or will be complete after all those things specified as targets have completed the job (SNAPSHOT). If continuous, the job may also be run on a thing when a change is detected in a target. For example, a job will run on a device when the thing representing the device is added to a target group, even after the job was completed by all things originally in the group.

    We recommend that you use continuous jobs instead of snapshot jobs for dynamic thing group targets. By using continuous jobs, devices that join the group receive the job execution even after the job has been created.

  • targets :: Maybe (NonEmpty Text)

    A list of IoT things and thing groups to which the job should be sent.

  • timeoutConfig :: Maybe TimeoutConfig

    Specifies the amount of time each device has to finish its execution of the job. A timer is started when the job execution status is set to IN_PROGRESS. If the job execution status is not set to another terminal state before the timer expires, it will be automatically set to TIMED_OUT.

Instances

Instances details
FromJSON Job Source # 
Instance details

Defined in Amazonka.IoT.Types.Job

Generic Job Source # 
Instance details

Defined in Amazonka.IoT.Types.Job

Associated Types

type Rep Job :: Type -> Type #

Methods

from :: Job -> Rep Job x #

to :: Rep Job x -> Job #

Read Job Source # 
Instance details

Defined in Amazonka.IoT.Types.Job

Show Job Source # 
Instance details

Defined in Amazonka.IoT.Types.Job

Methods

showsPrec :: Int -> Job -> ShowS #

show :: Job -> String #

showList :: [Job] -> ShowS #

NFData Job Source # 
Instance details

Defined in Amazonka.IoT.Types.Job

Methods

rnf :: Job -> () #

Eq Job Source # 
Instance details

Defined in Amazonka.IoT.Types.Job

Methods

(==) :: Job -> Job -> Bool #

(/=) :: Job -> Job -> Bool #

Hashable Job Source # 
Instance details

Defined in Amazonka.IoT.Types.Job

Methods

hashWithSalt :: Int -> Job -> Int #

hash :: Job -> Int #

type Rep Job Source # 
Instance details

Defined in Amazonka.IoT.Types.Job

type Rep Job = D1 ('MetaData "Job" "Amazonka.IoT.Types.Job" "amazonka-iot-2.0-6w03vgAfmrM1SG22OsNJXL" 'False) (C1 ('MetaCons "Job'" 'PrefixI 'True) ((((S1 ('MetaSel ('Just "abortConfig") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (Maybe AbortConfig)) :*: S1 ('MetaSel ('Just "comment") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (Maybe Text))) :*: (S1 ('MetaSel ('Just "completedAt") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (Maybe POSIX)) :*: (S1 ('MetaSel ('Just "createdAt") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (Maybe POSIX)) :*: S1 ('MetaSel ('Just "description") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (Maybe Text))))) :*: ((S1 ('MetaSel ('Just "documentParameters") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (Maybe (HashMap Text Text))) :*: (S1 ('MetaSel ('Just "forceCanceled") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (Maybe Bool)) :*: S1 ('MetaSel ('Just "isConcurrent") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (Maybe Bool)))) :*: (S1 ('MetaSel ('Just "jobArn") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (Maybe Text)) :*: (S1 ('MetaSel ('Just "jobExecutionsRetryConfig") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (Maybe JobExecutionsRetryConfig)) :*: S1 ('MetaSel ('Just "jobExecutionsRolloutConfig") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (Maybe JobExecutionsRolloutConfig)))))) :*: (((S1 ('MetaSel ('Just "jobId") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (Maybe Text)) :*: (S1 ('MetaSel ('Just "jobProcessDetails") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (Maybe JobProcessDetails)) :*: S1 ('MetaSel ('Just "jobTemplateArn") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (Maybe Text)))) :*: (S1 ('MetaSel ('Just "lastUpdatedAt") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (Maybe POSIX)) :*: (S1 ('MetaSel ('Just "namespaceId") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (Maybe Text)) :*: S1 ('MetaSel ('Just "presignedUrlConfig") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (Maybe PresignedUrlConfig))))) :*: ((S1 ('MetaSel ('Just "reasonCode") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (Maybe Text)) :*: (S1 ('MetaSel ('Just "schedulingConfig") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (Maybe SchedulingConfig)) :*: S1 ('MetaSel ('Just "status") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (Maybe JobStatus)))) :*: (S1 ('MetaSel ('Just "targetSelection") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (Maybe TargetSelection)) :*: (S1 ('MetaSel ('Just "targets") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (Maybe (NonEmpty Text))) :*: S1 ('MetaSel ('Just "timeoutConfig") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (Maybe TimeoutConfig))))))))

newJob :: Job Source #

Create a value of Job with all optional fields omitted.

Use generic-lens or optics to modify other optional fields.

The following record fields are available, with the corresponding lenses provided for backwards compatibility:

$sel:abortConfig:Job', job_abortConfig - Configuration for criteria to abort the job.

$sel:comment:Job', job_comment - If the job was updated, describes the reason for the update.

$sel:completedAt:Job', job_completedAt - The time, in seconds since the epoch, when the job was completed.

$sel:createdAt:Job', job_createdAt - The time, in seconds since the epoch, when the job was created.

$sel:description:Job', job_description - A short text description of the job.

$sel:documentParameters:Job', job_documentParameters - A key-value map that pairs the patterns that need to be replaced in a managed template job document schema. You can use the description of each key as a guidance to specify the inputs during runtime when creating a job.

documentParameters can only be used when creating jobs from Amazon Web Services managed templates. This parameter can't be used with custom job templates or to create jobs from them.

$sel:forceCanceled:Job', job_forceCanceled - Will be true if the job was canceled with the optional force parameter set to true.

$sel:isConcurrent:Job', job_isConcurrent - Indicates whether a job is concurrent. Will be true when a job is rolling out new job executions or canceling previously created executions, otherwise false.

$sel:jobArn:Job', job_jobArn - An ARN identifying the job with format "arn:aws:iot:region:account:job/jobId".

$sel:jobExecutionsRetryConfig:Job', job_jobExecutionsRetryConfig - The configuration for the criteria to retry the job.

$sel:jobExecutionsRolloutConfig:Job', job_jobExecutionsRolloutConfig - Allows you to create a staged rollout of a job.

$sel:jobId:Job', job_jobId - The unique identifier you assigned to this job when it was created.

$sel:jobProcessDetails:Job', job_jobProcessDetails - Details about the job process.

$sel:jobTemplateArn:Job', job_jobTemplateArn - The ARN of the job template used to create the job.

$sel:lastUpdatedAt:Job', job_lastUpdatedAt - The time, in seconds since the epoch, when the job was last updated.

$sel:namespaceId:Job', job_namespaceId - The namespace used to indicate that a job is a customer-managed job.

When you specify a value for this parameter, Amazon Web Services IoT Core sends jobs notifications to MQTT topics that contain the value in the following format.

$aws/things/THING_NAME/jobs/JOB_ID/notify-namespace-NAMESPACE_ID/

The namespaceId feature is in public preview.

$sel:presignedUrlConfig:Job', job_presignedUrlConfig - Configuration for pre-signed S3 URLs.

$sel:reasonCode:Job', job_reasonCode - If the job was updated, provides the reason code for the update.

$sel:schedulingConfig:Job', job_schedulingConfig - The configuration that allows you to schedule a job for a future date and time in addition to specifying the end behavior for each job execution.

$sel:status:Job', job_status - The status of the job, one of IN_PROGRESS, CANCELED, DELETION_IN_PROGRESS or COMPLETED.

$sel:targetSelection:Job', job_targetSelection - Specifies whether the job will continue to run (CONTINUOUS), or will be complete after all those things specified as targets have completed the job (SNAPSHOT). If continuous, the job may also be run on a thing when a change is detected in a target. For example, a job will run on a device when the thing representing the device is added to a target group, even after the job was completed by all things originally in the group.

We recommend that you use continuous jobs instead of snapshot jobs for dynamic thing group targets. By using continuous jobs, devices that join the group receive the job execution even after the job has been created.

$sel:targets:Job', job_targets - A list of IoT things and thing groups to which the job should be sent.

$sel:timeoutConfig:Job', job_timeoutConfig - Specifies the amount of time each device has to finish its execution of the job. A timer is started when the job execution status is set to IN_PROGRESS. If the job execution status is not set to another terminal state before the timer expires, it will be automatically set to TIMED_OUT.

job_abortConfig :: Lens' Job (Maybe AbortConfig) Source #

Configuration for criteria to abort the job.

job_comment :: Lens' Job (Maybe Text) Source #

If the job was updated, describes the reason for the update.

job_completedAt :: Lens' Job (Maybe UTCTime) Source #

The time, in seconds since the epoch, when the job was completed.

job_createdAt :: Lens' Job (Maybe UTCTime) Source #

The time, in seconds since the epoch, when the job was created.

job_description :: Lens' Job (Maybe Text) Source #

A short text description of the job.

job_documentParameters :: Lens' Job (Maybe (HashMap Text Text)) Source #

A key-value map that pairs the patterns that need to be replaced in a managed template job document schema. You can use the description of each key as a guidance to specify the inputs during runtime when creating a job.

documentParameters can only be used when creating jobs from Amazon Web Services managed templates. This parameter can't be used with custom job templates or to create jobs from them.

job_forceCanceled :: Lens' Job (Maybe Bool) Source #

Will be true if the job was canceled with the optional force parameter set to true.

job_isConcurrent :: Lens' Job (Maybe Bool) Source #

Indicates whether a job is concurrent. Will be true when a job is rolling out new job executions or canceling previously created executions, otherwise false.

job_jobArn :: Lens' Job (Maybe Text) Source #

An ARN identifying the job with format "arn:aws:iot:region:account:job/jobId".

job_jobExecutionsRetryConfig :: Lens' Job (Maybe JobExecutionsRetryConfig) Source #

The configuration for the criteria to retry the job.

job_jobExecutionsRolloutConfig :: Lens' Job (Maybe JobExecutionsRolloutConfig) Source #

Allows you to create a staged rollout of a job.

job_jobId :: Lens' Job (Maybe Text) Source #

The unique identifier you assigned to this job when it was created.

job_jobProcessDetails :: Lens' Job (Maybe JobProcessDetails) Source #

Details about the job process.

job_jobTemplateArn :: Lens' Job (Maybe Text) Source #

The ARN of the job template used to create the job.

job_lastUpdatedAt :: Lens' Job (Maybe UTCTime) Source #

The time, in seconds since the epoch, when the job was last updated.

job_namespaceId :: Lens' Job (Maybe Text) Source #

The namespace used to indicate that a job is a customer-managed job.

When you specify a value for this parameter, Amazon Web Services IoT Core sends jobs notifications to MQTT topics that contain the value in the following format.

$aws/things/THING_NAME/jobs/JOB_ID/notify-namespace-NAMESPACE_ID/

The namespaceId feature is in public preview.

job_presignedUrlConfig :: Lens' Job (Maybe PresignedUrlConfig) Source #

Configuration for pre-signed S3 URLs.

job_reasonCode :: Lens' Job (Maybe Text) Source #

If the job was updated, provides the reason code for the update.

job_schedulingConfig :: Lens' Job (Maybe SchedulingConfig) Source #

The configuration that allows you to schedule a job for a future date and time in addition to specifying the end behavior for each job execution.

job_status :: Lens' Job (Maybe JobStatus) Source #

The status of the job, one of IN_PROGRESS, CANCELED, DELETION_IN_PROGRESS or COMPLETED.

job_targetSelection :: Lens' Job (Maybe TargetSelection) Source #

Specifies whether the job will continue to run (CONTINUOUS), or will be complete after all those things specified as targets have completed the job (SNAPSHOT). If continuous, the job may also be run on a thing when a change is detected in a target. For example, a job will run on a device when the thing representing the device is added to a target group, even after the job was completed by all things originally in the group.

We recommend that you use continuous jobs instead of snapshot jobs for dynamic thing group targets. By using continuous jobs, devices that join the group receive the job execution even after the job has been created.

job_targets :: Lens' Job (Maybe (NonEmpty Text)) Source #

A list of IoT things and thing groups to which the job should be sent.

job_timeoutConfig :: Lens' Job (Maybe TimeoutConfig) Source #

Specifies the amount of time each device has to finish its execution of the job. A timer is started when the job execution status is set to IN_PROGRESS. If the job execution status is not set to another terminal state before the timer expires, it will be automatically set to TIMED_OUT.