Endpoint#onError for a description of the different categories of error.
The method may only take the following parameters:-
Session parameterjava.lang.Throwable parameterjakarta.websocket.server.PathParam annotationThe parameters may appear in any order.