amazonka-iot-jobs-dataplane-1.6.0: Amazon IoT Jobs Data Plane SDK.

Copyright(c) 2013-2018 Brendan Hay
LicenseMozilla Public License, v. 2.0.
MaintainerBrendan Hay <brendan.g.hay+amazonka@gmail.com>
Stabilityauto-generated
Portabilitynon-portable (GHC extensions)
Safe HaskellNone
LanguageHaskell2010

Network.AWS.IoTJobsData.UpdateJobExecution

Contents

Description

Updates the status of a job execution.

Synopsis

Creating a Request

updateJobExecution Source #

Creates a value of UpdateJobExecution with the minimum fields required to make a request.

Use one of the following lenses to modify other fields as desired:

  • ujeIncludeJobDocument - Optional. When set to true, the response contains the job document. The default is false.
  • ujeStatusDetails - Optional. A collection of name/value pairs that describe the status of the job execution. If not specified, the statusDetails are unchanged.
  • ujeExecutionNumber - Optional. A number that identifies a particular job execution on a particular device.
  • ujeExpectedVersion - Optional. The expected current version of the job execution. Each time you update the job execution, its version is incremented. If the version of the job execution stored in Jobs does not match, the update is rejected with a VersionMismatch error, and an ErrorResponse that contains the current job execution status data is returned. (This makes it unnecessary to perform a separate DescribeJobExecution request in order to obtain the job execution status data.)
  • ujeIncludeJobExecutionState - Optional. When included and set to true, the response contains the JobExecutionState data. The default is false.
  • ujeJobId - The unique identifier assigned to this job when it was created.
  • ujeThingName - The name of the thing associated with the device.
  • ujeStatus - The new status for the job execution (IN_PROGRESS, FAILED, SUCCESS, or REJECTED). This must be specified on every update.

data UpdateJobExecution Source #

See: updateJobExecution smart constructor.

Instances

Eq UpdateJobExecution Source # 
Data UpdateJobExecution Source # 

Methods

gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> UpdateJobExecution -> c UpdateJobExecution #

gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c UpdateJobExecution #

toConstr :: UpdateJobExecution -> Constr #

dataTypeOf :: UpdateJobExecution -> DataType #

dataCast1 :: Typeable (* -> *) t => (forall d. Data d => c (t d)) -> Maybe (c UpdateJobExecution) #

dataCast2 :: Typeable (* -> * -> *) t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c UpdateJobExecution) #

gmapT :: (forall b. Data b => b -> b) -> UpdateJobExecution -> UpdateJobExecution #

gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> UpdateJobExecution -> r #

gmapQr :: (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> UpdateJobExecution -> r #

gmapQ :: (forall d. Data d => d -> u) -> UpdateJobExecution -> [u] #

gmapQi :: Int -> (forall d. Data d => d -> u) -> UpdateJobExecution -> u #

gmapM :: Monad m => (forall d. Data d => d -> m d) -> UpdateJobExecution -> m UpdateJobExecution #

gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> UpdateJobExecution -> m UpdateJobExecution #

gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> UpdateJobExecution -> m UpdateJobExecution #

Read UpdateJobExecution Source # 
Show UpdateJobExecution Source # 
Generic UpdateJobExecution Source # 
Hashable UpdateJobExecution Source # 
ToJSON UpdateJobExecution Source # 
NFData UpdateJobExecution Source # 

Methods

rnf :: UpdateJobExecution -> () #

AWSRequest UpdateJobExecution Source # 
ToHeaders UpdateJobExecution Source # 
ToPath UpdateJobExecution Source # 
ToQuery UpdateJobExecution Source # 
type Rep UpdateJobExecution Source # 
type Rep UpdateJobExecution = D1 * (MetaData "UpdateJobExecution" "Network.AWS.IoTJobsData.UpdateJobExecution" "amazonka-iot-jobs-dataplane-1.6.0-1BXy9I0VbTNJCQzMDHs5aK" False) (C1 * (MetaCons "UpdateJobExecution'" PrefixI True) ((:*:) * ((:*:) * ((:*:) * (S1 * (MetaSel (Just Symbol "_ujeIncludeJobDocument") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 * (Maybe Bool))) (S1 * (MetaSel (Just Symbol "_ujeStatusDetails") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 * (Maybe (Map Text Text))))) ((:*:) * (S1 * (MetaSel (Just Symbol "_ujeExecutionNumber") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 * (Maybe Integer))) (S1 * (MetaSel (Just Symbol "_ujeExpectedVersion") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 * (Maybe Integer))))) ((:*:) * ((:*:) * (S1 * (MetaSel (Just Symbol "_ujeIncludeJobExecutionState") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 * (Maybe Bool))) (S1 * (MetaSel (Just Symbol "_ujeJobId") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 * Text))) ((:*:) * (S1 * (MetaSel (Just Symbol "_ujeThingName") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 * Text)) (S1 * (MetaSel (Just Symbol "_ujeStatus") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 * JobExecutionStatus))))))
type Rs UpdateJobExecution Source # 

Request Lenses

ujeIncludeJobDocument :: Lens' UpdateJobExecution (Maybe Bool) Source #

Optional. When set to true, the response contains the job document. The default is false.

ujeStatusDetails :: Lens' UpdateJobExecution (HashMap Text Text) Source #

Optional. A collection of name/value pairs that describe the status of the job execution. If not specified, the statusDetails are unchanged.

ujeExecutionNumber :: Lens' UpdateJobExecution (Maybe Integer) Source #

Optional. A number that identifies a particular job execution on a particular device.

ujeExpectedVersion :: Lens' UpdateJobExecution (Maybe Integer) Source #

Optional. The expected current version of the job execution. Each time you update the job execution, its version is incremented. If the version of the job execution stored in Jobs does not match, the update is rejected with a VersionMismatch error, and an ErrorResponse that contains the current job execution status data is returned. (This makes it unnecessary to perform a separate DescribeJobExecution request in order to obtain the job execution status data.)

ujeIncludeJobExecutionState :: Lens' UpdateJobExecution (Maybe Bool) Source #

Optional. When included and set to true, the response contains the JobExecutionState data. The default is false.

ujeJobId :: Lens' UpdateJobExecution Text Source #

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

ujeThingName :: Lens' UpdateJobExecution Text Source #

The name of the thing associated with the device.

ujeStatus :: Lens' UpdateJobExecution JobExecutionStatus Source #

The new status for the job execution (IN_PROGRESS, FAILED, SUCCESS, or REJECTED). This must be specified on every update.

Destructuring the Response

updateJobExecutionResponse Source #

Creates a value of UpdateJobExecutionResponse with the minimum fields required to make a request.

Use one of the following lenses to modify other fields as desired:

data UpdateJobExecutionResponse Source #

See: updateJobExecutionResponse smart constructor.

Instances

Eq UpdateJobExecutionResponse Source # 
Data UpdateJobExecutionResponse Source # 

Methods

gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> UpdateJobExecutionResponse -> c UpdateJobExecutionResponse #

gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c UpdateJobExecutionResponse #

toConstr :: UpdateJobExecutionResponse -> Constr #

dataTypeOf :: UpdateJobExecutionResponse -> DataType #

dataCast1 :: Typeable (* -> *) t => (forall d. Data d => c (t d)) -> Maybe (c UpdateJobExecutionResponse) #

dataCast2 :: Typeable (* -> * -> *) t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c UpdateJobExecutionResponse) #

gmapT :: (forall b. Data b => b -> b) -> UpdateJobExecutionResponse -> UpdateJobExecutionResponse #

gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> UpdateJobExecutionResponse -> r #

gmapQr :: (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> UpdateJobExecutionResponse -> r #

gmapQ :: (forall d. Data d => d -> u) -> UpdateJobExecutionResponse -> [u] #

gmapQi :: Int -> (forall d. Data d => d -> u) -> UpdateJobExecutionResponse -> u #

gmapM :: Monad m => (forall d. Data d => d -> m d) -> UpdateJobExecutionResponse -> m UpdateJobExecutionResponse #

gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> UpdateJobExecutionResponse -> m UpdateJobExecutionResponse #

gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> UpdateJobExecutionResponse -> m UpdateJobExecutionResponse #

Read UpdateJobExecutionResponse Source # 
Show UpdateJobExecutionResponse Source # 
Generic UpdateJobExecutionResponse Source # 
NFData UpdateJobExecutionResponse Source # 
type Rep UpdateJobExecutionResponse Source # 
type Rep UpdateJobExecutionResponse = D1 * (MetaData "UpdateJobExecutionResponse" "Network.AWS.IoTJobsData.UpdateJobExecution" "amazonka-iot-jobs-dataplane-1.6.0-1BXy9I0VbTNJCQzMDHs5aK" False) (C1 * (MetaCons "UpdateJobExecutionResponse'" PrefixI True) ((:*:) * (S1 * (MetaSel (Just Symbol "_ujersJobDocument") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 * (Maybe Text))) ((:*:) * (S1 * (MetaSel (Just Symbol "_ujersExecutionState") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 * (Maybe JobExecutionState))) (S1 * (MetaSel (Just Symbol "_ujersResponseStatus") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 * Int)))))

Response Lenses

ujersJobDocument :: Lens' UpdateJobExecutionResponse (Maybe Text) Source #

The contents of the Job Documents.