deleteAddon method
Deletes an Amazon EKS add-on.
When you remove an add-on, it's deleted from the cluster. You can always manually start an add-on on the cluster using the Kubernetes API.
May throw ClientException.
May throw InvalidParameterException.
May throw InvalidRequestException.
May throw ResourceNotFoundException.
May throw ServerException.
Parameter addonName :
The name of the add-on. The name must match one of the names returned by
ListAddons .
Parameter clusterName :
The name of your cluster.
Parameter preserve :
Specifying this option preserves the add-on software on your cluster but
Amazon EKS stops managing any settings for the add-on. If an IAM account
is associated with the add-on, it isn't removed.
Implementation
Future<DeleteAddonResponse> deleteAddon({
required String addonName,
required String clusterName,
bool? preserve,
}) async {
final $query = <String, List<String>>{
if (preserve != null) 'preserve': [preserve.toString()],
};
final response = await _protocol.send(
payload: null,
method: 'DELETE',
requestUri:
'/clusters/${Uri.encodeComponent(clusterName)}/addons/${Uri.encodeComponent(addonName)}',
queryParams: $query,
exceptionFnMap: _exceptionFns,
);
return DeleteAddonResponse.fromJson(response);
}