code: public void onError(Session session, Throwable thr) {
          if (getOnErrorHandle() != null) {
              callMethod(getOnErrorHandle(), getOnErrorParameters(), session, false, thr);
          } else {
              logger.error(Messages.get("web.socket.error"), thr);
          }
      }
docs: <p>onError.</p>
  
  @param session a {@link javax.websocket.Session} object.
  @param thr a {@link java.lang.Throwable} object.