Version: 9.4.5.v20170502 |
private support for your internal/customer projects ... custom extensions and distributions ... versioned snapshots for indefinite support ... scalability guidance for your apps and Ajax/Comet projects ... development services for sponsored feature development
The Session object can be used to:
The Connection State (is it open or not).
if(session.isOpen()) {
// send message
}
Is the Connection Secure.
if(session.isSecure()) {
// connection is using 'wss://'
}
What was in the Upgrade Request and Response.
UpgradeRequest req = session.getUpgradeRequest();
String channelName = req.getParameterMap().get("channelName");
UpgradeRespons resp = session.getUpgradeResponse();
String subprotocol = resp.getAcceptedSubProtocol();
What is the Local and Remote Address.
InetSocketAddress remoteAddr = session.getRemoteAddress();
Get and Set the Idle Timeout
session.setIdleTimeout(2000); // 2 second timeout