cshannon commented on a change in pull request #756:
URL: https://github.com/apache/activemq/pull/756#discussion_r800240683



##########
File path: 
activemq-client/src/main/java/org/apache/activemq/util/JMSExceptionSupport.java
##########
@@ -61,6 +63,11 @@ public static JMSException create(Exception cause) {
         if (cause instanceof JMSException) {
             return (JMSException)cause;
         }
+        if (cause instanceof MaxFrameSizeExceededException) {
+            JMSException jmsException = new JMSException(cause.getMessage(), 
"41300");
+            jmsException.setLinkedException(cause);

Review comment:
       Instead of using linked I would use initCause() as thats what the server 
side does.  A server side error thrown will have a TransportDisposedIOException 
or SocketException set when calling e.getCause() so it would be consistent




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


Reply via email to