use of software.amazon.awssdk.services.firehose.model.DeleteDeliveryStreamRequest in project aws-doc-sdk-examples by awsdocs.
the class DeleteStream method delStream.
// snippet-start:[firehose.java2.delete_stream.main]
public static void delStream(FirehoseClient firehoseClient, String streamName) {
try {
DeleteDeliveryStreamRequest deleteDeliveryStreamRequest = DeleteDeliveryStreamRequest.builder().deliveryStreamName(streamName).build();
firehoseClient.deleteDeliveryStream(deleteDeliveryStreamRequest);
System.out.println("Delivery Stream " + streamName + " is deleted");
} catch (FirehoseException e) {
System.out.println(e.getLocalizedMessage());
System.exit(1);
}
}
Aggregations