Java Code Examples for com.amazonaws.AmazonServiceException#setServiceName()

The following examples show how to use com.amazonaws.AmazonServiceException#setServiceName() .
Example 1
Project: localization_nifi   File: AbstractDynamoDBTest.java    License: Apache License 2.0 5 votes vote down vote up
protected AmazonServiceException getSampleAwsServiceException() {
    final AmazonServiceException testServiceException = new AmazonServiceException("Test AWS Service Exception");
    testServiceException.setErrorCode("8673509");
    testServiceException.setErrorMessage("This request cannot be serviced right now.");
    testServiceException.setErrorType(ErrorType.Service);
    testServiceException.setServiceName("Dynamo DB");
    testServiceException.setRequestId("TestRequestId-1234567890");

    return testServiceException;
}
 
Example 2
Project: nifi   File: AbstractDynamoDBTest.java    License: Apache License 2.0 5 votes vote down vote up
protected AmazonServiceException getSampleAwsServiceException() {
    final AmazonServiceException testServiceException = new AmazonServiceException("Test AWS Service Exception");
    testServiceException.setErrorCode("8673509");
    testServiceException.setErrorMessage("This request cannot be serviced right now.");
    testServiceException.setErrorType(ErrorType.Service);
    testServiceException.setServiceName("Dynamo DB");
    testServiceException.setRequestId("TestRequestId-1234567890");

    return testServiceException;
}