updateRecipeJob method

Future<UpdateRecipeJobResponse> updateRecipeJob({
  1. required String name,
  2. required String roleArn,
  3. List<DataCatalogOutput>? dataCatalogOutputs,
  4. List<DatabaseOutput>? databaseOutputs,
  5. String? encryptionKeyArn,
  6. EncryptionMode? encryptionMode,
  7. LogSubscription? logSubscription,
  8. int? maxCapacity,
  9. int? maxRetries,
  10. List<Output>? outputs,
  11. int? timeout,
})

Modifies the definition of an existing DataBrew recipe job.

May throw AccessDeniedException. May throw ResourceNotFoundException. May throw ValidationException.

Parameter name : The name of the job to update.

Parameter roleArn : The Amazon Resource Name (ARN) of the Identity and Access Management (IAM) role to be assumed when DataBrew runs the job.

Parameter dataCatalogOutputs : One or more artifacts that represent the Glue Data Catalog output from running the job.

Parameter databaseOutputs : Represents a list of JDBC database output objects which defines the output destination for a DataBrew recipe job to write into.

Parameter encryptionKeyArn : The Amazon Resource Name (ARN) of an encryption key that is used to protect the job.

Parameter encryptionMode : The encryption mode for the job, which can be one of the following:

  • SSE-KMS - Server-side encryption with keys managed by KMS.
  • SSE-S3 - Server-side encryption with keys managed by Amazon S3.

Parameter logSubscription : Enables or disables Amazon CloudWatch logging for the job. If logging is enabled, CloudWatch writes one log stream for each job run.

Parameter maxCapacity : The maximum number of nodes that DataBrew can consume when the job processes data.

Parameter maxRetries : The maximum number of times to retry the job after a job run fails.

Parameter outputs : One or more artifacts that represent the output from running the job.

Parameter timeout : The job's timeout in minutes. A job that attempts to run longer than this timeout period ends with a status of TIMEOUT.

Implementation

Future<UpdateRecipeJobResponse> updateRecipeJob({
  required String name,
  required String roleArn,
  List<DataCatalogOutput>? dataCatalogOutputs,
  List<DatabaseOutput>? databaseOutputs,
  String? encryptionKeyArn,
  EncryptionMode? encryptionMode,
  LogSubscription? logSubscription,
  int? maxCapacity,
  int? maxRetries,
  List<Output>? outputs,
  int? timeout,
}) async {
  _s.validateNumRange(
    'maxRetries',
    maxRetries,
    0,
    1152921504606846976,
  );
  _s.validateNumRange(
    'timeout',
    timeout,
    0,
    1152921504606846976,
  );
  final $payload = <String, dynamic>{
    'RoleArn': roleArn,
    if (dataCatalogOutputs != null) 'DataCatalogOutputs': dataCatalogOutputs,
    if (databaseOutputs != null) 'DatabaseOutputs': databaseOutputs,
    if (encryptionKeyArn != null) 'EncryptionKeyArn': encryptionKeyArn,
    if (encryptionMode != null) 'EncryptionMode': encryptionMode.value,
    if (logSubscription != null) 'LogSubscription': logSubscription.value,
    if (maxCapacity != null) 'MaxCapacity': maxCapacity,
    if (maxRetries != null) 'MaxRetries': maxRetries,
    if (outputs != null) 'Outputs': outputs,
    if (timeout != null) 'Timeout': timeout,
  };
  final response = await _protocol.send(
    payload: $payload,
    method: 'PUT',
    requestUri: '/recipeJobs/${Uri.encodeComponent(name)}',
    exceptionFnMap: _exceptionFns,
  );
  return UpdateRecipeJobResponse.fromJson(response);
}