updateJob method

Future<UpdateJobResponse> updateJob({
  1. required String jobName,
  2. required JobUpdate jobUpdate,
})

Updates an existing job definition. The previous job definition is completely overwritten by this information.

May throw ConcurrentModificationException. May throw EntityNotFoundException. May throw InternalServiceException. May throw InvalidInputException. May throw OperationTimeoutException.

Parameter jobName : The name of the job definition to update.

Parameter jobUpdate : Specifies the values with which to update the job definition. Unspecified configuration is removed or reset to default values.

Implementation

Future<UpdateJobResponse> updateJob({
  required String jobName,
  required JobUpdate jobUpdate,
}) async {
  final headers = <String, String>{
    'Content-Type': 'application/x-amz-json-1.1',
    'X-Amz-Target': 'AWSGlue.UpdateJob'
  };
  final jsonResponse = await _protocol.send(
    method: 'POST',
    requestUri: '/',
    exceptionFnMap: _exceptionFns,
    // TODO queryParams
    headers: headers,
    payload: {
      'JobName': jobName,
      'JobUpdate': jobUpdate,
    },
  );

  return UpdateJobResponse.fromJson(jsonResponse.body);
}