cloudformation-cli-java-plugin icon indicating copy to clipboard operation
cloudformation-cli-java-plugin copied to clipboard

Fixed problem when original exception message was lost.

Open wesolowskim opened this issue 4 years ago • 0 comments

*Issue #351 * When the exception was thrown with operation name the original errorMessage was lost. For example

 throw new CfnGeneralServiceException("Operation", new RuntimeException("something happend");

results in "Error occurred during operation 'Operation'." message. If operation parameter would not be passed then the message would contain "something happend".

Description of changes: I changed how Exceptions are constructed so behavior is consistent. If "operation" is passed in the original message is preserved.

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.

wesolowskim avatar Feb 11 '21 16:02 wesolowskim