deleteCluster method

Future<DeleteClusterResponse> deleteCluster({
  1. required String clusterName,
})

Deletes a previously provisioned DAX cluster. DeleteCluster deletes all associated nodes, node endpoints and the DAX cluster itself. When you receive a successful response from this action, DAX immediately begins deleting the cluster; you cannot cancel or revert this action.

May throw ClusterNotFoundFault. May throw InvalidClusterStateFault. May throw ServiceLinkedRoleNotFoundFault. May throw InvalidParameterValueException. May throw InvalidParameterCombinationException.

Parameter clusterName : The name of the cluster to be deleted.

Implementation

Future<DeleteClusterResponse> deleteCluster({
  required String clusterName,
}) async {
  ArgumentError.checkNotNull(clusterName, 'clusterName');
  final headers = <String, String>{
    'Content-Type': 'application/x-amz-json-1.1',
    'X-Amz-Target': 'AmazonDAXV3.DeleteCluster'
  };
  final jsonResponse = await _protocol.send(
    method: 'POST',
    requestUri: '/',
    exceptionFnMap: _exceptionFns,
    // TODO queryParams
    headers: headers,
    payload: {
      'ClusterName': clusterName,
    },
  );

  return DeleteClusterResponse.fromJson(jsonResponse.body);
}