cancelExportTask method
Cancels the specified export task.
The task must be in the PENDING
or RUNNING
state.
May throw InvalidParameterException. May throw ResourceNotFoundException. May throw InvalidOperationException. May throw ServiceUnavailableException.
Parameter taskId
:
The ID of the export task.
Implementation
Future<void> cancelExportTask({
required String taskId,
}) async {
ArgumentError.checkNotNull(taskId, 'taskId');
_s.validateStringLength(
'taskId',
taskId,
1,
512,
isRequired: true,
);
final headers = <String, String>{
'Content-Type': 'application/x-amz-json-1.1',
'X-Amz-Target': 'Logs_20140328.CancelExportTask'
};
await _protocol.send(
method: 'POST',
requestUri: '/',
exceptionFnMap: _exceptionFns,
// TODO queryParams
headers: headers,
payload: {
'taskId': taskId,
},
);
}