deleteApplicationCloudWatchLoggingOption method
Deletes an Amazon CloudWatch log stream from an SQL-based Kinesis Data Analytics application.
May throw ConcurrentModificationException.
May throw InvalidApplicationConfigurationException.
May throw InvalidArgumentException.
May throw InvalidRequestException.
May throw ResourceInUseException.
May throw ResourceNotFoundException.
Parameter applicationName :
The application name.
Parameter cloudWatchLoggingOptionId :
The CloudWatchLoggingOptionId of the Amazon CloudWatch
logging option to delete. You can get the
CloudWatchLoggingOptionId by using the
DescribeApplication operation.
Parameter conditionalToken :
A value you use to implement strong concurrency for application updates.
You must provide the CurrentApplicationVersionId or the
ConditionalToken. You get the application's current
ConditionalToken using DescribeApplication. For better
concurrency support, use the ConditionalToken parameter
instead of CurrentApplicationVersionId.
Parameter currentApplicationVersionId :
The version ID of the application. You must provide the
CurrentApplicationVersionId or the
ConditionalToken. You can retrieve the application version ID
using DescribeApplication. For better concurrency support, use the
ConditionalToken parameter instead of
CurrentApplicationVersionId.
Implementation
Future<DeleteApplicationCloudWatchLoggingOptionResponse>
deleteApplicationCloudWatchLoggingOption({
required String applicationName,
required String cloudWatchLoggingOptionId,
String? conditionalToken,
int? currentApplicationVersionId,
}) async {
_s.validateNumRange(
'currentApplicationVersionId',
currentApplicationVersionId,
1,
999999999,
);
final headers = <String, String>{
'Content-Type': 'application/x-amz-json-1.1',
'X-Amz-Target':
'KinesisAnalytics_20180523.DeleteApplicationCloudWatchLoggingOption'
};
final jsonResponse = await _protocol.send(
method: 'POST',
requestUri: '/',
exceptionFnMap: _exceptionFns,
// TODO queryParams
headers: headers,
payload: {
'ApplicationName': applicationName,
'CloudWatchLoggingOptionId': cloudWatchLoggingOptionId,
if (conditionalToken != null) 'ConditionalToken': conditionalToken,
if (currentApplicationVersionId != null)
'CurrentApplicationVersionId': currentApplicationVersionId,
},
);
return DeleteApplicationCloudWatchLoggingOptionResponse.fromJson(
jsonResponse.body);
}