https://bz.apache.org/bugzilla/show_bug.cgi?id=63114

            Bug ID: 63114
           Summary: Async methods do not call handler on exception
           Product: Tomcat 9
           Version: 9.0.14
          Hardware: PC
                OS: Linux
            Status: NEW
          Severity: major
          Priority: P2
         Component: WebSocket
          Assignee: dev@tomcat.apache.org
          Reporter: boris_pet...@live.com
  Target Milestone: -----

While debugging another issue, we noticed that some (most?) async methods at
least in WsRemoteEndpointImplBase do not call the handler when erring but
rather throw an exception. Here are examples:

https://github.com/apache/tomcat/blob/TOMCAT_9_0_14/java/org/apache/tomcat/websocket/WsRemoteEndpointImplBase.java#L204

https://github.com/apache/tomcat/blob/TOMCAT_9_0_14/java/org/apache/tomcat/websocket/WsRemoteEndpointImplBase.java#L207

https://github.com/apache/tomcat/blob/TOMCAT_9_0_14/java/org/apache/tomcat/websocket/WsRemoteEndpointImplBase.java#L1224

https://github.com/apache/tomcat/blob/TOMCAT_9_0_14/java/org/apache/tomcat/websocket/WsRemoteEndpointImplBase.java#L799

These are coming from the "sendStringByCompletion" method. There's more async
methods in this class and at least some of them have the same issues.

I think this is a bug. The SendHandler's onResult method should be called
instead.

-- 
You are receiving this mail because:
You are the assignee for the bug.
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org
For additional commands, e-mail: dev-h...@tomcat.apache.org

Reply via email to