List of usage examples for com.amazonaws.services.sns AmazonSNS getCachedResponseMetadata
ResponseMetadata getCachedResponseMetadata(AmazonWebServiceRequest request);
From source file:com.dev.appx.sns.SNSMobilePush.java
License:Open Source License
public void deleteTopic(String topicArn) throws IOException { //AmazonSNSClient snsClient = new AmazonSNSClient(new ClasspathPropertiesFileCredentialsProvider()); AmazonSNS snsClient = new AmazonSNSClient( new PropertiesCredentials(SNSMobilePush.class.getResourceAsStream("AwsCredentials.properties"))); //delete an SNS topic DeleteTopicRequest deleteTopicRequest = new DeleteTopicRequest(topicArn); snsClient.deleteTopic(deleteTopicRequest); //get request id for DeleteTopicRequest from SNS metadata System.out.println("DeleteTopicRequest - " + snsClient.getCachedResponseMetadata(deleteTopicRequest)); }