jsr356-experts@websocket-spec.java.net

[jsr356-experts] JSR-356 missing information at time of upgrade

From: Joakim Erdfelt <joakim_at_intalio.com>
Date: Wed, 5 Jun 2013 10:12:19 -0700

During the Upgrade process, there is a few pieces of information, that are
missing that seem to be an oversight in the spec.

Namely some means to access the low level connection endpoint information.

Example (using HttpServletRequest methods as example)
Local Address - HttpServletRequest.getLocalAddr()
Local Hostname - HttpServletRequest.getLocalName()
Local Port - HttpServletRequest.getLocalPort()
Remote Address - HttpServletRequest.getRemoteAddr()
Remote Hostname - HttpServletRequest.getRemoteHost()
Remote Port - HttpServletRequest.getRemotePort()

These are rather important pieces of information about the connection.
Ideally, since JSR-356 is disconnected from the servlet api, these should
be made available somewhere, even the javax.websocket.Session interface.

However, an ideal place to use these pieces of information would be to add
reject logic on the upgrade process. But there is no appropriate place on
a server configuration to perform this sort of accept/deny upgrade logic.

--
Joakim Erdfelt <joakim_at_intalio.com>
webtide.com <http://www.webtide.com/>
Developer advice, services and support
from the Jetty & CometD experts
eclipse.org/jetty - cometd.org